Developers

Build on the Knowledge Network.

Connect your application’s knowledge to an ENS namespace and let other agents and applications consume it. Three surfaces — SDK, CLI, MCP - One Knowledge Network

The model your code touches

  1. 01

    Source

    who or what said it

  2. 02

    Contribution

    a branch and a commit

  3. 03

    Proposal

    opened for review

  4. 04

    Review

    findings, then a verdict

  5. 05

    Commit

    lands as version vN

  6. 06

    Namespace

    an ENS name

    consumers

    resolve by name
  7. 07

    IPFS

    every version, addressable

A knowledge object keeps its source and provenance for its whole life.

How to create subdomains

Name a subdomain by what someone would look for; record who wrote each claim as its source.

The writer as a branch of the tree

  • swiggy.rishikesh.eth
  • foodagent.rishikesh.eth

The subject as the name, the writer as the source

  • food.rishikesh.eth
  • claim: "Prefers vegetarian food"
  • source: { kind: application, name: Swiggy }
An agent resolves one predictable name and gets everything on that subject, each claim carrying its own source. Per-writer subdomains rebuild the silo with better addresses — nobody looks in foodagent.* and nothing is shared. init warns on vendor- or agent-shaped names; the exception is a source running its own maintained namespace, like a trial registry publishing under its own name.
  1. 01

    Create it under a name you own

    A subdomain gets its own registry and resolver, so it can have its own owner, reviewers and children. Your wallet must own the parent.
    knowledge init food.yourname.eth --title "Food" --register
    knowledge init work.yourname.eth --title "Work" --kind organisation --register
    knowledge init trials.research.yourorg.eth --register       # nests as deep as you need

Integrate

Three npm packages, one network. Pick the one that matches where your code runs.

  1. 01

    Give your agent the network — @knowledge01/mcp

    One MCP server serves every namespace; the agent names one per call. PINATA_GATEWAY is required; add KNOWLEDGE_AGENT to sign what it proposes, and KNOWLEDGE_READER_KEY to open a private namespace it was granted. Any MCP client takes the same command and environment.
    claude mcp add knowledge \
      -e PINATA_GATEWAY=<gateway>.mypinata.cloud \
      -e KNOWLEDGE_AGENT=<your-agent>.eth \
      -- npx -y @knowledge01/mcp
    
    # then, from the agent
    knowledge_search({ namespace: "cancer-research.eth", query: "PARP inhibitor" })
    knowledge_read({ namespace: "signals.treasury.eth" })        // sealed: opens with its grant
    knowledge_propose({ namespace: "cancer-research.eth", title: "…", items: [...] })
  2. 02

    Own and publish from a terminal — @knowledge01/cli

    Create a namespace on ENS, set who reviews and who may propose, and publish. PRIVATE_KEY is the wallet that owns the name; reading needs none.
    npm i -g @knowledge01/cli
    
    knowledge init research.yourorg.eth --title "Research" --register
    knowledge policy --reviewer reviewer.eth --contributors anyone --approvals 1
    knowledge add "…" --subject "…" --topic "…" --source document:"…"
    knowledge commit -m "Seed" && knowledge push       # one setContenthash
    knowledge roles                                   # who may publish or propose, read from ENS
  3. 03

    Read from the network in your app — @knowledge01/repo

    Resolve a name on ENS, fetch its current version from IPFS and verify every object by its hash. No account and no server of ours; set PINATA_GATEWAY, and a private namespace opens with a grant sealed to your key.
    npm i @knowledge01/repo @knowledge01/storage viem
    export PINATA_GATEWAY=<gateway>.mypinata.cloud
    
    import { ensNetwork, resolveNamespace } from '@knowledge01/repo'
    import { createStorage } from '@knowledge01/storage'
    import { createPublicClient, http } from 'viem'
    import { sepolia } from 'viem/chains'
    
    const network = ensNetwork({ storage: createStorage(), client: createPublicClient({ chain: sepolia, transport: http() }) })
    const ns = await resolveNamespace(network, 'cancer-research.eth', null)   // or { privateKey } for a grant
    ns.version   // 2
    ns.claims    // each with sources, contributor, reviewers, confidence
  4. 04

    Contribute from your app — the same package

    Write through a local repository: a contribution becomes a proposal with automated findings, reviewed before it lands; personal memory can take observations directly.
    import { Namespace } from '@knowledge01/repo'
    
    const research = Namespace.for('cancer-research.eth', { agent: 'your-app.eth' })
    research.contribute({ title: 'Add olaparib', items: [{ subject: 'Olaparib', claim: '…', topic: 'approvals',
      sources: [{ type: 'document', title: 'FDA approval, December 2014' }] }] })   // → proposal #n
    
    const me = Namespace.for('alice.eth', { agent: 'your-app.eth' })
    me.observe({ observation: 'Prefers vegetarian food', topic: 'food', confidence: 0.9 })