Install from npm (kaibo), PyPI (kaibo) or the CLI (curl -fsSL $KAIBO_URL/install.sh | sh). An AI agent can also connect over MCP, and anything can use the HTTP API with curl, with nothing to install.
/app page of the site you are reading this on), create a project and an API key. A key looks like kaibo_<id>.<secret> and is shown once. Choose the scope read and write for this tutorial; forgetting later needs the forget scope. Put the key and the site's address in your environment:12export KAIBO_URL=<the address you opened this site at> export KAIBO_KEY=kaibo_<id>.<secret>
KAIBO_URL and KAIBO_KEY on its own, so your code never needs to mention them.1bun add kaibo # or: npm install kaibo, pnpm add kaibo, yarn add kaibo
kaibo init in it. It prints the right install command for your package manager and sets up your agent tools (step 4).123456789import { Kaibo } from "kaibo"; const kaibo = new Kaibo(); // reads KAIBO_KEY await kaibo.remember("The release target is July 13."); await kaibo.remember("Move the release target from July 13 to July 17.", { wait: true }); const pack = await kaibo.recall("release target"); console.log(pack.found ? pack.answer : `no answer: ${pack.reason}`); console.log(pack.sources); // the events it came from
kaibo init in your project. It finds the agent tools you already use and writes what they need: a skill for Claude Code, a rule for Cursor, a block in AGENTS.md for Codex and others, and an MCP config. Nothing is overwritten, and your key stays in the environment./agents/setup-prompt.md on this site) into your agent and let it do the steps. See Use with agents for the details.123const memory = await kaibo.context("what did we decide about the release?"); // delimited as stored data, with citations, and with outdated, unverified // and untrusted items marked. Say "I do not know" when it says there is no answer.
recall with asOf set to an earlier time and you get July 13 back.explain returns the chain: what the memory replaced, and the source events with their hashes. kaibo verify recomputes the hash chain of a stream on your machine.123const preview = await kaibo.forget({ query: "release target" }, { reason: "demo", dryRun: true }); const { receipt } = await kaibo.forget({ query: "release target" }, { reason: "demo" }); await kaibo.forget.verify(receipt.id); // { ok: true, ... }
forget scope.