tensor-grep 1.76.1__tar.gz → 1.76.2__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 (135) hide show
  1. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/PKG-INFO +1 -1
  2. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/pyproject.toml +2 -1
  3. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/Cargo.lock +1 -1
  4. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/Cargo.toml +2 -1
  5. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/repo_map.py +25 -6
  6. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/runtime_paths.py +7 -0
  7. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/LICENSE +0 -0
  8. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/NOTICE +0 -0
  9. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/README.md +0 -0
  10. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/deny.toml +0 -0
  11. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/rust-toolchain.toml +0 -0
  12. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/backend_ast.rs +0 -0
  13. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/backend_ast_workflow.rs +0 -0
  14. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/backend_cpu.rs +0 -0
  15. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/bin/tg_search_fast.rs +0 -0
  16. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/cli.rs +0 -0
  17. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/crossover.rs +0 -0
  18. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/editor_plane.rs +0 -0
  19. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/gpu_native.rs +0 -0
  20. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/index.rs +0 -0
  21. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/index_lock.rs +0 -0
  22. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/lib.rs +0 -0
  23. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/main.rs +0 -0
  24. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/mmap_arrow.rs +0 -0
  25. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/native_search.rs +0 -0
  26. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/python_sidecar.rs +0 -0
  27. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/rg_passthrough.rs +0 -0
  28. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/routing.rs +0 -0
  29. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/src/runtime_paths.rs +0 -0
  30. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_ast_backend.rs +0 -0
  31. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_ast_cache.rs +0 -0
  32. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_ast_grep_embed.rs +0 -0
  33. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_ast_rewrite.rs +0 -0
  34. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_audit_manifest_symlink_unix.rs +0 -0
  35. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_gpu_native.rs +0 -0
  36. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_gpu_native_error_handling.rs +0 -0
  37. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_gpu_native_graphs.rs +0 -0
  38. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_gpu_native_integration.rs +0 -0
  39. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_gpu_native_long_lines.rs +0 -0
  40. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_gpu_native_streams.rs +0 -0
  41. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_index.rs +0 -0
  42. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_index_lock_concurrency.rs +0 -0
  43. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_mmap_arrow.rs +0 -0
  44. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_native_search.rs +0 -0
  45. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_output.rs +0 -0
  46. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_public_native_cli_parity.rs +0 -0
  47. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_python_bootstrap.rs +0 -0
  48. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_release_profile.rs +0 -0
  49. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_replace.rs +0 -0
  50. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_resident_worker.rs +0 -0
  51. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_routing.rs +0 -0
  52. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_runtime_path_resolution.rs +0 -0
  53. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_schema_compat.rs +0 -0
  54. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_search.rs +0 -0
  55. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_search_golden.rs +0 -0
  56. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_sidecar_ipc.rs +0 -0
  57. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/rust_core/tests/test_smart_routing.rs +0 -0
  58. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/__init__.py +0 -0
  59. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/__main__.py +0 -0
  60. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/__init__.py +0 -0
  61. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/ast_backend.py +0 -0
  62. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/ast_wrapper_backend.py +0 -0
  63. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/base.py +0 -0
  64. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/cpu_backend.py +0 -0
  65. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/cudf_backend.py +0 -0
  66. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/cybert_backend.py +0 -0
  67. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/ripgrep_backend.py +0 -0
  68. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/rust_backend.py +0 -0
  69. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/stringzilla_backend.py +0 -0
  70. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/backends/torch_backend.py +0 -0
  71. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/__init__.py +0 -0
  72. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/_index_lock.py +0 -0
  73. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/agent_capsule.py +0 -0
  74. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/apply_policy.py +0 -0
  75. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/ast_workflows.py +0 -0
  76. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/audit_manifest.py +0 -0
  77. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/bootstrap.py +0 -0
  78. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/checkpoint_store.py +0 -0
  79. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/codemap.py +0 -0
  80. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/commands.py +0 -0
  81. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/docs_coverage.py +0 -0
  82. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/dogfood.py +0 -0
  83. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/evidence_receipt.py +0 -0
  84. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/evidence_signing.py +0 -0
  85. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/formatters/__init__.py +0 -0
  86. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/formatters/base.py +0 -0
  87. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/formatters/csv_fmt.py +0 -0
  88. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/formatters/json_fmt.py +0 -0
  89. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/formatters/ripgrep_fmt.py +0 -0
  90. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/formatters/table_fmt.py +0 -0
  91. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/inventory.py +0 -0
  92. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/lang_go.py +0 -0
  93. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/lang_registry.py +0 -0
  94. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/lsp_external_provider.py +0 -0
  95. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/lsp_provider_setup.py +0 -0
  96. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/lsp_server.py +0 -0
  97. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/main.py +0 -0
  98. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/mcp_server.py +0 -0
  99. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/orient_capsule.py +0 -0
  100. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/progress.py +0 -0
  101. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/rg_contract.py +0 -0
  102. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/rule_packs.py +0 -0
  103. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/scan_guardrails.py +0 -0
  104. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/session_daemon.py +0 -0
  105. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/session_store.py +0 -0
  106. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/cli/subprocess_policy.py +0 -0
  107. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/__init__.py +0 -0
  108. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/config.py +0 -0
  109. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/hardware/__init__.py +0 -0
  110. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/hardware/device_detect.py +0 -0
  111. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/hardware/device_inventory.py +0 -0
  112. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/hardware/memory_manager.py +0 -0
  113. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/observability.py +0 -0
  114. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/pipeline.py +0 -0
  115. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/query_analyzer.py +0 -0
  116. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/registration_check.py +0 -0
  117. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/reranker.py +0 -0
  118. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/result.py +0 -0
  119. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/retrieval_bm25.py +0 -0
  120. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/retrieval_chunker.py +0 -0
  121. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/retrieval_dense.py +0 -0
  122. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/retrieval_fusion.py +0 -0
  123. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/retrieval_late.py +0 -0
  124. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/retrieval_lexical.py +0 -0
  125. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/retrieval_scoring.py +0 -0
  126. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/core/semantic_index.py +0 -0
  127. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/io/__init__.py +0 -0
  128. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/io/base.py +0 -0
  129. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/io/directory_scanner.py +0 -0
  130. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/io/reader_cudf.py +0 -0
  131. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/io/reader_dstorage.py +0 -0
  132. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/io/reader_fallback.py +0 -0
  133. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/io/reader_kvikio.py +0 -0
  134. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/perf_guard.py +0 -0
  135. {tensor_grep-1.76.1 → tensor_grep-1.76.2}/src/tensor_grep/sidecar.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tensor-grep
3
- Version: 1.76.1
3
+ Version: 1.76.2
4
4
  Requires-Dist: typer>=0.12,<0.26
5
5
  Requires-Dist: rich>=13.0
6
6
  Requires-Dist: mcp>=1.2.0
@@ -530,11 +530,12 @@ version_variables = [
530
530
 
531
531
 
532
532
 
533
+
533
534
 
534
535
 
535
536
  [project]
536
537
  name = "tensor-grep"
537
- version = "1.76.1"
538
+ version = "1.76.2"
538
539
  description = "High-performance grep-compatible CLI with Rust, GPU, and AST/NLP routing"
539
540
  readme = { file = "rust_core/README.md", content-type = "text/markdown" }
540
541
  requires-python = ">=3.11"
@@ -1579,7 +1579,7 @@ dependencies = [
1579
1579
 
1580
1580
  [[package]]
1581
1581
  name = "tensor_grep_rs"
1582
- version = "1.76.1"
1582
+ version = "1.76.2"
1583
1583
  dependencies = [
1584
1584
  "aho-corasick",
1585
1585
  "anyhow",
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "tensor_grep_rs"
3
- version = "1.76.1"
3
+ version = "1.76.2"
4
4
  edition = "2021"
5
5
  description = "Rust core engine for tensor-grep"
6
6
  license = "Apache-2.0"
@@ -438,6 +438,7 @@ path = "src/bin/tg_search_fast.rs"
438
438
 
439
439
 
440
440
 
441
+
441
442
 
442
443
 
443
444
  [dev-dependencies]
@@ -6412,12 +6412,20 @@ def _python_module_matches_definition(
6412
6412
  repo_root: Path | str | None = None,
6413
6413
  *,
6414
6414
  level: int = 0,
6415
- ) -> bool:
6416
- return bool(
6417
- _python_module_match_details(
6418
- importer_path, module_name, definition_path, repo_root, level=level
6419
- )["matched"]
6415
+ ) -> tuple[bool, list[str]]:
6416
+ """Return `(matched, provenance)`.
6417
+
6418
+ Unlike the bool-only `_js_ts_module_matches_definition` / `_rust_module_matches_definition`
6419
+ siblings, this also threads through `_python_module_match_details`'s `provenance` (notably
6420
+ the "sys-path-insert" tag) -- #155 fix: that tag was computed but provably unreachable
6421
+ (this was the only caller, and it discarded everything but the bool) before this change.
6422
+ The sole caller, `_confirm_import_edges`, uses it to report the tag honestly on `tg
6423
+ importers` reverse edges instead of silently collapsing it into a generic label.
6424
+ """
6425
+ details = _python_module_match_details(
6426
+ importer_path, module_name, definition_path, repo_root, level=level
6420
6427
  )
6428
+ return bool(details["matched"]), list(details["provenance"])
6421
6429
 
6422
6430
 
6423
6431
  def _group_symbols_by_file(symbols: list[dict[str, Any]]) -> dict[str, list[dict[str, Any]]]:
@@ -15463,6 +15471,7 @@ def _confirm_import_edges(
15463
15471
  # a confirmed edge for an import whose target we can't actually read (precision
15464
15472
  # matters more than recall past this point).
15465
15473
  continue
15474
+ python_provenance: list[str] = []
15466
15475
  if language_id in ("javascript", "typescript"):
15467
15476
  matched = _js_ts_module_matches_definition(
15468
15477
  candidate_importer, module, target_file, repo_root
@@ -15479,7 +15488,7 @@ def _confirm_import_edges(
15479
15488
  # `_python_module_candidates` resolve a relative import correctly instead of
15480
15489
  # falling back to a bare path-suffix match that ignores directory context.
15481
15490
  level = int(raw_entry.get("level", 0) or 0)
15482
- matched = _python_module_matches_definition(
15491
+ matched, python_provenance = _python_module_matches_definition(
15483
15492
  candidate_importer, module, target_file, repo_root, level=level
15484
15493
  )
15485
15494
  if not matched or line in seen_lines:
@@ -15496,6 +15505,16 @@ def _confirm_import_edges(
15496
15505
  "provenance": provenance,
15497
15506
  "resolution_confidence": _import_graph_resolution_confidence(provenance),
15498
15507
  }
15508
+ if python_provenance == ["sys-path-insert"]:
15509
+ # #155 fix: report the sys.path-hack tag honestly on the reverse edge too, mirroring
15510
+ # the forward `tg imports` path (`_resolve_raw_import_entry`). A SEPARATE field, not
15511
+ # an overwrite of `provenance` above -- that string drives
15512
+ # `_import_graph_resolution_confidence`'s enum ("parser-backed"/"heuristic"/
15513
+ # "regex-heuristic", pinned by test_import_span_targeting.py) and this edge is still
15514
+ # exactly as parser-confirmed (exact AST-parsed, exact resolved-path match) as any
15515
+ # other Python edge, just resolved via a sys.path-hacked root instead of a standard
15516
+ # one.
15517
+ edge["path_provenance"] = "sys-path-insert"
15499
15518
  if dynamic:
15500
15519
  # Payload-bloat fix (#93 SUB-1 follow-up, same rationale as
15501
15520
  # _resolve_raw_import_entry): preserve the dynamic markers on an edge that IS
@@ -84,6 +84,13 @@ def _read_project_version_fallback() -> str:
84
84
  return "0.0.0"
85
85
 
86
86
 
87
+ # Safe to cache (unlike `_native_tg_version` below, whose docstring at `inspect_native_tg_binary`
88
+ # warns against a path-keyed cache going stale across an `os.replace` swap): this function takes
89
+ # no arguments and only reads pyproject.toml + installed package metadata, neither of which change
90
+ # within a single process lifetime. Called on every daemon probe (`_probe_daemon` in
91
+ # session_daemon.py) since the daemon became default-on for symbol commands, so an uncached
92
+ # pyproject.toml read + importlib.metadata scan on every probe is wasted I/O.
93
+ @lru_cache(maxsize=1)
87
94
  def _expected_tg_version() -> str:
88
95
  source_version = _read_project_version_fallback()
89
96
  try:
File without changes
File without changes