Row-based
Rows in tables. Relations between tables. Query by joining tables and filtering rows.
- Strength:
- Transactional integrity
- Designed for:
- Forms & ledgers
The grammar that predates algebra.
Drop facts in. Pull them back in the order they were saved, scoped to the right branch. Always local on your Mac. No cloud LLMs required. Zero API costs.
v1.2.13 β · ~10 MB · Apple Silicon (M1+) · Signed + notarized — just double-click
KOSHA's labels are pure Sanskrit, but the structure maps cleanly to anything you've ever queried. If you've worked with row-based or graph-based storage, you can read a KOSHA tree on first sight.
| KOSHA term | What it is | SQL equivalent | Graph equivalent |
|---|---|---|---|
| KOSHA | Entire storage unit (one local file) | Database | Property graph |
| NABHA | Workspace inside a Kosha | Schema | Labelled subgraph |
| TAARA | Root branch (depth-0; max 8 per Nabha) | Parent table | Top-level node |
| GRAHA | Tree node with source content (depth 1-7) | Row / record | Node |
| ASHRU | V| pipe row extracted from graha content | Normalized row | Edge / relationship |
Three classes of structured storage have shipped over the last 50 years, each shaped by the workloads of its era. A vector index is not in this list — it's a similarity-search index that sits inside a storage layer as an implementation detail.
Rows in tables. Relations between tables. Query by joining tables and filtering rows.
Nodes and typed edges. Query by traversing relationships. Multi-hop becomes first-class.
Branches (TAARAs) and facts (Grahas) on an 8-deep tree. Query by semantic position. Designed around the data shape an LLM actually reads cleanly.
A vector index returns the top-K most cosine-similar chunks for a query. Two failure modes are baked in: chunks come from anywhere in the embedding space (boundary leak), and they arrive ranked by similarity, not by sequence (temporal scramble). The LLM has to re-derive context every time.
Your query searches only the relevant branch. KOSHA's TAARA structure scopes the question to one part of the tree — same question, same branch, every time. No answers from unrelated data.
Facts come back in their ingestion order. The LLM reads them in the sequence they were saved in, not reshuffled by similarity scores.
list taaras · summary "Work" · add "..." to "Day Job" · rename · delete · findkosha_ingest(content, auto_route=true)Always local. KOSHA stores everything on your Mac — the 8-branch structure, the facts, the registry, all local. No cloud LLMs are required to use V1.0; you read and write entirely without network.
Zero API costs. V1.0 has no cloud LLM toggles. No Gemini key, OpenAI key, or Anthropic key fields anywhere in the UI. Local Gemma 4 (when installed via Ollama) handles inference. You pay nothing per query.
Apple Silicon (M1+) required. This is your personal memory — it never leaves your laptop.
Anonymous usage stats during the beta. KOSHA records counts (number of grahas, KoshaLang commands run) once a day so we can improve the product. Never the content of your queries or your stored data. The telemetry endpoint table exists in the V1.0 schema; the daily ping wires up in V1.1.
Your data, your files.
Each Kosha is one file on disk at ~/Library/Application Support/com.sumaproai.kosha/koshas/<name>.db.
Drag it to a USB stick. Hand it to a coworker. Delete it. It's yours.
KOSHA's structural model is the kāraka case roles formalized in Pāṇini's Aṣṭādhyāyī (~5th century BCE) — one of humanity's earliest formal grammars. Six syntactic-semantic roles (kartā, karma, karaṇa, sampradāna, apādāna, adhikaraṇa) describe how nouns relate to verbs in any sentence.
Two and a half millennia of linguistic refinement turned out to be a remarkably good shape for representing LLM-extracted facts. We're using a structure that has been in the public domain for over two thousand years.
v1.2.13 β · ~10 MB · Apple Silicon (M1+) Mac. Signed + Apple-notarized — just double-click to open.
Download KOSHA 1.2.13 →Always local · No cloud LLMs required · Zero API costs
KOSHA runs an MCP server at 127.0.0.1:4096/mcp. Two tools — kosha_ingest (write) and kosha_search (read). One question in, one answer out. Every call is a sealed Chakra.
Open KOSHA. In the KoshaLang editor type create kosha "qa" with template Empty, then create kosha "dev" with template Empty. Switch between them in the dropdown — each is a separate encrypted file with its own TAARA tree. The QA agent never sees Dev's facts. The Dev agent never sees QA's facts. Branch-scoped retrieval, deterministic by construction.
Multi-machine networking, cross-agent writes, and federation arrive in V1.1+ (the MYRA layer). Today: per-agent bounded memory on one Mac.
curl -s -X POST http://127.0.0.1:4096/mcp \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' import json, urllib.request
def kosha_call(method, params=None):
payload = {"jsonrpc": "2.0", "id": 1, "method": method}
if params: payload["params"] = params
req = urllib.request.Request(
"http://127.0.0.1:4096/mcp",
data=json.dumps(payload).encode(),
headers={"Content-Type": "application/json"},
)
with urllib.request.urlopen(req) as r:
return json.loads(r.read())
# Overview of the active Kosha
print(kosha_call("tools/call", {"name": "kosha_search", "arguments": {}}))
# Write a fact under "Work" (hint is required — KOSHA enforces structure on write)
kosha_call("tools/call", {
"name": "kosha_ingest",
"arguments": {"content": "Migration 057 ships Friday.", "hint": "Work"},
}) async function koshaCall(method, params) {
const res = await fetch("http://127.0.0.1:4096/mcp", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ jsonrpc: "2.0", id: 1, method, params }),
});
return res.json();
}
// Read mode — query inside a scope (4 search modes total: overview / scope / query / query+scope)
const hits = await koshaCall("tools/call", {
name: "kosha_search",
arguments: { query: "migration 057", scope: "Work" },
});
console.log(hits); {
"mcpServers": {
"kosha": {
"url": "http://127.0.0.1:4096/mcp"
}
}
}
Drop into ~/.cursor/mcp.json or Continue's ~/.continue/config.json. Restart the IDE. kosha_search and kosha_ingest appear as native tools. Claude Desktop currently expects stdio MCP — an HTTP-bridge adapter ships in V1.1.
A note on hint: kosha_ingest requires a hint (a TAARA or sub-branch name like "Work") — KOSHA enforces structure on write. If your agent doesn't know where the fact belongs, call kosha_search first to discover the right branch, OR pass auto_route: true and KOSHA picks via Gemma path embeddings (requires Ollama + gemma4:e2b).
We'll email when V1.1 ships — first-run auto-install of Ollama + Gemma 4, per-account encryption keys, and the pre-populated KOSHA tutorial Nabha.