ScarAI · web3ctx

As built,
as served.

Every box on this page runs in production. Components that were designed, measured, and rejected are listed at the bottom — absent from the product, so absent from the diagram.

Query path

Deterministic end to end — no model invoked.

The wrong-version twin must be excluded before ranking. Ranking it high and filtering after is the incumbent failure mode with an extra step.

01 · Resolve

Name → scope

entity → version → scope. Declared aliases and family aliases, never inferred. Dictionary-word names require a second signal before a recipe is served — a coincidence is not a name.

02 · Bind or abstain

Evidence, or nothing

Version binds from evidence: exact match, else a single agreeing major, else nothing — ambiguity never picks. No scoping evidence → abstention, with what would resolve it. Never a ranked guess over the whole corpus.

03 · Retrieve

Filter, then rank

Dependency closure defines the candidate set — a filter, never a fused score. BM25 ranks within it. Scope is carried inside the index and matched as phrases at weight 0: a filter expressed in the index, never a ranking signal.

04 · Shape

Budget-true payload

Token budget honored per call. Citations, provenance and receipts are never truncated; long bodies degrade behind a self-describing cursor, never disappear.

END-TO-END SQL predicate before any search · no rewriting · no reranker · no compression DETERMINISTIC
Clients

Remote MCP over HTTPS

One URL, two tiers

No package, no local process, nothing to update. /mcp — free, no key, ever. /mcp/oauth — GitHub sign-in, free, 10× daily budget. A token on the free route is refused, never silently honored.

Rate limiting in-band

Durable Object limiter. A refusal is a typed answer naming which window blocked and what raises it — never a transport 429 that kills the whole exchange.

Terse registered surface

Five primitives, small schemas by rule. The surface is an eval subject. No meta-tools, no dynamic tool discovery.

Trust layer

What the payload carries.

Version-true units

Every unit labelled project@version with as_of. Superseded APIs may appear — only with their version label beside them. Disagreements are stated, never reconciled silently.

Pinned citations

Sources cite immutable refs — commit SHAs, version-locked registry artifacts. A citation that cannot be re-fetched is treated as a defect, not a style choice.

Human-run recipes + receipts

Recipes validated by a person against live chains, served with transaction hashes anyone can check by RPC. The stamp attests the integration ran; the receipts are how you check it.

Stores

Cloudflare-native, serverless

Core D1

Dependency graph (WITH RECURSIVE, depth-capped) · identifier index · version predicates · typed tables (addresses / ABIs / EIPs) · recipes. No virtual tables — stays exportable. Read replication on from day one.

Lexical D1 — disposable

FTS5 with verbatim compounds + camelCase/snake subtokens — the identifier gap closes at ingest, not at query time. Rebuild-from-source is the recovery path.

R2 + KV

Content-addressed bodies · response cache keyed on the deployed code version — a deploy invalidates by construction, because a cache key that omits the code is a wrong answer with good latency.

Ingest is deterministic: same commit in → same index out, hash-verified. No LLM, no learned model anywhere in the parse loop.
Deliberately absent

Designed, measured, rejected.

Dense / neural arm

gated behind an ablation it has not won

Reranker

precision measured above the threshold that would justify one

Compression models

measured to hurt code; never on the hot path

Semantic cache

waits for real traffic to tune against

Each rejection is a pre-registered measurement in the public evidence set — the experiments that died are published beside the ones that shipped.