Releases: davesheffer/hunch
Release list
v1.7.0 — user-selected synthesis providers
Subscription choice without vendor lock-in
Hunch now detects the supported coding-assistant CLIs available locally and never silently guesses which subscription to bill.
- Set a local choice with
hunch provider claude-cli,codex-cli,cursor-agent, ordeterministic. HUNCH_SYNTH_PROVIDERremains a per-shell / CI override.- Auto mode uses a subscription only when exactly one supported CLI is available; multiple candidates use the free deterministic fallback.
- The same policy now covers capture, verification, auto-review, and wiki prose.
- The subscription-only invariant and generated assistant grounding are provider-agnostic.
Validation
- Typecheck
- 492 passing tests (1 skipped)
- Core and VS Code builds
- Strict architectural conformance
v1.6.0 — agent-agnostic lifecycle hooks
What's Changed
- feat: add agent-agnostic lifecycle hooks by @davesheffer in #7
Full Changelog: v1.5.0...v1.6.0
Hunch v1.5.0 — Change Gate and private workflows
One working loop for every agent
Hunch 1.5.0 adds a deterministic Change Gate across the CLI, MCP, and VS Code, so every change can start with the decisions, constraints, blast radius, and bug history that already matter.
Highlights
- Change Gate everywhere — inspect a working diff or target from the CLI, any MCP client, or VS Code.
- Working-tree checks — assess staged, unstaged, and untracked work before a commit with
hunch check --working --strict --blast. - Private overlays that stay private — private captures, reviews, causal receipts, and deterministic local synthesis remain in the local overlay; public CI is explicitly public-only.
- Safer agent integrations — client-agnostic MCP updates and safer VS Code command execution.
- Product refresh — a new product README, VS Code README, launch post, and refreshed static site.
Install
npm i -g @davesheffer/hunch@1.5.0Verification
- 480 passing tests (1 intentionally skipped)
- TypeScript and VS Code extension builds pass
- npm provenance published from the
v1.5.0tag
v1.2.2
Fixes
- capture: auto-commit outcome reported truthfully — a skipped commit (safety backstop, held lock, empty stage) is no longer claimed as committed; a deferred overlay push says so with a retry hint
- cli: friendly Node-version gate — Node < 22.13 gets an actionable upgrade message instead of a raw ERR_UNKNOWN_BUILTIN_MODULE; the edit-hook stays silent exit 0 so an old Node never blocks an edit
- indexer: reindex merges components per id — curated responsibility/owners/status, synthesis-raised fragility, and upgraded provenance survive; unchanged components are byte-identical (no more timestamp churn in committed .hunch/)
CI
- release workflow publishes on version-tag push (npm provenance) and no-ops green when the version is already on npm
v1.2.0 — your agent greps; a grounded agent asks
hunch structure / MCP hunch_structure
Agents burn grep/glob rounds every session rediscovering structure the graph already holds. One call now serves it:
- (no target) — repo map: components + directories by symbol weight
- a directory — its files, each with symbols and fan-in
- a file — outline: symbols, fan-in/out, and who calls them
- a symbol name — exact definition site(s) + one-hop callers/callees
Deterministic, read-only, no LLM — and the MCP description tells agents to call it before searching, so it names the file to read on the first try.
Also: hunch runbook --find reindexes before searching.
🤖 Generated with Claude Code
v1.1.1 — Claude Code plugin
One-step install for Claude Code
/plugin marketplace add davesheffer/hunch
/plugin install hunch@hunch
Ships the hunch_* MCP tools plus five skills: /hunch:capture, /hunch:heal, /hunch:why, /hunch:fix, /hunch:fragile. Then hunch init per repo builds the graph.
Also:
- The repo now commits a curated slice of its own graph — clone it and
hunch why src/store/db.tsanswers on day one, guards fire with citations. hunch runbook --findreindexes first, so runbooks written out-of-band (MCP, another machine) are found immediately.
🤖 Generated with Claude Code
v1.1.0 — AGENTS.md as a drift surface
Memory that gates, not just recalls
Markdown topic anchors — AGENTS.md / CLAUDE.md as a drift surface
The doc≠graph spoke now covers the prose files the ecosystem funnels team knowledge into:
<!-- hunch:topic auth.session --> grounds only
<!-- hunch:topic auth.session dec_a1b2c3d4e5 --> pinned to a decision- Pre-edit grounding: editing an anchored markdown file injects each topic's current decision, what it rejected, and an inline stale-pin warning — the graph outranks the prose being edited.
hunch drift: a pin to a superseded decision firesdoc-anchor-stale(CI-gateable, non-zero exit); a pin to a missing decision firesdoc-anchor-dangling. Deterministic — only an explicit pin can fire, never a semantic guess.hunch heal: renders prose≠graph findings with the reconcile-then-re-pin action. Read-only, never rewrites prose.
hunch impact + hunch path
hunch impact [base|--commit]/ MCPhunch_pr_impact— a change's impact surface: dependent files reached, invariants direct + via blast radius, and the decisions concerned. Composed from the same primitives as the gate, so impact and gating can never disagree.hunch path <A> <B>/ MCPhunch_path— shortest dependency chain between any two symbols/files/components, walked in either direction.
Also: hunch heal now covers every drift kind (dead-ref, dangling supersede, doc-stale) with a next action, and findRoot stops at the .git boundary so a stray ancestor .hunch can never hijack a fresh repo.
Full suite: 394 tests green.
🤖 Generated with Claude Code
v1.0.0 — zero native SQLite dependency
1.0 — node:sqlite
The derived index (FTS5 search, dependency graph, vectors) now runs on Node's built-in node:sqlite instead of better-sqlite3.
What this removes:
- Install-time native builds — no more
prebuild-install(deprecated upstream), nonode-gypfallback failures - Windows
EPERMon global upgrades from a lockedbetter_sqlite3.node— the binding now ships inside the Node binary - ~130 transitive install packages
Breaking:
- Requires Node ≥ 22.13 (first LTS line with
node:sqliteunflagged; Node 20 is past EOL since April 2026)
FTS5 ranking, WAL, recursive-CTE graph walks, and stored embeddings are unchanged — no reindex needed. Full test suite (386 tests) green.
Also: fixed a Windows path bug in singlesource.test.ts (worktree path built with split("/")).
🤖 Generated with Claude Code
v0.40.0 — single source of truth + auto-commit by default
Two behavior-changing features (existing users: your defaults change on upgrade).
Single source of truth for memory
hunch shared --repo <url> is now unified — every capture (decisions, bugs, constraints, runbooks) routes through one resolver to one home, so nothing splits between the public and shared stores.
- Worktree-stable: the overlay anchors at the main worktree root, so a
git worktree removecan no longer silently take the store down. - Team auto-discovery: a committed
.hunch/team.jsonadvertises the store — a fresh clone auto-connects onhunch init, and any MCP-connected agent or CI job wires up the same way on server start. Everyone, on every branch, resolves the same memory. --reponever silently ignored: same remote → pull; no remote → attach + merge + push; different remote → hard refusal.hunch doctornow reports the true mode and shouts a dead-pointer finding instead of silently reading empty memory.- Mode is persisted with no schema bump — existing setups keep their current behavior until you explicitly re-run
hunch shared.
Auto-commit ON by default, in every mode
A capture is now committed to whichever store it lands in without being asked: a private/shared overlay repo is committed and pushed; the public .hunch/ is committed only and rides your next push — Hunch never pushes or merges your code branch. Opt out with --no-auto-commit on init / private / shared.
Security
.hunch/team.json is committed, so in a freshly cloned untrusted repo its URL is attacker-controlled and auto-consumed on MCP start. The clone now runs behind a strict URL allowlist (https / ssh / git / scp-style only) plus -- and a protocol kill-switch, so a smuggled git flag or ext:: transport can never turn opening a repo into code execution.
Full test suite: 385 pass.
v0.39.0 — decision-grounding
Topic-anchored decisions with read-time grounding, doc≠graph drift detection, a gated capture flow, and heal.
New
topicanchor on decisions + the query contract (current/history/rejected/collisions) — the join key for drift detection. Defaulted, so existing graphs need no migration.- Read-time grounding — the PreToolUse hook now surfaces a file's topic-anchored decisions with doc-precedence framing ("follow the graph, not a stale doc") + what they rejected.
- doc≠graph drift — a deterministic
anchor-stalecheck (a file orphaned to a superseded decision) inhunch drift(CI-gateable) anddoctor. - Capture —
hunch_capture_decision(grilling protocol + capture-session token) andhunch_current_decision. The existinghunch_record_decisionis now gated: a store-scoped uniqueness guard refuses a second live decision per topic (a cross-store supersede that can't close its target is refused, never silently leaving two live), with an optional capture token. hunch reconcile-topics— surfaces >1-live-per-topic collisions a git merge can introduce.hunch heal+/capture/healslash commands (scaffolded byhunch init).
Compatibility: fully additive and backward-compatible — topic defaults to null, no schema-version bump, existing decisions load unchanged.