Skip to content

Add snippet and excerpt range metadata - #2699

Merged
Widthdom merged 5 commits into
mainfrom
codex/fix-issue1775-1773-1746
May 25, 2026
Merged

Add snippet and excerpt range metadata#2699
Widthdom merged 5 commits into
mainfrom
codex/fix-issue1775-1773-1746

Conversation

@Widthdom

Copy link
Copy Markdown
Owner

Summary

  • Add dropped_match_line_count to compact search snippets so clients can detect match lines omitted by the snippet window.
  • Add highlights[].term_occurrences with per-occurrence line/column/length data while preserving the existing distinct terms list.
  • Add semantic_tokens to excerpt --json with lightweight 1-based ranges and token types.
  • Preserve C# verbatim identifier coordinates by mapping normalized matches back to raw snippet text.

Validation

  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj --filter "FullyQualifiedName~SearchSnippetFormatterTests|FullyQualifiedName~QueryCommandRunnerTests.RunExcerpt_JsonClampsLongSingleLineContentAroundFocus" -p:UseSharedCompilation=false
  • dotnet run --project tools/CodeIndex.Changelog -- check
  • dotnet build CodeIndex.sln --no-restore
  • Adversarial review pass 2: No blocking/actionable issues found.

Documentation and Changelog

  • Updated DEVELOPER_GUIDE.md.
  • Added changelog fragments:
    • changelog.d/unreleased/1746.added.md
    • changelog.d/unreleased/1773.fixed.md
    • changelog.d/unreleased/1775.fixed.md

Fixes #1775
Fixes #1773
Fixes #1746

@Widthdom
Widthdom merged commit 3923ab9 into main May 25, 2026
10 checks passed
@Widthdom
Widthdom deleted the codex/fix-issue1775-1773-1746 branch May 25, 2026 09:38
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