mirror of
https://github.com/colbymchenry/codegraph.git
synced 2026-09-19 07:34:57 +08:00
22333c1535
Lands the "explore overhaul" arc — make codegraph_explore good enough to be a
Read-replacement, and cut the tool surface to match.
Tool surface
- Removed codegraph_context (fuzzy-input, surfaced the wrong feature) and
codegraph_trace (explore-flow already does its job; the agent under-picked it).
codegraph_explore is now the single PRIMARY tool; codegraph_node is the
after-explore depth tool (labeled SECONDARY).
- Folded an always-on, compact "Blast radius" (dependents + covering tests,
locations only) into explore output.
Coverage (general AST rule, no library names)
- Extract function-valued properties of an object literal that is an exported
const's value — directly, or RETURNED by an initializer call incl. middleware
wrappers: export const useStore = create((set,get) => ({ fetchUser: ... })).
Covers Zustand/Redux/Pinia/MobX/handler-maps. Store actions are now real nodes,
so codegraph_node / codegraph_callers resolve them (was "not found"); resolution
falls out of exact-name matching for getState()/destructured/in-store calls.
Overload disambiguation (Swift/Go/Java/C# same-named methods)
- codegraph_node returns EVERY matching definition for an ambiguous name (full
bodies packed to a char budget + the rest listed by file:line) instead of
guessing one wrong overload + a dead-end note.
- codegraph_explore is overload-aware: a PascalCase type token in the query biases
an overloaded name to that type's own def (DataRequest task -> DataRequest's task,
not the abstract base / a same-named method elsewhere); files where the agent
named a symbol now sort first.
Budget + ranking
- Reverted the flat 100K explore output budget to the tiered getExploreOutputBudget
(the flat budget produced ~67K responses that overflowed the agent's per-tool
output cap and FORCED a Read); bounded the central whole-file dump so a large
central file sections into methods instead of dumping whole.
- Graph-connectivity (RWR) file ranking; the relevance gate no longer prunes a
file the agent named or one matching >=2 distinct named query terms.
- isDistinctiveIdentifier precision fix: a plain dictionary word in the query can
no longer hijack ranking by exact-matching an unrelated symbol.
Validation (agent A/B, why-Read diagnostic)
- amniservices (RN/Expo): 5 reads -> 0 (store coverage).
- gin / Alamofire (README's thinnest-margin repos): no regression from the tool
removals; multiple fully-clean (0 read / 0 grep) runs after the overload fixes.
- Full suite green (pre-existing npm-shim network failures excepted).
Docs
- README: MCP Tools table, diagram, tool-by-intent, permissions, and CLI reference
no longer advertise the removed context/trace tools.
- CLAUDE.md + docs/design: forward guidance and surfacing/validation references
point at codegraph_explore; design docs carry dated banners noting the removal.
Tests: new object-literal-methods, context-ranking, explore-blast-radius; updated
symbol-lookup + pr19-improvements for the all-overloads codegraph_node contract.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>