instinct-cli 0.3.6

Local memory for AI coding agents: an MCP server and CLI that gives Claude Code, Codex, Cursor and any MCP client the one lesson that fits. Lessons that keep failing go quiet.
# Capability verification: frozen evaluation protocol v1

Status: development protocol; no measured economic benefit or transfer result claimed.

## Question

Can explicit reusable checks reduce total work per independently correct task decision compared with the strongest available baseline, without increasing unsafe actions or hiding failed completion behind abstention?

A previous research pilot (PR56 c55f617, bench/analogy-grounding/agent-trial) reported equal information-appropriate decisions for unaided and native arms, with higher native cost. It is a negative/null utility baseline, not evidence that more context is useful. Replaying historical Python evidence is separate from the product runtime; no new model experiment is authorized by this protocol.

## First deterministic rung

The check kernel consumes supplied facts; it does not claim to observe the filesystem. Artifact membership fixture gold is computed independently as set difference. Correct decisions:

- complete inventory and explicit policy present, actual subset allowed: pass;
- complete inventory and explicit policy present, extra actual member: fail with lexicographically first extra member;
- either required condition absent/false: abstain;
- required scope unknown/different: abstain;
- malformed structure, wrong types, duplicates, unknown inputs: error.

Every result declares caller_reported evidence and not_evaluated authorization. A pass cannot be presented as complete release safety or content-secret verification.

## Arms

1. Direct hand-written set/predicate oracle with the same fact inputs (strong deterministic baseline).
2. Typed compiled check, cold compile plus evaluate.
3. Typed compiled check, reusable compiled plan where exposed (report unsupported until implemented).
4. Current Instinct retrieval only, where the task requires a predicate answer; do not score textual relevance as proof.
5. Later authenticated trials: unaided capable agent, equal evidence pasted, current Instinct, compiled checks, transfer/composition. Same model revision, tool access and task budget.

Do not multiply ratios from incomparable tasks or replace the strongest baseline with repeated LLM reasoning just to obtain a bigger number.

## Work accounting

Record separately: definition authoring and validation, compile time, input acquisition, evidence hashing, evaluation steps, process startup, receipt/cache cost, maintenance, model tokens/cost, human interventions and total latency. Report first-use cost, amortized cost at measured reuse counts and break-even reuse. A synthetic infinite reuse forecast is not an observed multiplier.

Deterministic microbench timings are descriptive until repeated/interleaved across enough trials with load recorded; medians and p90 plus raw samples. Semantic parity is checked for every timed result, including fail/abstain/error. No performance report if the measured path silently returns empty.

## Split and leakage prevention

Committed fixtures are public development/calibration evidence, NOT held-out validation. Independent acceptance tests are authored from docs/checks.md without reading implementation. A later sealed final corpus is created by a separate verifier before candidate tuning, held outside the builder's working context, grouped by source family/domain rather than renamed examples. Freeze hashes and scoring before revealing outcomes. Hashes prove identity, not trusted chronology.

Cross-domain transfer remains UNMEASURED until separate source and withheld-domain tasks, independent target oracles and autonomous retrieval are exercised. Passing artifact-membership predicates is not cross-domain discovery.

## Non-negotiable gates

- No false pass on the enumerated challenge suite; report finite sample size, not universal safety.
- No missing/false condition converted to true; no scope broadening.
- Exact integers remain exact above 2^53 and through i128 endpoints.
- Unreachable malformed expressions still fail compilation.
- Fuel limits include set work, not only AST visits.
- CLI check does not create/open a lesson bank, perform network I/O or execute actions.
- Same pure result for equivalent set orders and file/stdin input.
- Existing release tests stay green; structured check errors cannot alter legacy hook fail-open behavior.

## Exhaustive small-set control

`cargo run --locked --offline --example capability-subset -- /absolute/path/to/instinct` runs all 64 pairs of subsets of a three-element universe. Gold is independent bitmask subset arithmetic, not the implementation's evaluator. It checks every CLI verdict, declared evidence/authorization boundary and absence of bank writes. Latencies include process startup and are descriptive only. The runner is authored in `subset.hlx`, exported to `subset.rs` for public Cargo users.

Released v0.3.1 negative control: 64/64 cases fail because `check` is absent, exit 1. This establishes that the instrument detects missing capability, not a performance result.

## Artifacts

- `cases.json`: public development fixture pack frozen before first implementation results.
- `cases.sha256`: fixture content identity; any change must explain why and start a new measured run.
- `results.json`: produced only after actual execution; never prefill success.
- Future held-out protocol/results live separately and name exact commit, binary digest, compiler, host, baseline and exclusions.

## Stop conditions

Malformed input acceptance, scope leaks, authority escalation, cost hidden outside measurements or corrupted receipts halt promotion. A null economic result is retained and drives redesign; thresholds are not weakened to make it look like a win. Paid trials, external publication and production use require separate authorization.