Kits
Kits are drop-in, composable, multi-framework feature overlays for 0G apps. A kit injects a working feature — files, dependencies, and env var stubs — into any compatible template without rewriting the base. Kits compose: some kits build on other kits automatically.
Built with Kits —
0gkit-status. Our showcase app, a live 0G network dashboard, is composed from theagent-memory+live-feedkits on the published@foundryprotocol/0gkit-*packages, usingCompute.router()and0g testas its CI gate — the epic's end-to-end dogfood. See it live at apps.0gkit.com · source.
How kits work
Every kit follows a 3-tier model:
| Tier | What it contains | Always applied? |
|---|---|---|
| lib | Portable core — pure TypeScript, all deps injected | Yes |
| adapters | Per-base wiring — one file per compatible base (Next.js, Hono, MCP, …) | Only the adapter matching your base |
| ui | React components and hooks | Only for React-capable bases |
The lib tier has zero hard @foundryprotocol/* imports — dependencies are
injected by the adapter. This makes each lib independently testable and
framework-agnostic.
Composition
Some kits declare composes in their kit.json. When you apply
prediction-market, the engine automatically applies ai-oracle first,
then merges both kits' files and package.json dependencies. The resolution
order is depth-first, deduped, and cycle-safe.
Upgradeable overlay vs. code dump
Kits are overlays: the engine writes only the files from the kit's tiers
for your base. Your base files are unchanged except for merged
package.json dependencies and .env.example additions. You own the
written files — edit them freely.
Commands
# List kits compatible with your current project base
0g kits list
# Filter by a specific base
0g kits list --base react-app
# Print details for a kit (summary, tiers, env vars)
0g kits info ai-oracle
# Apply a kit to the current project
0g add ai-oracle
# Apply multiple kits at once
0g add agent-memory durable-agent
# Apply at scaffold time (comma-separated)
npm create 0gkit-app -- --kits agent-memory,sealed-inference
CLI commands verified in packages/0gkit-cli/src/commands/kits.ts and
packages/create-0g-app/src/index.ts.
Kit catalog
Verifiable AI
| Kit | Summary |
|---|---|
| AI Oracle | Signed AI answers with commitments anchored to 0G Storage (default) or on-chain. ✓ signature verified. |
| Sealed Inference | Signed AI inference with a verification badge driven by the real verify result. Badge is never hardcoded. |
Agent Infra
| Kit | Summary |
|---|---|
| Agent Memory | Persistent agent memory on 0G Storage — append-only JSONL blobs per namespace with keyword-indexed recall. |
| Durable Agent | Resumable multi-step agent loop on 0gkit-jobs — step ledger persisted to 0G Storage, every step traced via OpenTelemetry. |
Markets
| Kit | Summary |
|---|---|
| Prediction Market | AI-resolved, proof-anchored prediction market. Composes ai-oracle automatically. ✓ signature verified. |
| Live Feed | Reorg-safe live social feed on 0G Storage + 0gkit-indexer. Falls back to storage-only mode without a contract address. |
Assets
| Kit | Summary |
|---|---|
| iNFT Studio | Mint intelligent NFTs with AI-generated media stored on 0G Storage and attested provenance. |
DeFi
| Kit | Summary |
|---|---|
| Yield Intelligence | Read-only AI yield analysis with an attested decision log. No automated execution. Testnet-only. |
After applying a kit
- Run
pnpm install(ornpm install) to pull the kit's declareddependenciesintonode_modules. - Copy the new entries from
.env.exampleinto your.envand fill in the values. - Commit the kit files to your repo — they are yours to edit.
See Authoring a kit if you want to build your own kit and contribute it to the catalog.