Skip to content

Add MCP truncation metadata and graph pagination - #2704

Merged
Widthdom merged 7 commits into
mainfrom
fix-issue1727-1729
May 25, 2026
Merged

Add MCP truncation metadata and graph pagination#2704
Widthdom merged 7 commits into
mainfrom
fix-issue1727-1729

Conversation

@Widthdom

Copy link
Copy Markdown
Owner

Summary

  • Add truncated and more_available metadata to capped MCP search and graph result payloads.
  • Add offset pagination for MCP graph tools (references, callers, callees) with next_offset on truncated pages.
  • Keep search as truncation-only metadata and cover filtered references pagination so using-static suppression cannot skip visible rows.

Validation

  • dotnet build
  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj --filter "FullyQualifiedName~SearchReferences_ExactCSharpUsingStaticFilter_PaginatesPastSuppressedRows|FullyQualifiedName~McpServerTests.ToolsCall_Callers_TruncatedResponseIncludesNextOffsetAndPages"
  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj --filter "FullyQualifiedName~McpServerTests|FullyQualifiedName~DbReaderTests" (run during adversarial review)
  • dotnet run --project tools/CodeIndex.Changelog -- check
  • dotnet ./src/CodeIndex/bin/Debug/net8.0/cdidx.dll status --check --json
  • Codex adversarial review: No blocking/actionable issues found.

Documentation and Changelog

  • Updated USER_GUIDE.md for MCP truncation and graph pagination metadata.
  • Added changelog.d/unreleased/1727.fixed.md.
  • Added changelog.d/unreleased/1729.added.md.

Follow-up Candidates

  • None.

Fixes #1727
Fixes #1729

@Widthdom
Widthdom marked this pull request as ready for review May 25, 2026 08:51
@Widthdom
Widthdom merged commit 78406ab into main May 25, 2026
10 checks passed
@Widthdom
Widthdom deleted the fix-issue1727-1729 branch May 25, 2026 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant