Releases: thegoodguysla/myco-brain
Myco Brain 1.2.8
[1.2.8] — 2026-06-18
Version alignment only — no functional changes. The npm package was bumped to
1.2.8 during publishing (the compiled output is identical to 1.2.6); this entry
brings the documented history in line with the published version, and adds the
mcpName field (io.github.thegoodguysla/myco-brain) for the Official MCP
Registry.
Myco Brain 1.2.6
[1.2.6] — 2026-06-17
An agent-experience release: the agent contract now teaches Myco as the
adjudication engine it is, and the doctor verifies your setup for real instead of
trusting config. No tool-contract changes (the brain_* inputs/outputs are
unchanged; brain_ingest gains an additive extraction field). No migrations.
Changed
- Agent contract rewritten to embody "the program writes the facts, not the
LLM." The runtime contract, the pasteable CLAUDE.md / .cursorrules / AGENTS.md
manual, thebrain_*tool descriptions, and the website now teach the
source-first write ladder (ingest a source -> propose a claim -> private
save_memory) and the engine's mechanics: compounding confidence across
independent sources, supersede-don't-overwrite on conflict, provenance via
brain_why, and propose -> review -> promote.brain_save_memoryis honestly
fenced as a private scratchpad, never workspace truth. The runtime contract is
single-sourced so the surfaces cannot drift (CI guard:npm run check:contract-drift).
Added
mycobrain-doctornow verifies live, not just config. For the local Ollama
path it pings the server, confirms the model is pulled, and runs a real embed
and generation ("live-verified"); it adds an extraction-backlog check and a
--fixmode that offers to pull missing models.brain_ingestreturns an
honestextraction: "graph" | "search-only"receipt so an agent knows whether
a fact graph was actually built from the source.- Agent-contract eval harness (
npm run eval:contract, gated on
ANTHROPIC_API_KEY): scores whether an agent routes to the right tool across 20
adversarial scenarios, so the contract is measured and regression-guarded.
Myco Brain 1.2.5
[1.2.5] — 2026-06-17
A frictionless-install and value-surfacing release. No tool-contract changes —
every brain_* input is unchanged; the new response fields below are additive and
optional. No migrations.
Added
npx @mycobrain/install— one command to connect any client. A new
installer (mycobrain-install, fronted by the@mycobrain/installlauncher)
detects your MCP client and writes the right config for Claude Code, Claude
Desktop, Cursor, Codex, or Windsurf (with--printsnippets for Zed, Continue,
Cline), then runs onboarding. Flags:--client,--all,--print,--scope,
--no-onboard.- Onboarding now indexes your own repo (opt-in). On a fresh brain,
mycobrain-onboardasks before indexing the current project, then proves recall
on your own code in a fresh context — the fastest felt "it just knew", with no
export wait. Decline to leave the workspace untouched;--tourruns on
throwaway sample data instead. - "Recalled from your memory" attribution.
brain_recall_memoryand
brain_context_packattach an optionalattributioncredit line that decays as
the workspace matures (BRAIN_ATTRIBUTION,BRAIN_ATTRIBUTION_DECAY). It rides
in a structured field, never the result body. - Pushed stats.
brain_context_packadds a once-per-sessionsession_greeting
("Myco has N facts indexed for this workspace");brain_save_memoryadds a
log-spacedmilestonetoast (10/50/100/250, then every 250). mycobrain-ingest --watch-downloads. Opt-in watcher that auto-imports a
ChatGPT or Claude export.zipthe moment it lands in~/Downloads.- Paste-anywhere agent instructions.
mycobrain-installprints, and
docs/agent-instructions.mddocuments, a portable CLAUDE.md /.cursorrules/
AGENTS.md contract for when to recall, save, and cite.
Myco Brain 1.2.4
[1.2.4] — 2026-06-16
A reliability, security, and docs release. No tool-contract changes — the
brain_* MCP tool inputs and outputs are unchanged. Includes two database
migrations (052, 053); apply on upgrade. (The 1.2.3 release was a docs-only
benchmark correction; this release ships the prelaunch engine hardening that landed
afterward.)
Fixed
- Extraction-worker durability. A worker that crashed or restarted mid-chunk
left that chunk stranded inprocessingforever, and a retry-exhausted chunk was
mislabeledpendinginstead offailed. The worker now reclaims stale
processingchunks once their lease expires and marks retry-exhausted chunks
terminallyfailed. Proof:npm run test:reliability. - Contradiction / supersession robustness. Concurrent contradictions of the
same functional fact are serialized (no two active objects can result), predicate
matching is separator-insensitive (reports_to≡reports to), and the claims
ledger no longer duplicates on re-fired contradictions. Proof:npm run test:contradiction. - Schema-proposal corroboration counts distinct documents.
seen_countis
derived from the true distinct-source set, so two documents alternating can no
longer reach the auto-promote gate;brain_whysource counts are per fact, not
per edge row. Proof:npm run test:proposal-sources.
Changed
- Workspace-scoped dynamic type catalogs. Under
BRAIN_SCHEMA_AUTO_PROMOTE=1, a
workspace's auto-promoted entity-kind / relation-type names were written into the
global catalog (visible to other workspaces). Promoted types are now scoped to
their workspace; the canonical seed stays global. Proof:npm run test:schema-promotion.
Security
form-dataadvisory (CRLF injection). Resolved the transitiveform-data
dependency pulled via@anthropic-ai/sdk;npm auditreports 0 vulnerabilities.- stdio auth hardened (defense-in-depth). The stdio MCP server now derives
agent/workspace identity from the environment and ignores caller-supplied
api_key/workspace_id/agent_idby default — set
BRAIN_TRUST_REQUEST_IDENTITY=1to opt back in for a real multi-tenant gateway —
and a service-role JWT must now equalBRAIN_SERVICE_ROLE_KEYrather than
merely look like a JWT. Closes a prompt-injection path to another workspace in a
multi-tenant deployment; no change for single-tenant self-host (identity already
came from env). Proof:auth.test.ts.
Docs
- README / SECURITY: honest RLS/superuser disclosure (the default
brainrole is a
Postgres superuser that bypasses RLS — multi-tenant isolation binds only under the
least-privilegebrain_approle), edge survival cited as ~80% (11–12 of 14,
≥75% gate) rather than a bare 79%, and a reframed comparison table. Documented
thebrain_searchrerankerargument. The LongMemEval headline (73.6% oracle QA)
is now backed by committed n=500 result files so it reproduces from a clone. - Added a consolidated environment-variable reference to the README and
documented the identity varsBRAIN_TRUST_REQUEST_IDENTITY,BRAIN_AGENT_ID, and
BRAIN_SERVICE_ROLE_KEY(with a matching.env.example); corrected the
api-reference note that per-callworkspace_id/api_keyare honored on stdio
(they are ignored by default post stdio-auth hardening).
Migrations
20260616000052_workspace_scoped_catalogs.sql20260616000053_schema_proposal_distinct_sources.sql
v1.1.0 — keyless semantic search, direction-aware graphs, dynamic schema (phase 1)
Fixed
- Relation endpoint recovery — graph edges now survive small-model
extraction. Small local models frequently emit a correct relation while
omitting one endpoint fromentities; the worker's anti-hallucination
guard (relations never create entities) then silently dropped the edge.
Measured on the gold fixture withllama3.2:3b: 0% of emitted relations
had both endpoints listed — i.e. zero graph edges survived on a fresh
keyless install.extract()now runs a best-effort second pass that asks
the model to classify exactly the missing endpoint names against the same
text (example-anchored prompt; anything beyond the requested names is
discarded). Edge survival: 0% → 79%, direction accuracy unchanged at
93%; the remainder are junk phrase-objects that are correctly rejected.
The direction check now also measures and gates endpoint completeness
(BRAIN_ENDPOINT_MIN_COMPLETENESS, default 0.75).
Changed
- Relationship extraction is now direction-aware. The extraction prompt
states that relations are directed (subject → predicate → object), defines
subject vs. object, and gives worked directional examples (including the
passive-voice trap that flips small models). On the gold fixture this lifts
llama3.2:3bdirection accuracy from ~79% to ~93%. The prompt and provider
calls moved toextraction.ts(importable without starting the worker loop).
Added
- Strict curation mode.
BRAIN_REQUIRE_HUMAN_REVIEW=1disables all
auto-promotion: every extracted entity and relation waits in the review
queue (proposed_*, state=pending) and nothing reaches the canonical
graph without a human decision — the LLM writes proposals, the human writes
the graph. Covered by a differential end-to-end check
(npm run test:strict-mode, no LLM required). - Seeded relationship-type catalog. Migration
20260611000048seeds
relation_typeswith the eight canonical predicates the extraction prompt
teaches (idempotent; tolerant ofASSIGNED_TO-style naming from existing
deployments). The dynamic-schema known-predicate filter now has a real
baseline instead of an empty catalog. - Dynamic schema (phase 1) — propose and surface. The extraction worker now
records entity kinds and relationship predicates it observes that aren't in
theentity_kinds/relation_typescatalogs as pending
schema_proposalsrows (provenance-tagged, deduped per workspace by the
unique type+name constraint; min confidence via
BRAIN_SCHEMA_PROPOSAL_MIN_CONFIDENCE, default 0.6, inclusive).brain_stats
gains aschemasection and the summary surfaces "Brain proposed N new
types from your data (pending review)". Promotion stays manual — nothing
auto-applies: entities with a not-yet-cataloged kind stay in the review queue
and are not auto-promoted into the canonical graph (so a novel "product"
can never be mislabeled as an organization or fuzzy-merged into one).
Migration20260611000047(idempotent) extends theproposal_typeCHECK
withentity_kind; the proposal write runs under a savepoint, so a database
that hasn't applied the migration degrades to "no proposals recorded" instead
of failing extraction. The extraction prompt now lets the model name a novel
kind when none of the canonical four fits; the prompt's own example
predicates are treated as canonical and never proposed as "new". - Direction regression test.
src/extraction-direction.tsdefines a
gold fixture of clearly-directed facts (fromexamples/demo-corpus, with
passive-voice traps) and ascoreDirectionscorer (deterministic unit tests
inextraction-direction.test.ts).test/extraction-direction-check.mjs
(npm run test:direction) measures a model's directed accuracy and fails
belowBRAIN_DIRECTION_MIN_ACCURACY(default 0.8); it skips when no real
extraction model is configured, so the keyless CI quickstart is unaffected. - Recommended-model + measured-accuracy note in
docs/relationship-extraction.md. - Local (keyless) vector search via Ollama
nomic-embed-text(768d),
selected withBRAIN_EMBED_PROVIDER=ollama(auto-selected when an Ollama
base URL is configured and no OpenAI key is present). Runs alongside the
existing OpenAItext-embedding-3-small(1536d) path; each provider stores
vectors in its own table (chunks_ollama_nomic/chunks_openai3small), so
switching providers never causes a dimension clash.brain_search,
brain_context_pack, andbrain_recall_memoryjoin the active provider's
table, andbrain_statscounts embedded chunks across both. Migration
20260611000046_chunks_ollama_nomic.sql(idempotent) adds the 768d table.
Semantic search now works with no hosted API key at all.