local-codebase-indexer 0.9.1__tar.gz → 1.0.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (159) hide show
  1. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/AGENTS.md +12 -1
  2. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/CHANGELOG.md +22 -1
  3. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/CONTRIBUTING.md +12 -1
  4. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/PKG-INFO +13 -10
  5. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/README.md +8 -8
  6. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/README.zh-CN.md +8 -8
  7. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/README.zh-TW.md +8 -8
  8. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/TODO.md +6 -2
  9. local_codebase_indexer-1.0.1/assets/impact-report.html +384 -0
  10. local_codebase_indexer-1.0.1/assets/impact-report.png +0 -0
  11. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/README.md +10 -0
  12. local_codebase_indexer-1.0.1/benchmarks/client-compatibility.json +34 -0
  13. local_codebase_indexer-1.0.1/benchmarks/codex-tool-events.json +389 -0
  14. local_codebase_indexer-1.0.1/benchmarks/maintainer-acceptance.json +188 -0
  15. local_codebase_indexer-1.0.1/benchmarks/maintainer-project-results.json +1251 -0
  16. local_codebase_indexer-1.0.1/benchmarks/maintainer-project.json +136 -0
  17. local_codebase_indexer-1.0.1/benchmarks/performance-results.json +441 -0
  18. local_codebase_indexer-1.0.1/benchmarks/performance.py +281 -0
  19. local_codebase_indexer-1.0.1/benchmarks/real-project-results.json +9572 -0
  20. local_codebase_indexer-1.0.1/benchmarks/real-projects.json +1034 -0
  21. local_codebase_indexer-1.0.1/benchmarks/real_projects.py +279 -0
  22. local_codebase_indexer-1.0.1/benchmarks/v1-tool-comparison-queries.jsonl +96 -0
  23. local_codebase_indexer-1.0.1/benchmarks/v1-tool-comparison.json +148 -0
  24. local_codebase_indexer-1.0.1/docs/contracts/codebase_get_data_access.json +412 -0
  25. local_codebase_indexer-1.0.1/docs/contracts/codebase_get_optimized_context.json +52 -0
  26. local_codebase_indexer-1.0.1/docs/contracts/codebase_get_symbol_relations.json +48 -0
  27. local_codebase_indexer-1.0.1/docs/contracts/codebase_impact_analysis.json +52 -0
  28. local_codebase_indexer-1.0.1/docs/contracts/codebase_index_doctor.json +48 -0
  29. local_codebase_indexer-1.0.1/docs/contracts/codebase_index_status.json +48 -0
  30. local_codebase_indexer-1.0.1/docs/contracts/codebase_semantic_search.json +95 -0
  31. local_codebase_indexer-1.0.1/docs/mcp-tools.json +1038 -0
  32. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/reference.md +17 -2
  33. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/reference.zh-CN.md +18 -3
  34. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/reference.zh-TW.md +19 -4
  35. local_codebase_indexer-1.0.1/docs/v1-readiness.md +137 -0
  36. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/__init__.py +1 -1
  37. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/cli.py +64 -11
  38. local_codebase_indexer-1.0.1/local_codebase_indexer/contracts.py +169 -0
  39. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/core.py +44 -26
  40. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/cscalls.py +5 -4
  41. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/csdata.py +46 -28
  42. local_codebase_indexer-1.0.1/local_codebase_indexer/dataflow.py +519 -0
  43. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/db.py +6 -2
  44. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/impact.py +14 -7
  45. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/langparse.py +20 -4
  46. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/mcp_server.py +78 -21
  47. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/pagination.py +3 -3
  48. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/query.py +39 -17
  49. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/relations.py +16 -4
  50. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/rendering.py +3 -0
  51. local_codebase_indexer-1.0.1/local_codebase_indexer/reports.py +201 -0
  52. local_codebase_indexer-1.0.1/local_codebase_indexer/setup_project.py +98 -0
  53. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/sqlaccess.py +6 -1
  54. local_codebase_indexer-1.0.1/local_codebase_indexer/sqlidentity.py +121 -0
  55. local_codebase_indexer-1.0.1/local_codebase_indexer/vector_cache.py +68 -0
  56. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer.egg-info/PKG-INFO +13 -10
  57. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer.egg-info/SOURCES.txt +35 -1
  58. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer.egg-info/requires.txt +5 -0
  59. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/pyproject.toml +3 -2
  60. local_codebase_indexer-1.0.1/scripts/check_mcp_clients.py +437 -0
  61. local_codebase_indexer-1.0.1/scripts/export_contracts.py +54 -0
  62. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/server.json +2 -2
  63. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_dataaccess.py +59 -0
  64. local_codebase_indexer-1.0.1/tests/test_v1_cache.py +77 -0
  65. local_codebase_indexer-1.0.1/tests/test_v1_contracts.py +191 -0
  66. local_codebase_indexer-1.0.1/tests/test_v1_scope.py +329 -0
  67. local_codebase_indexer-1.0.1/tests/test_v1_workflows.py +136 -0
  68. local_codebase_indexer-0.9.1/local_codebase_indexer/dataflow.py +0 -333
  69. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/.claude-plugin/marketplace.json +0 -0
  70. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/CLAUDE.md +0 -0
  71. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/LICENSE +0 -0
  72. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/MANIFEST.in +0 -0
  73. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/assets/demo-output.txt +0 -0
  74. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/assets/demo-preview.png +0 -0
  75. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/assets/demo-report.json +0 -0
  76. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/assets/demo.gif +0 -0
  77. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/baseline.json +0 -0
  78. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/compare_tools.py +0 -0
  79. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Auth/LoginService.cs +0 -0
  80. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Controllers/LotController.cs +0 -0
  81. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Controllers/ScrapController.cs +0 -0
  82. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Data/MesDbContext.cs +0 -0
  83. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Legacy/frmChangeLine.frm +0 -0
  84. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Models/DrillBreakEvent.cs +0 -0
  85. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Models/Lot.cs +0 -0
  86. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Models/ScrapRecord.cs +0 -0
  87. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Printing/LabelPrinter.cs +0 -0
  88. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Repositories/LotRepository.cs +0 -0
  89. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Repositories/ScrapRepository.cs +0 -0
  90. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Services/IScrapService.cs +0 -0
  91. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Services/InspectionService.cs +0 -0
  92. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Services/LotService.cs +0 -0
  93. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Services/ScrapService.cs +0 -0
  94. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Sql/MES_Lot.sql +0 -0
  95. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Sql/usp_Inspection_Report.sql +0 -0
  96. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Sql/usp_Lot_UpdateStatus.sql +0 -0
  97. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Sql/usp_Scrap_Insert.sql +0 -0
  98. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Utils/DateRangeHelper.cs +0 -0
  99. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Utils/PartNumberDecoder.cs +0 -0
  100. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Web/scrapForm.ts +0 -0
  101. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/Web.config +0 -0
  102. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/corpus/tools/export_report.py +0 -0
  103. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/navigation_task.json +0 -0
  104. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/queries_project.json +0 -0
  105. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/queries_stdlib.json +0 -0
  106. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/queries_synthetic.json +0 -0
  107. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/run_benchmark.py +0 -0
  108. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/tool-comparison-queries.jsonl +0 -0
  109. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/benchmarks/tool-comparison.json +0 -0
  110. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/bin/indexer +0 -0
  111. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/case-study.md +0 -0
  112. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/comparison-evidence.json +0 -0
  113. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/discovery.md +0 -0
  114. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/launch/community.en.md +0 -0
  115. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/launch/community.zh-TW.md +0 -0
  116. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/launch/directory-entry.md +0 -0
  117. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/sql-legacy-support.md +0 -0
  118. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/docs/tool-comparison.md +0 -0
  119. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/index.md +0 -0
  120. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/llms.txt +0 -0
  121. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/__main__.py +0 -0
  122. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/callgraph.py +0 -0
  123. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/context.py +0 -0
  124. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo.py +0 -0
  125. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Controllers/OrdersController.cs +0 -0
  126. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Data/OrderRepository.cs +0 -0
  127. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Models/Order.cs +0 -0
  128. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/README.md +0 -0
  129. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Services/IOrderService.cs +0 -0
  130. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Services/OrderService.cs +0 -0
  131. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Sql/Sales_OrderHeader.sql +0 -0
  132. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Sql/usp_ApproveOrder.sql +0 -0
  133. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/demo_project/Views/Orders/Details.cshtml +0 -0
  134. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/embedder.py +0 -0
  135. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/evaluation.py +0 -0
  136. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/locking.py +0 -0
  137. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/query_common.py +0 -0
  138. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/scanner.py +0 -0
  139. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/synonyms.py +0 -0
  140. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/textdecode.py +0 -0
  141. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer/vbdata.py +0 -0
  142. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer.egg-info/dependency_links.txt +0 -0
  143. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer.egg-info/entry_points.txt +0 -0
  144. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/local_codebase_indexer.egg-info/top_level.txt +0 -0
  145. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/plugins/local-codebase-indexer/.claude-plugin/plugin.json +0 -0
  146. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/plugins/local-codebase-indexer/.mcp.json +0 -0
  147. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/scripts/release_assets.py +0 -0
  148. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/scripts/render_demo.py +0 -0
  149. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/setup.cfg +0 -0
  150. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_demo.py +0 -0
  151. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_evaluation.py +0 -0
  152. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_indexer.py +0 -0
  153. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_navigation_stability.py +0 -0
  154. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_onnx_plumbing.py +0 -0
  155. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_provenance_boundaries.py +0 -0
  156. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_release_assets.py +0 -0
  157. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_reliability.py +0 -0
  158. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_sql_regressions.py +0 -0
  159. {local_codebase_indexer-0.9.1 → local_codebase_indexer-1.0.1}/tests/test_tool_comparison.py +0 -0
@@ -80,7 +80,7 @@ Run `local-codebase-indexer demo` without a database or model. It uses a tempora
80
80
 
81
81
  ## SQL and legacy-source correctness (0.9.0)
82
82
 
83
- - Run `python -m ruff check local_codebase_indexer scripts benchmarks/compare_tools.py`, `python -m mypy`, and the full pytest suite before publishing. CI covers Linux and Windows on Python 3.10, 3.12, and 3.13.
83
+ - Run `python -m ruff check local_codebase_indexer scripts benchmarks/compare_tools.py benchmarks/real_projects.py benchmarks/performance.py tests/test_v1_*.py`, `python -m mypy`, and the full pytest suite before publishing. CI covers Linux and Windows on Python 3.10, 3.11, 3.12, and 3.13.
84
84
  - Dependency declarations live in `pyproject.toml`; `requirements.txt` was removed to avoid drift.
85
85
  - Source decoding and context extraction handle BOM-tagged UTF-16/UTF-32. True binary files are excluded consistently by scanning and status.
86
86
  - `data-access` has additive `schema_changes` entries (`access=schema`) for table/index DDL. They are not row writers. File-level SQL changes appear in impact with before/current/after labels and source evidence.
@@ -94,3 +94,14 @@ Run `local-codebase-indexer demo` without a database or model. It uses a tempora
94
94
  - SQL object definitions come only from SQL sources; application symbol navigation still includes Python/JS functions.
95
95
  - Index format 10 invalidates older parsed edges and rebuilds them on the first update. Keep package and Registry versions synchronized when preparing a release.
96
96
  - Tool comparisons live in `docs/tool-comparison.md`; keep language READMEs in sync, cite upstream capabilities, and distinguish a literal-search baseline from a full Claude workflow. Do not claim measured speed/token/accuracy superiority without a corresponding experiment.
97
+
98
+ ## SQL evidence and stable contracts (1.0.0)
99
+
100
+ - Index format 11 preserves SQL identity as lossless JSON components. Keep the last-segment key only as an indexed lookup accelerator; never use it alone to identify an object or expand procedure dependencies. Ambiguous short names must not combine confirmed accessors.
101
+ - C# symbol/SQL ownership uses AST byte ranges; same-line methods and overloads must remain separate. Symbol IDs are opaque revision-bound values.
102
+ - `path`, action-specific `programs[].paths`, and `coverage.warnings` explain representative static chains and SQL/C# cutoffs. Never claim complete runtime coverage from `complete_within_limits`.
103
+ - Preserve text MCP responses and the seven names. Structured outputs and corresponding CLI JSON use schema_version 1; keep MCP defaults bounded (5 data-access entries per section, exact pagination, nested truncation metadata) and only unbound nested data for explicit detail=true; export/check docs/contracts with `python scripts/export_contracts.py --check`. Supported old protocol versions must negotiate correctly.
104
+ - `init` writes project-local client configuration only, preserves unrelated settings, rejects conflicts/symlink escapes, and leaves client trust prompts intact. Report export must escape source text, work without remote assets, and require explicit overwrite.
105
+ - Cache vectors only within a configured budget and a committed index revision/embedder identity; scoped searches and other-process updates must not reuse stale/wrong rows. Lexical mode skips vectors and SQL routing; bind cursors to mode.
106
+ - Keep benchmarks/real-projects.json frozen; it has 100 project-authored development questions over three real pinned repositories, not independent user validation. Never edit gold or lower a regression budget to hide a failure. Preserve losses, workload boundaries and raw observations.
107
+ - Actual Claude/Codex transport tests use a deterministic local model stub, not hosted reasoning. Recorded native Codex events verify a prior tool round trip; automatic CI runs SDK + Claude. Review client configuration and normal state-directory/network needs before invoking optional real-client checks.
@@ -1,6 +1,27 @@
1
1
  # Changelog
2
2
 
3
- ## Unreleased
3
+ ## 1.0.1 — 2026-11-20
4
+
5
+ - Program tracing follows interface methods implemented by abstract base classes: an override in a subclass is reached from callers of the interface or base method (`override dispatch`), so data-access `programs` and impact no longer report such pipeline steps as having no known caller.
6
+ - Impact `tables` include accesses made by methods the changed code calls (confirmed / probable calls, up to 4 hops). Each entry carries `depth` and `via_chain`; a `callee_depth_limit` coverage warning marks a cutoff.
7
+ - No index format change; existing indexes keep working.
8
+
9
+ ## 1.0.0 — 2026-11-20
10
+
11
+ - Simplify all three READMEs: remove development-stage notes, repeated benchmarks, and maintainer-specific acceptance narratives; retain practical setup/report commands and source-backed tool comparisons.
12
+
13
+ - Keep BOM-tagged UTF-16/UTF-32 SQL eligible in doctor, matching indexing/status; add separate maintainer-supplied Python workflow/retrieval acceptance.
14
+
15
+ - Preserve four-part SQL identities, delimited dots, explicit USE context, EF schema mappings, and quoted C# stored-procedure names. Return qualified candidates for ambiguous short names; keep unresolved scope under possible instead of confirmed.
16
+ - Use AST byte ranges for compact C# source ownership and distinct same-line overload IDs; preserve differently qualified SQL accesses on the same source line.
17
+ - Add representative source-evidence paths, action-specific page locations, bounded SQL/C# depth controls, and visible cutoff/unavailable-definition warnings, including Git impact metadata.
18
+ - Negotiate supported MCP protocol versions; provide structured results/output schemas and matching CLI JSON metadata while retaining legacy text. Add seven checked-in contracts, a full tool manifest, bounded structured defaults with exact truncation/pagination, retryable busy errors, and official-SDK tests.
19
+ - Add project-local init/configuration, stderr indexing progress, and offline escaped HTML/SVG, Mermaid and JSON impact reports with explicit overwrite handling.
20
+ - Add optional lexical search, soft file diversity, and a bounded revision-aware in-process vector cache; bind cursors to retrieval mode/algorithm.
21
+ - Add 100 frozen navigation questions on three pinned public C# projects, baseline/candidate records, real-client transport evidence using a local mock model, and 10k/50k/100k scaling/update/Git-switch measurements. Preserve retrieval losses and limits on interpretation.
22
+ - Extend Linux/Windows CI to Python 3.11, package the new tests/dependencies, check contracts, run public-code/performance smoke evaluations, and test Claude transport automatically. Codex native tool events are recorded from a manual transport run.
23
+ - Synchronize English/Traditional Chinese/Simplified Chinese README and reference additions; correct obsolete JOIN and index-format guidance.
24
+ - Index format 11 rebuilds older parsed data on the first update. Package and MCP Registry versions are synchronized at 1.0.0.
4
25
 
5
26
  ## 0.9.1
6
27
 
@@ -8,7 +8,7 @@ Use Python 3.10+ in a virtual environment:
8
8
 
9
9
  ```bash
10
10
  python -m pip install -e ".[dev,onnx]" onnx build twine
11
- python -m ruff check local_codebase_indexer scripts benchmarks/compare_tools.py
11
+ python -m ruff check local_codebase_indexer scripts benchmarks/compare_tools.py benchmarks/real_projects.py benchmarks/performance.py
12
12
  python -m mypy
13
13
  python -m pytest -q
14
14
  python -m build
@@ -33,3 +33,14 @@ Add verified questions and expected source locations when a new behavior needs c
33
33
  Public documentation and Release notes use English, with Traditional/Simplified Chinese README translations. Keep generated demo assets in sync by running `python scripts/render_demo.py` after installing `.[media]`.
34
34
 
35
35
  Contributions are under this repository's [MIT license](LICENSE).
36
+
37
+ ## v1 readiness checks
38
+
39
+ Run `python scripts/export_contracts.py --check` and the full tests, including official MCP client schema validation. Optional evaluations:
40
+
41
+ ```bash
42
+ python benchmarks/real_projects.py --baseline-source /path/to/0.9.1-checkout --save /tmp/real-projects.json
43
+ python benchmarks/performance.py --sizes 10000 50000 100000 --save /tmp/performance.json
44
+ ```
45
+
46
+ Use paths suitable for your OS. Questions, pinned sources, gold and budgets are fixed; report losses and failed questions. These are development/public-code/scaling workloads, not independent production accuracy or human investigation studies. Client CLI checks use a deterministic local model; review their configuration/network behavior and normal state-directory needs before running them. See [v1 evidence and limitations](docs/v1-readiness.md).
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: local-codebase-indexer
3
- Version: 0.9.1
3
+ Version: 1.0.1
4
4
  Summary: Trace SQL Server tables to C# callers and Razor pages locally. MCP server and CLI for code search and change impact.
5
5
  Author: sfy257000
6
6
  License-Expression: MIT
@@ -10,7 +10,7 @@ Project-URL: Issues, https://github.com/sfy257000/local-codebase-indexer/issues
10
10
  Project-URL: Documentation, https://github.com/sfy257000/local-codebase-indexer/blob/main/docs/reference.md
11
11
  Project-URL: Case study, https://github.com/sfy257000/local-codebase-indexer/blob/main/docs/case-study.md
12
12
  Keywords: mcp,model-context-protocol,claude-code,code-search,semantic-search,codebase-index,tree-sitter,sqlite,stored-procedure,csharp,dapper,t-sql,call-graph,ai-coding-assistant
13
- Classifier: Development Status :: 4 - Beta
13
+ Classifier: Development Status :: 5 - Production/Stable
14
14
  Classifier: Environment :: Console
15
15
  Classifier: Intended Audience :: Developers
16
16
  Classifier: Programming Language :: Python :: 3
@@ -31,6 +31,7 @@ Requires-Dist: tree-sitter-javascript
31
31
  Requires-Dist: tree-sitter-typescript
32
32
  Requires-Dist: numpy
33
33
  Requires-Dist: pathspec>=0.12.1
34
+ Requires-Dist: tomli>=2; python_version < "3.11"
34
35
  Provides-Extra: onnx
35
36
  Requires-Dist: onnxruntime; extra == "onnx"
36
37
  Requires-Dist: tokenizers; extra == "onnx"
@@ -38,6 +39,8 @@ Provides-Extra: dev
38
39
  Requires-Dist: pytest; extra == "dev"
39
40
  Requires-Dist: ruff>=0.9; extra == "dev"
40
41
  Requires-Dist: mypy>=1.14; extra == "dev"
42
+ Requires-Dist: jsonschema>=4; extra == "dev"
43
+ Requires-Dist: mcp<2,>=1.12; extra == "dev"
41
44
  Provides-Extra: media
42
45
  Requires-Dist: Pillow>=10; extra == "media"
43
46
  Dynamic: license-file
@@ -56,19 +59,17 @@ Trace tables and stored procedures to repositories, controller actions, and Razo
56
59
 
57
60
  ## How it compares with Claude's Grep and similar tools
58
61
 
59
- **Measured on our MES fixtures: +9.5–10.7 percentage points in relevant-file recall versus `rg + BM25`.** For the bundled SQL → C# → page investigation, the relation report covers **5/5 required evidence files**, versus **3/5** from one literal table-name search (**+40 points**).
62
+ **Measured on our MES fixtures: +9.5–13.1 percentage points in relevant-file recall versus `rg + BM25`.** For the bundled SQL → C# → page investigation, the relation report covers **5/5 required evidence files**, versus **3/5** from one literal table-name search (**+40 points**).
60
63
 
61
64
  | Fixed retrieval suite | `rg + BM25` file Recall@5 | This project | Difference |
62
65
  |---|---:|---:|---:|
63
- | MES-style synthetic: 42 questions, 24 files | 81.0% | **91.7%** | **+10.7 pp** |
66
+ | MES-style synthetic: 42 questions, 24 files | 81.0% | **94.0%** | **+13.1 pp** |
64
67
  | Same 42 questions with distractors: 109 files | 81.0% | **90.5%** | **+9.5 pp** |
65
68
  | Python stdlib: 12 questions, 85 real source files | **100.0%** | 79.2% | −20.8 pp |
66
69
 
67
- Recall means the fraction of known relevant files retrieved, averaged over questions. The baseline runs real ripgrep with generic query-term splitting and BM25 ranking; it is not Claude's agent. This project uses default hashing and 5 result chunks; the baseline returns 5 files. Both are scored at file level. These are 54 unique, project-authored questions (96 executions including the repeated noisy suite), not a general accuracy guarantee.
70
+ Recall is averaged over 54 project-authored questions (96 executions including the noisy rerun). The indexer returns 5 chunks; `rg + BM25` returns 5 files, and both are scored by file. This is a fixed-fixture comparison, not a complete Claude agent benchmark.
68
71
 
69
- **Less source to read:** on the noisy MES and stdlib suites, rendered search results contain **94.9% / 96.9% fewer characters** than reading the same selected files in full. Tiny synthetic files instead produce **2.3% more** characters. This measures output size against whole-file reading, not savings against Grep snippets or Claude tokens.
70
-
71
- **Cost of the richer report:** the demo CLI takes **244.5 ms** warm versus **8.3 ms** for one literal `rg` call (three-run medians; first indexer call **266.1 ms** including indexing). It adds controller/page evidence, not a speed win. The controller path is `probable`, not runtime proof. No end-to-end Claude, Serena, or Claude Context measurement was made. [Protocol and reproduction](docs/tool-comparison.md) · [machine/environment and summary](benchmarks/tool-comparison.json) · [all 96 query records](benchmarks/tool-comparison-queries.jsonl).
72
+ The richer relation report is slower than a single literal search: **228.5 ms versus 18.8 ms** on the bundled scenario (three-run medians). Controller reachability is `probable`, not runtime proof. [Protocol](docs/v1-readiness.md#candidate-versus-the-literal-search-baseline) · [Raw results](benchmarks/v1-tool-comparison.json) · [Per-query records](benchmarks/v1-tool-comparison-queries.jsonl).
72
73
 
73
74
  **The extra value is an indexed SQL → C# → page relation report.** For supported patterns, one `data-access` query returns direct/procedure-mediated access, controller actions, page links, and confidence labels. Claude can also follow these links through multiple Grep searches and file reads; this tool packages that investigation into a repeatable CLI/MCP result.
74
75
 
@@ -126,10 +127,11 @@ Replace the path and table name. The first query builds the index; subsequent qu
126
127
 
127
128
  ## Give the same evidence to your assistant
128
129
 
129
- For Claude Code, after installing the package:
130
+ After installation, choose your client to create project-local MCP configuration:
130
131
 
131
132
  ```bash
132
- claude mcp add local-indexer -- local-codebase-indexer --root "/absolute/path/to/project" serve
133
+ local-codebase-indexer --root "/absolute/path/to/project" init --client claude
134
+ local-codebase-indexer --root "/absolute/path/to/project" init --client codex
133
135
  ```
134
136
 
135
137
  Ask: “Which code writes `YourTable`, and which controller actions and pages reach it? Show paths and confidence levels.” Restart/reconnect the MCP client if needed. For other stdio MCP clients, use command `local-codebase-indexer` and arguments `--root`, your absolute project path, `serve`.
@@ -143,6 +145,7 @@ local-codebase-indexer --root "/path/to/project" relations OrderRepository.Appro
143
145
  local-codebase-indexer --root "/path/to/project" impact main...HEAD
144
146
  local-codebase-indexer --root "/path/to/project" search "order approval" --explain --limit 5
145
147
  local-codebase-indexer --root "/path/to/project" doctor
148
+ local-codebase-indexer --root "/path/to/project" report dbo.YourTable --output table-impact.html
146
149
  ```
147
150
 
148
151
  Relations show callers; impact compares Git snapshots; search combines identifiers, text, and local embeddings. C#, Python, JavaScript, and TypeScript have symbol parsing; T-SQL and C# have additional data-access analysis. Add `--json` for structured output.
@@ -12,19 +12,17 @@ Trace tables and stored procedures to repositories, controller actions, and Razo
12
12
 
13
13
  ## How it compares with Claude's Grep and similar tools
14
14
 
15
- **Measured on our MES fixtures: +9.5–10.7 percentage points in relevant-file recall versus `rg + BM25`.** For the bundled SQL → C# → page investigation, the relation report covers **5/5 required evidence files**, versus **3/5** from one literal table-name search (**+40 points**).
15
+ **Measured on our MES fixtures: +9.5–13.1 percentage points in relevant-file recall versus `rg + BM25`.** For the bundled SQL → C# → page investigation, the relation report covers **5/5 required evidence files**, versus **3/5** from one literal table-name search (**+40 points**).
16
16
 
17
17
  | Fixed retrieval suite | `rg + BM25` file Recall@5 | This project | Difference |
18
18
  |---|---:|---:|---:|
19
- | MES-style synthetic: 42 questions, 24 files | 81.0% | **91.7%** | **+10.7 pp** |
19
+ | MES-style synthetic: 42 questions, 24 files | 81.0% | **94.0%** | **+13.1 pp** |
20
20
  | Same 42 questions with distractors: 109 files | 81.0% | **90.5%** | **+9.5 pp** |
21
21
  | Python stdlib: 12 questions, 85 real source files | **100.0%** | 79.2% | −20.8 pp |
22
22
 
23
- Recall means the fraction of known relevant files retrieved, averaged over questions. The baseline runs real ripgrep with generic query-term splitting and BM25 ranking; it is not Claude's agent. This project uses default hashing and 5 result chunks; the baseline returns 5 files. Both are scored at file level. These are 54 unique, project-authored questions (96 executions including the repeated noisy suite), not a general accuracy guarantee.
23
+ Recall is averaged over 54 project-authored questions (96 executions including the noisy rerun). The indexer returns 5 chunks; `rg + BM25` returns 5 files, and both are scored by file. This is a fixed-fixture comparison, not a complete Claude agent benchmark.
24
24
 
25
- **Less source to read:** on the noisy MES and stdlib suites, rendered search results contain **94.9% / 96.9% fewer characters** than reading the same selected files in full. Tiny synthetic files instead produce **2.3% more** characters. This measures output size against whole-file reading, not savings against Grep snippets or Claude tokens.
26
-
27
- **Cost of the richer report:** the demo CLI takes **244.5 ms** warm versus **8.3 ms** for one literal `rg` call (three-run medians; first indexer call **266.1 ms** including indexing). It adds controller/page evidence, not a speed win. The controller path is `probable`, not runtime proof. No end-to-end Claude, Serena, or Claude Context measurement was made. [Protocol and reproduction](docs/tool-comparison.md) · [machine/environment and summary](benchmarks/tool-comparison.json) · [all 96 query records](benchmarks/tool-comparison-queries.jsonl).
25
+ The richer relation report is slower than a single literal search: **228.5 ms versus 18.8 ms** on the bundled scenario (three-run medians). Controller reachability is `probable`, not runtime proof. [Protocol](docs/v1-readiness.md#candidate-versus-the-literal-search-baseline) · [Raw results](benchmarks/v1-tool-comparison.json) · [Per-query records](benchmarks/v1-tool-comparison-queries.jsonl).
28
26
 
29
27
  **The extra value is an indexed SQL → C# → page relation report.** For supported patterns, one `data-access` query returns direct/procedure-mediated access, controller actions, page links, and confidence labels. Claude can also follow these links through multiple Grep searches and file reads; this tool packages that investigation into a repeatable CLI/MCP result.
30
28
 
@@ -82,10 +80,11 @@ Replace the path and table name. The first query builds the index; subsequent qu
82
80
 
83
81
  ## Give the same evidence to your assistant
84
82
 
85
- For Claude Code, after installing the package:
83
+ After installation, choose your client to create project-local MCP configuration:
86
84
 
87
85
  ```bash
88
- claude mcp add local-indexer -- local-codebase-indexer --root "/absolute/path/to/project" serve
86
+ local-codebase-indexer --root "/absolute/path/to/project" init --client claude
87
+ local-codebase-indexer --root "/absolute/path/to/project" init --client codex
89
88
  ```
90
89
 
91
90
  Ask: “Which code writes `YourTable`, and which controller actions and pages reach it? Show paths and confidence levels.” Restart/reconnect the MCP client if needed. For other stdio MCP clients, use command `local-codebase-indexer` and arguments `--root`, your absolute project path, `serve`.
@@ -99,6 +98,7 @@ local-codebase-indexer --root "/path/to/project" relations OrderRepository.Appro
99
98
  local-codebase-indexer --root "/path/to/project" impact main...HEAD
100
99
  local-codebase-indexer --root "/path/to/project" search "order approval" --explain --limit 5
101
100
  local-codebase-indexer --root "/path/to/project" doctor
101
+ local-codebase-indexer --root "/path/to/project" report dbo.YourTable --output table-impact.html
102
102
  ```
103
103
 
104
104
  Relations show callers; impact compares Git snapshots; search combines identifiers, text, and local embeddings. C#, Python, JavaScript, and TypeScript have symbol parsing; T-SQL and C# have additional data-access analysis. Add `--json` for structured output.
@@ -12,19 +12,17 @@
12
12
 
13
13
  ## 与 Claude 的 Grep 及类似工具比较
14
14
 
15
- **在本项目的 MES 测试集,相关文件召回率比 `rg + BM25` 高 9.5~10.7 个百分点。** 内置 SQL → C# → 页面调查场景中,关系报告覆盖 **5/5 个必要证据文件**,单次表名字面搜索为 **3/5**,覆盖率 **60% → 100%(+40 个百分点)**。
15
+ **在本项目的 MES 测试集,相关文件召回率比 `rg + BM25` 高 9.5~13.1 个百分点。** 内置 SQL → C# → 页面调查场景中,关系报告覆盖 **5/5 个必要证据文件**,单次表名字面搜索为 **3/5**,覆盖率 **60% → 100%(+40 个百分点)**。
16
16
 
17
17
  | 固定搜索测试集 | `rg + BM25` 文件 Recall@5 | 本项目 | 差异 |
18
18
  |---|---:|---:|---:|
19
- | MES 风格合成数据:42 题、24 个文件 | 81.0% | **91.7%** | **+10.7 个百分点** |
19
+ | MES 风格合成数据:42 题、24 个文件 | 81.0% | **94.0%** | **+13.1 个百分点** |
20
20
  | 相同 42 题加入干扰来源:109 个文件 | 81.0% | **90.5%** | **+9.5 个百分点** |
21
21
  | Python 标准库:12 题、85 个真实源代码文件 | **100.0%** | 79.2% | −20.8 个百分点 |
22
22
 
23
- 召回率是每题找回的已知相关文件比例,再取平均。基准实际运行 ripgrep,以通用查询拆词及 BM25 排序,并非 Claude agent。本项目使用默认 hashing、取 5 个结果块;基准取 5 个文件,双方都按文件评分。共 54 个由本项目编写的不同题目(含重跑干扰集共 96 次),不代表通用准确率保证。
23
+ 召回率取 54 道项目自编题目的平均(含噪声集重跑共 96 次)。本工具取 5 个代码块,`rg + BM25` 取 5 个文件,双方按文件评分。这是固定案例比较,并非完整 Claude agent 流程的评测。
24
24
 
25
- **减少需要阅读的源代码:** 在含干扰的 MES 与标准库测试集,搜索结果文本比“完整读取同一批选中文件”少 **94.9%/96.9% 字符**;极小的合成文件反而多 **2.3%**。这是相对于整文件读取的输出大小,并非相对 Grep 片段或 Claude token 的节省量。
26
-
27
- **较完整报告的成本:** demo CLI 暖查询 **244.5 ms**,单次字面 `rg` 为 **8.3 ms**(各测量 3 次取中位数;本项目首次查询含建索引为 **266.1 ms**)。提升在于多追到 Controller/页面;速度较慢。Controller 路径标为 `probable`,不代表运行时证明。尚未测量完整 Claude、Serena 或 Claude Context 流程。[方法与重跑命令](docs/tool-comparison.md) · [机器环境与汇总数据](benchmarks/tool-comparison.json) · [全部 96 条逐题记录](benchmarks/tool-comparison-queries.jsonl)。
25
+ 关系报告比单次字面搜索慢:示例中为 **228.5 ms 对 18.8 ms**(各 3 次中位数)。Controller 路径标为 `probable`,不代表运行时证明。[方法](docs/v1-readiness.md#candidate-versus-the-literal-search-baseline) · [原始数据](benchmarks/v1-tool-comparison.json) · [逐题记录](benchmarks/v1-tool-comparison-queries.jsonl)。
28
26
 
29
27
  **这个项目多提供的是 SQL → C# → 页面的索引关系报告。** 在支持的代码模式中,一次 `data-access` 查询就能列出直接/通过存储过程的访问、Controller Action、页面与置信度标签。Claude 也能通过多轮 Grep 和读文件追踪关系;该工具将这段调查整理成可重复执行的 CLI/MCP 结果。
30
28
 
@@ -82,10 +80,11 @@ local-codebase-indexer --root "/path/to/project" data-access YourTable
82
80
 
83
81
  ## 接入 AI 助手
84
82
 
85
- 安装包后,在 Claude Code 中注册:
83
+ 安装软件包后,按使用的客户端选择一个命令,创建项目内 MCP 配置:
86
84
 
87
85
  ```bash
88
- claude mcp add local-indexer -- local-codebase-indexer --root "/absolute/path/to/project" serve
86
+ local-codebase-indexer --root "/absolute/path/to/project" init --client claude
87
+ local-codebase-indexer --root "/absolute/path/to/project" init --client codex
89
88
  ```
90
89
 
91
90
  可以问:“哪些代码写入 `YourTable`?哪些 Controller Action 和页面会到达它?请列出路径和置信度。”必要时重新连接或重启 MCP 客户端。
@@ -99,6 +98,7 @@ local-codebase-indexer --root "/path/to/project" relations OrderRepository.Appro
99
98
  local-codebase-indexer --root "/path/to/project" impact main...HEAD
100
99
  local-codebase-indexer --root "/path/to/project" search "order approval" --explain --limit 5
101
100
  local-codebase-indexer --root "/path/to/project" doctor
101
+ local-codebase-indexer --root "/path/to/project" report dbo.YourTable --output table-impact.html
102
102
  ```
103
103
 
104
104
  可查询调用者、Git 版本间影响,以及结合标识符、文本和本地 embedding 的搜索。C#、Python、JavaScript、TypeScript 支持符号解析;T-SQL 和 C# 另有数据访问分析。加上 `--json` 获取结构化结果。
@@ -12,19 +12,17 @@
12
12
 
13
13
  ## 與 Claude 的 Grep 及類似工具比較
14
14
 
15
- **在本專案的 MES 測試集,相關檔案召回率比 `rg + BM25` 高 9.5~10.7 個百分點。** 內建 SQL → C# → 頁面調查情境中,關係報告涵蓋 **5/5 個必要證據檔案**,單次表名字面搜尋為 **3/5**,涵蓋率 **60% → 100%(+40 個百分點)**。
15
+ **在本專案的 MES 測試集,相關檔案召回率比 `rg + BM25` 高 9.5~13.1 個百分點。** 內建 SQL → C# → 頁面調查情境中,關係報告涵蓋 **5/5 個必要證據檔案**,單次表名字面搜尋為 **3/5**,涵蓋率 **60% → 100%(+40 個百分點)**。
16
16
 
17
17
  | 固定搜尋測試集 | `rg + BM25` 檔案 Recall@5 | 本專案 | 差異 |
18
18
  |---|---:|---:|---:|
19
- | MES 風格合成資料:42 題、24 個檔案 | 81.0% | **91.7%** | **+10.7 個百分點** |
19
+ | MES 風格合成資料:42 題、24 個檔案 | 81.0% | **94.0%** | **+13.1 個百分點** |
20
20
  | 相同 42 題加入干擾來源:109 個檔案 | 81.0% | **90.5%** | **+9.5 個百分點** |
21
21
  | Python 標準函式庫:12 題、85 個真實原始碼檔案 | **100.0%** | 79.2% | −20.8 個百分點 |
22
22
 
23
- 召回率是每題找回的已知相關檔案比例,再取平均。基準實際執行 ripgrep,以通用查詢拆詞及 BM25 排序,並非 Claude agent。本專案使用預設 hashing、取 5 個結果區塊;基準取 5 個檔案,雙方都以檔案計分。共 54 個由本專案編寫的不同題目(含重跑干擾集共 96 次),不代表通用準確率保證。
23
+ 召回率取 54 題專案自編題目的平均(含雜訊集重跑共 96 次)。本工具取 5 個程式區塊,`rg + BM25` 取 5 個檔案,雙方以檔案計分。這是固定案例比較,並非完整 Claude agent 流程的評測。
24
24
 
25
- **減少需要閱讀的原始碼:** 在含干擾的 MES 與標準函式庫測試集,搜尋結果文字比「完整讀取同一批選中檔案」少 **94.9%/96.9% 字元**;極小的合成檔案反而多 **2.3%**。這是相對於整檔讀取的輸出大小,並非相對 Grep 摘錄或 Claude token 的節省量。
26
-
27
- **較完整報告的成本:** demo CLI 暖查詢 **244.5 ms**,單次字面 `rg` 為 **8.3 ms**(各量測 3 次取中位數;本專案首次查詢含建索引為 **266.1 ms**)。提升在於多追到 Controller/頁面;速度較慢。Controller 路徑標為 `probable`,不代表執行期證明。尚未量測完整 Claude、Serena 或 Claude Context 流程。[方法與重跑命令](docs/tool-comparison.md) · [機器環境與彙總數據](benchmarks/tool-comparison.json) · [全部 96 筆逐題紀錄](benchmarks/tool-comparison-queries.jsonl)。
25
+ 關係報告比單次字面搜尋慢:範例中為 **228.5 ms 對 18.8 ms**(各 3 次中位數)。Controller 路徑標為 `probable`,不代表執行期證明。[方法](docs/v1-readiness.md#candidate-versus-the-literal-search-baseline) · [原始數據](benchmarks/v1-tool-comparison.json) · [逐題紀錄](benchmarks/v1-tool-comparison-queries.jsonl)。
28
26
 
29
27
  **這個專案多提供的是 SQL → C# → 頁面的索引關係報告。** 在支援的程式模式中,一次 `data-access` 查詢就能列出直接/透過預存程序的存取、Controller Action、頁面與信心標籤。Claude 也能透過多輪 Grep 與讀檔追出關係;此工具把這段調查整理成可重複執行的 CLI/MCP 結果。
30
28
 
@@ -82,10 +80,11 @@ local-codebase-indexer --root "/path/to/project" data-access YourTable
82
80
 
83
81
  ## 接上 AI 助手
84
82
 
85
- 安裝套件後,在 Claude Code 註冊:
83
+ 安裝套件後,依使用的用戶端選一個命令,建立專案內 MCP 設定:
86
84
 
87
85
  ```bash
88
- claude mcp add local-indexer -- local-codebase-indexer --root "/absolute/path/to/project" serve
86
+ local-codebase-indexer --root "/absolute/path/to/project" init --client claude
87
+ local-codebase-indexer --root "/absolute/path/to/project" init --client codex
89
88
  ```
90
89
 
91
90
  可以問:「哪些程式寫入 `YourTable`?哪些 Controller Action 與頁面會到達它?請列出路徑與信心等級。」必要時重新連線或重啟 MCP 用戶端。
@@ -99,6 +98,7 @@ local-codebase-indexer --root "/path/to/project" relations OrderRepository.Appro
99
98
  local-codebase-indexer --root "/path/to/project" impact main...HEAD
100
99
  local-codebase-indexer --root "/path/to/project" search "order approval" --explain --limit 5
101
100
  local-codebase-indexer --root "/path/to/project" doctor
101
+ local-codebase-indexer --root "/path/to/project" report dbo.YourTable --output table-impact.html
102
102
  ```
103
103
 
104
104
  可查呼叫者、Git 版本間影響,以及結合識別字、文字與本機 embedding 的搜尋。C#、Python、JavaScript、TypeScript 支援符號解析;T-SQL 與 C# 另有資料存取分析。加上 `--json` 可取得結構化結果。
@@ -4,9 +4,12 @@ Priorities come from the benchmark (`benchmarks/run_benchmark.py`, baseline in `
4
4
 
5
5
  ## Next
6
6
 
7
+ - Validate independent maintainer-authored SQL impact tasks and actual investigation time before making production-accuracy or time-savings claims. The new 100-question public-code development evaluation is source-reviewed but project-authored; its generic retrieval Recall@5 remains 48%.
8
+ - Continue improving broad paraphrase retrieval. See [v1 implementation and evidence](docs/v1-readiness.md); SDK/Claude automatic checks and recorded native Codex transport evidence do not measure model reasoning.
9
+
7
10
  0. **MCP Registry discovery**: the 0.8.0 release workflow publishes `server.json` after PyPI succeeds, using GitHub OIDC. Verify the live entry after each release; a local manifest alone does not establish publication. See [discovery instructions](docs/discovery.md).
8
11
  1. **Remaining data-flow gaps**: non-sink SQL proc-name literals (`Run("usp_X")`), EF `this.ToTable(..)` inside `EntityTypeConfiguration<T>` (entity not taken from the base class yet), and EF updates through tracked entities when the entity was loaded in another method than the one calling `SaveChanges` (only same-method read + `SaveChanges` is listed, as uncertain).
9
- 2. **C# call graph gaps**: overload resolution by argument type, delegates / lambdas / extension methods, call chains longer than one level. Without Roslyn these stay approximate; edges carry `confirmed` / `probable` / `candidate`.
12
+ 2. **C# call graph gaps**: overload resolution by argument type, delegates / lambdas / extension methods, return-type inference across chained receiver expressions. Without Roslyn these stay approximate; edges carry `confirmed` / `probable` / `candidate`.
10
13
 
11
14
  ## Deferred (not worth doing yet)
12
15
 
@@ -15,13 +18,14 @@ Priorities come from the benchmark (`benchmarks/run_benchmark.py`, baseline in `
15
18
  | Real embedding model as default | Measured 0.4.0 on a real 30k-chunk C# codebase with Chinese comments, 12 paraphrased queries (6 zh, 6 en): hashing MRR 0.48 / hit@5 6, `all-MiniLM-L6-v2` 0.29 / 6, `paraphrase-multilingual-MiniLM-L12-v2` (int8) 0.41 / 6; full index 128 s vs 35 / 43 min. Benchmark: MiniLM +0.08-0.13 MRR, multilingual -0.01..+0.03. Domain jargon ("split a lot into two") was missed by all three | A model trained on code + Chinese, or embedding becomes incremental enough that branch switches stay under a minute |
16
19
  | Content-hash cache of parse results across branch switches | Measured: a switch that rewrites 400 files re-indexes in about 10 s; parsing is about 40% of that, so a cache would save a few seconds at the cost of a large table | Branch switches routinely rewrite thousands of files |
17
20
  | ANN index | Exact search is not the bottleneck. Measured (Python stdlib copies, linear growth): 17k chunks cold CLI search 0.35 s / warm 0.13 s / index 10 s; 52k chunks 0.75 s / 0.36 s / 28 s; 104k chunks 1.09 s / 0.73 s / 54 s, 372 MB RSS, 729 MB database. At 104k chunks the cosine product plus top-k takes about 12 ms; loading the vectors out of SQLite (fetch 0.31 s, join 0.12 s) is about half of a warm query | Exact cosine itself becomes slow, which is far beyond 1M chunks |
18
- | Vector matrix cache | Cheap and measurable: it removes about half of a warm query at 104k chunks (about 0.8 s -> 0.3 s). Not needed below ~50k chunks | A real project passes ~50k chunks. Keep the matrix in the MCP server process, and/or store it as a memory-mapped `.npy` next to the database so the CLI benefits too (invalidate on any index change) |
19
21
  | `codebase_trace_execution` | Needs reliable call / data-flow relations; today's usage edges are name matches | Call graph gaps (item 3) are narrowed; today edges carry a confidence level |
20
22
  | `codebase_architecture_overview` | Low value for the intended use cases | A concrete need appears |
21
23
  | `codebase_find_references` (upgrade) | `relations` already returns name-matched references | Done in part: `relations` already separates confirmed / probable / candidate callers |
22
24
 
23
25
  ## Done
24
26
 
27
+ - 1.0.0: scoped four-part SQL identities and ambiguity handling; AST-byte C# owners and distinct compact overloads; representative evidence paths/depth warnings; versioned MCP/CLI schemas and protocol negotiation; project initialization, progress, offline reports; lexical mode, revision-bound vector cache; frozen real-project/scaling/client evidence and CI artifacts.
28
+
25
29
  - 0.9.0: SQL alias/hint/TOP and quoted-name fixes; cursor/TRIM false-positive removal; nested comments and uncertain OPENQUERY analysis; comma sources after JOIN; BOM-aware Unicode source/context handling; constant SQL method attribution; VB6 SQL analysis; separate DDL/schema impact; explicit ignore overrides; modular navigation/context/rendering; lint/mypy CI and Windows Python 3.10/3.12/3.13.
26
30
 
27
31
  - 0.7.0: revision-bound search cursors; historical target snapshots; model content identities; process coordination and crash recovery; focus-preserving context; synonym hot reload; retrieval explanations; project evaluation runner; automatic validated Release assets. Representative user-authored evaluation questions and broader semantic retrieval remain ongoing work.