TL;DR: two MCP tools report a different caller count for into_events (repo-a/src/input/transcript/entry.rs:267), the same symbol at the same location, in the same repo. find_most_complex_functions says 10 direct callers; analyze_relationships(find_callers) says 0. They may be reading different edge sources, or counting under different edge semantics by design.
Environment
- memtrace 0.6.0, darwin-arm64
- engine in remote mode on 127.0.0.1:50051
- repo
repo-a, indexed, 19206 nodes / 45938 edges
Repro
find_most_complex_functions(repo_id=repo-a, top_n=10)
-> into_events (repo-a/src/input/transcript/entry.rs:267): "direct_callers": 10
analyze_relationships(repo_id=repo-a, target=into_events, query_type=find_callers, depth=2)
-> {"count": 0, "found": true, "results": [], "_backend": "memdb"}
Expected
The two surfaces either agree on the caller count for a single symbol, or the output documents why they differ (distinct edge semantics, direct versus transitive).
Actual
10 versus 0. For this captured symbol, found: true rules out a missing-symbol explanation, so the gap is not "symbol not in graph" here. The two tools likely count over different edge relations, though I have not confirmed which.
Why it matters
The two tools may use different edge semantics by design (direct_callers could mean direct edges, find_callers could resolve transitively or over a different relation). That is a legitimate split. The friction is the agent-facing one: find_most_complex_functions ranks technical debt by direct_callers, and analyze_relationships is the tool an agent reaches for to list those callers. When one says 10 and the other says 0, the ranking points at callers the second tool cannot enumerate, with nothing in the output to explain the gap.
Ask
Which edge relation backs each count (CALLS only, or CALLS plus REFERENCES/INSTANTIATES), and which one is authoritative? If direct_callers includes reference edges that find_callers excludes, a one-line doc note would already clear the confusion. Aligning the two counts would clear it better. I might be missing a deliberate reason for the split, but if not, happy to send a PR once the intended semantics are settled.
TL;DR: two MCP tools report a different caller count for
into_events(repo-a/src/input/transcript/entry.rs:267), the same symbol at the same location, in the same repo.find_most_complex_functionssays 10 direct callers;analyze_relationships(find_callers)says 0. They may be reading different edge sources, or counting under different edge semantics by design.Environment
repo-a, indexed, 19206 nodes / 45938 edgesRepro
Expected
The two surfaces either agree on the caller count for a single symbol, or the output documents why they differ (distinct edge semantics, direct versus transitive).
Actual
10 versus 0. For this captured symbol,
found: truerules out a missing-symbol explanation, so the gap is not "symbol not in graph" here. The two tools likely count over different edge relations, though I have not confirmed which.Why it matters
The two tools may use different edge semantics by design (
direct_callerscould mean direct edges,find_callerscould resolve transitively or over a different relation). That is a legitimate split. The friction is the agent-facing one:find_most_complex_functionsranks technical debt bydirect_callers, andanalyze_relationshipsis the tool an agent reaches for to list those callers. When one says 10 and the other says 0, the ranking points at callers the second tool cannot enumerate, with nothing in the output to explain the gap.Ask
Which edge relation backs each count (
CALLSonly, orCALLSplusREFERENCES/INSTANTIATES), and which one is authoritative? Ifdirect_callersincludes reference edges thatfind_callersexcludes, a one-line doc note would already clear the confusion. Aligning the two counts would clear it better. I might be missing a deliberate reason for the split, but if not, happy to send a PR once the intended semantics are settled.