Open Context Format — the open, token-efficient standard that unifies knowledge, tools, resources, and prompts into lightweight, git-friendly Markdown bundles.
Website · Read the spec · Try the example bundle · Report an issue
We are tackling the biggest bottleneck in production agents: token growth.
Frontier labs optimize for more tokens in the loop. We are the builders who ship agents — and we are fixing the economics of context.
Modern agent stacks burn context on:
| Waste | What it costs you |
|---|---|
| Verbose JSON tool schemas | Every tool registered, every session — often before a single call |
| Repeated context | Same definitions re-sent across turns and sub-agents |
| All-or-nothing discovery | No progressive load; agents ingest what they will never use |
Agents get expensive, slow, and hard to scale. Token growth is not a feature — it is the ceiling on useful autonomy.
OCF extends ideas from Google’s Open Knowledge Format (OKF) into one standard for knowledge and executable tools.
Everything is plain Markdown + YAML frontmatter. Agents read an index first, then load only the concepts they need.
flowchart LR
A[Agent] --> B[index.md]
B --> C{Need a tool?}
C -->|Yes| D[One .md concept]
C -->|No| E[Stop — minimal tokens]
D --> F[Runtime / MCP adapter]
Typical outcome in discovery-heavy workflows: roughly 70–90% fewer tokens vs loading full MCP-style schemas for every tool up front — while keeping a clear path to MCP adapters and existing clients. (Measurement guidance in the spec →)
A real tool concept — arithmetic, percentages, simple & compound interest, loan payments, ROI — not a toy one-liner.
| Approach | Tokens (approx., GPT-4o-style) |
|---|---|
| Traditional MCP tool definition | 320–450+ |
| OCF tool concept (this repo) | 110–160 |
~70%+ savings on the definition alone, with Markdown humans can edit in a PR.
👉 Open the Business Calculator · Start at the bundle index
Bundle layout
examples/ocf-example-bundle/
├── index.md # Start here — progressive disclosure
├── META.yaml
├── tools/
│ ├── index.md
│ └── business_calculator.md
└── knowledge/
└── index.md
| MCP-heavy workflow | OCF workflow |
|---|---|
| Pay schema cost for all tools up front | Pay ~20–40 tokens per index entry; load tools on demand |
| JSON Schema as the source of truth | Natural language + examples; JSON Schema optional when you need strict validation |
| Tool defs live in server code | Git-diffable bundles your team can review |
Session-scale rule of thumb (from the spec): ~8 tools, ~3 selective calls — MCP-style upfront definitions often 2,800–4,000+ tokens; OCF selective loading often 400–700. Your tokenizer and agent loop will differ — benchmark it.
- Radical token efficiency — Load only what you need; forget what you loaded.
- Human + agent native — One format your team and your model both read.
- Git-friendly & portable — No vendor lock-in; fork, version, and share bundles.
- MCP compatible — Project OCF tools into
tools/listvia an adapter (§8). - Open by design — Draft spec, reference bundle, room for validators and runtimes on the roadmap.
git clone https://github.com/Ashvinnaik/OCF.git
cd OCFExplore
| Resource | Link |
|---|---|
| Specification (v0.1 draft) | OCF_Spec_v0.1.md |
| Examples | examples/ocf-example-bundle/ |
| Token targets & benchmarks | Spec §5 — Performance & tokens |
| MCP compatibility | Spec §8 — MCP adapter |
Three-minute agent test: Point your agent at examples/ocf-example-bundle/index.md. Ask it to use the Business Calculator without pasting your full MCP tools/list. Compare context size.
We are outsiders solving the token problem incumbents will not prioritize.
- ⭐ Star this repo — it signals demand for efficient agent standards.
- 🛠 Contribute tools, bundle examples, spec clarifications, or adapter designs via Issues and PRs.
- 🐦 Follow updates on X: @ashvinn
Let’s make AI agents efficient again.
OCF — Efficiency first. Open always.
Status: v0.1 draft for community review · Contributions welcome