tracekite-core 0.1.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 (218) hide show
  1. tracekite_core-0.1.1/.gitignore +111 -0
  2. tracekite_core-0.1.1/LICENSE +202 -0
  3. tracekite_core-0.1.1/PKG-INFO +78 -0
  4. tracekite_core-0.1.1/README.md +27 -0
  5. tracekite_core-0.1.1/hatch_build.py +29 -0
  6. tracekite_core-0.1.1/pyproject.toml +85 -0
  7. tracekite_core-0.1.1/src/tracekite/__init__.py +0 -0
  8. tracekite_core-0.1.1/src/tracekite/_control_plane/confidence.yml +259 -0
  9. tracekite_core-0.1.1/src/tracekite/_control_plane/internal_namespaces.yml +29 -0
  10. tracekite_core-0.1.1/src/tracekite/_control_plane/promotions.yml +10 -0
  11. tracekite_core-0.1.1/src/tracekite/_control_plane/repos.yml +9 -0
  12. tracekite_core-0.1.1/src/tracekite/_control_plane/service_aliases.yml +9 -0
  13. tracekite_core-0.1.1/src/tracekite/_control_plane/vendor_catalog.yml +57 -0
  14. tracekite_core-0.1.1/src/tracekite/agent_setup.py +120 -0
  15. tracekite_core-0.1.1/src/tracekite/answer.py +198 -0
  16. tracekite_core-0.1.1/src/tracekite/cli.py +299 -0
  17. tracekite_core-0.1.1/src/tracekite/cli_emit.py +19 -0
  18. tracekite_core-0.1.1/src/tracekite/cli_explain.py +96 -0
  19. tracekite_core-0.1.1/src/tracekite/cli_inspect.py +281 -0
  20. tracekite_core-0.1.1/src/tracekite/completeness.py +82 -0
  21. tracekite_core-0.1.1/src/tracekite/config.py +105 -0
  22. tracekite_core-0.1.1/src/tracekite/db/__init__.py +0 -0
  23. tracekite_core-0.1.1/src/tracekite/db/artifact.py +265 -0
  24. tracekite_core-0.1.1/src/tracekite/db/artifact_diff.py +129 -0
  25. tracekite_core-0.1.1/src/tracekite/db/artifact_migrations.py +152 -0
  26. tracekite_core-0.1.1/src/tracekite/db/artifact_reader.py +123 -0
  27. tracekite_core-0.1.1/src/tracekite/db/constraints.py +121 -0
  28. tracekite_core-0.1.1/src/tracekite/db/graph_store.py +89 -0
  29. tracekite_core-0.1.1/src/tracekite/db/impact_reader.py +64 -0
  30. tracekite_core-0.1.1/src/tracekite/db/memory_store.py +268 -0
  31. tracekite_core-0.1.1/src/tracekite/db/migrate.py +80 -0
  32. tracekite_core-0.1.1/src/tracekite/db/neo4j_client.py +61 -0
  33. tracekite_core-0.1.1/src/tracekite/db/neo4j_graph_store.py +183 -0
  34. tracekite_core-0.1.1/src/tracekite/db/sqlite_store.py +242 -0
  35. tracekite_core-0.1.1/src/tracekite/db/store_config.py +67 -0
  36. tracekite_core-0.1.1/src/tracekite/engine_config.py +84 -0
  37. tracekite_core-0.1.1/src/tracekite/engine_health.py +147 -0
  38. tracekite_core-0.1.1/src/tracekite/facade.py +282 -0
  39. tracekite_core-0.1.1/src/tracekite/ingest_client.py +216 -0
  40. tracekite_core-0.1.1/src/tracekite/main.py +81 -0
  41. tracekite_core-0.1.1/src/tracekite/mcp_envelope.py +114 -0
  42. tracekite_core-0.1.1/src/tracekite/mcp_server.py +298 -0
  43. tracekite_core-0.1.1/src/tracekite/metrics_export.py +143 -0
  44. tracekite_core-0.1.1/src/tracekite/middleware/__init__.py +0 -0
  45. tracekite_core-0.1.1/src/tracekite/middleware/auth.py +160 -0
  46. tracekite_core-0.1.1/src/tracekite/models/__init__.py +0 -0
  47. tracekite_core-0.1.1/src/tracekite/models/api_models.py +134 -0
  48. tracekite_core-0.1.1/src/tracekite/models/graph_models.py +170 -0
  49. tracekite_core-0.1.1/src/tracekite/parsers/__init__.py +0 -0
  50. tracekite_core-0.1.1/src/tracekite/parsers/asyncapi_parser.py +288 -0
  51. tracekite_core-0.1.1/src/tracekite/parsers/base.py +91 -0
  52. tracekite_core-0.1.1/src/tracekite/parsers/brace_blocks.py +33 -0
  53. tracekite_core-0.1.1/src/tracekite/parsers/config_parser.py +306 -0
  54. tracekite_core-0.1.1/src/tracekite/parsers/cron_parser.py +69 -0
  55. tracekite_core-0.1.1/src/tracekite/parsers/dependency_parser.py +1470 -0
  56. tracekite_core-0.1.1/src/tracekite/parsers/docker_parser.py +262 -0
  57. tracekite_core-0.1.1/src/tracekite/parsers/gateway_parser.py +913 -0
  58. tracekite_core-0.1.1/src/tracekite/parsers/graphql_parser.py +175 -0
  59. tracekite_core-0.1.1/src/tracekite/parsers/helm_refs.py +29 -0
  60. tracekite_core-0.1.1/src/tracekite/parsers/iac_parser.py +234 -0
  61. tracekite_core-0.1.1/src/tracekite/parsers/iac_units.py +152 -0
  62. tracekite_core-0.1.1/src/tracekite/parsers/java_parser.py +199 -0
  63. tracekite_core-0.1.1/src/tracekite/parsers/javascript_parser.py +211 -0
  64. tracekite_core-0.1.1/src/tracekite/parsers/kotlin_parser.py +225 -0
  65. tracekite_core-0.1.1/src/tracekite/parsers/kubernetes_parser.py +739 -0
  66. tracekite_core-0.1.1/src/tracekite/parsers/mcp_manifest_parser.py +156 -0
  67. tracekite_core-0.1.1/src/tracekite/parsers/migration_parser.py +306 -0
  68. tracekite_core-0.1.1/src/tracekite/parsers/openapi_parser.py +73 -0
  69. tracekite_core-0.1.1/src/tracekite/parsers/ownership_parser.py +622 -0
  70. tracekite_core-0.1.1/src/tracekite/parsers/parser_registry.py +462 -0
  71. tracekite_core-0.1.1/src/tracekite/parsers/pipeline_parser.py +807 -0
  72. tracekite_core-0.1.1/src/tracekite/parsers/proto_parser.py +282 -0
  73. tracekite_core-0.1.1/src/tracekite/parsers/python_parser.py +234 -0
  74. tracekite_core-0.1.1/src/tracekite/parsers/scip_parser.py +115 -0
  75. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/README.md +36 -0
  76. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/__init__.py +0 -0
  77. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/adapter.py +668 -0
  78. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/__init__.py +0 -0
  79. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/base_parser.py +34 -0
  80. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/extractor.py +721 -0
  81. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/models.py +686 -0
  82. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/parser.py +391 -0
  83. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/__init__.py +0 -0
  84. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/__init__.py +0 -0
  85. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/java/__init__.py +0 -0
  86. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/java/sql_annotations.scm +13 -0
  87. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/javascript/__init__.py +0 -0
  88. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/kotlin/__init__.py +0 -0
  89. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/python/__init__.py +0 -0
  90. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/python/sql_annotations.scm +13 -0
  91. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/typescript/__init__.py +0 -0
  92. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/files/typescript/sql_annotations.scm +13 -0
  93. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/query_engine.py +619 -0
  94. tracekite_core-0.1.1/src/tracekite/parsers/tree_sitter/core/queries/query_loader.py +67 -0
  95. tracekite_core-0.1.1/src/tracekite/parsers/yaml_shapes.py +27 -0
  96. tracekite_core-0.1.1/src/tracekite/routes/__init__.py +0 -0
  97. tracekite_core-0.1.1/src/tracekite/routes/graph.py +87 -0
  98. tracekite_core-0.1.1/src/tracekite/routes/health.py +36 -0
  99. tracekite_core-0.1.1/src/tracekite/routes/impact.py +38 -0
  100. tracekite_core-0.1.1/src/tracekite/routes/jobs.py +45 -0
  101. tracekite_core-0.1.1/src/tracekite/routes/links.py +237 -0
  102. tracekite_core-0.1.1/src/tracekite/routes/repos.py +151 -0
  103. tracekite_core-0.1.1/src/tracekite/routes/rollup.py +51 -0
  104. tracekite_core-0.1.1/src/tracekite/routes/trace.py +243 -0
  105. tracekite_core-0.1.1/src/tracekite/run_logging.py +126 -0
  106. tracekite_core-0.1.1/src/tracekite/scan_meta.py +208 -0
  107. tracekite_core-0.1.1/src/tracekite/services/__init__.py +0 -0
  108. tracekite_core-0.1.1/src/tracekite/services/absence.py +93 -0
  109. tracekite_core-0.1.1/src/tracekite/services/agents_extractor.py +708 -0
  110. tracekite_core-0.1.1/src/tracekite/services/calibration.py +1377 -0
  111. tracekite_core-0.1.1/src/tracekite/services/calibration_estates.py +271 -0
  112. tracekite_core-0.1.1/src/tracekite/services/calibration_io.py +96 -0
  113. tracekite_core-0.1.1/src/tracekite/services/calibration_tiers.py +129 -0
  114. tracekite_core-0.1.1/src/tracekite/services/call_graph_resolver.py +166 -0
  115. tracekite_core-0.1.1/src/tracekite/services/claim_sink.py +46 -0
  116. tracekite_core-0.1.1/src/tracekite/services/claims.py +304 -0
  117. tracekite_core-0.1.1/src/tracekite/services/control_plane.py +25 -0
  118. tracekite_core-0.1.1/src/tracekite/services/csharp_route_extractor.py +198 -0
  119. tracekite_core-0.1.1/src/tracekite/services/data_extractor.py +459 -0
  120. tracekite_core-0.1.1/src/tracekite/services/env_extractor.py +149 -0
  121. tracekite_core-0.1.1/src/tracekite/services/evidence_reverify.py +105 -0
  122. tracekite_core-0.1.1/src/tracekite/services/extraction_coverage.py +85 -0
  123. tracekite_core-0.1.1/src/tracekite/services/file_classifier.py +127 -0
  124. tracekite_core-0.1.1/src/tracekite/services/file_scanner.py +165 -0
  125. tracekite_core-0.1.1/src/tracekite/services/flag_guards.py +98 -0
  126. tracekite_core-0.1.1/src/tracekite/services/framework_routes.py +82 -0
  127. tracekite_core-0.1.1/src/tracekite/services/go_route_extractor.py +426 -0
  128. tracekite_core-0.1.1/src/tracekite/services/graph_factories.py +214 -0
  129. tracekite_core-0.1.1/src/tracekite/services/graph_properties.py +29 -0
  130. tracekite_core-0.1.1/src/tracekite/services/graph_reader.py +405 -0
  131. tracekite_core-0.1.1/src/tracekite/services/graph_writer.py +276 -0
  132. tracekite_core-0.1.1/src/tracekite/services/grpc_extractor.py +169 -0
  133. tracekite_core-0.1.1/src/tracekite/services/grpc_gateway_routes.py +144 -0
  134. tracekite_core-0.1.1/src/tracekite/services/http_call_extractor.py +546 -0
  135. tracekite_core-0.1.1/src/tracekite/services/http_call_js.py +141 -0
  136. tracekite_core-0.1.1/src/tracekite/services/http_call_url.py +64 -0
  137. tracekite_core-0.1.1/src/tracekite/services/ingest_artifacts.py +297 -0
  138. tracekite_core-0.1.1/src/tracekite/services/ingest_claims.py +1746 -0
  139. tracekite_core-0.1.1/src/tracekite/services/ingest_config_defs.py +148 -0
  140. tracekite_core-0.1.1/src/tracekite/services/ingest_deps.py +112 -0
  141. tracekite_core-0.1.1/src/tracekite/services/ingest_source.py +300 -0
  142. tracekite_core-0.1.1/src/tracekite/services/ingest_upload.py +92 -0
  143. tracekite_core-0.1.1/src/tracekite/services/ingestion_service.py +232 -0
  144. tracekite_core-0.1.1/src/tracekite/services/job_handlers.py +131 -0
  145. tracekite_core-0.1.1/src/tracekite/services/job_queue.py +229 -0
  146. tracekite_core-0.1.1/src/tracekite/services/js_route_extractor.py +855 -0
  147. tracekite_core-0.1.1/src/tracekite/services/jvm_route_extractor.py +267 -0
  148. tracekite_core-0.1.1/src/tracekite/services/link_writer.py +124 -0
  149. tracekite_core-0.1.1/src/tracekite/services/linker/__init__.py +3 -0
  150. tracekite_core-0.1.1/src/tracekite/services/linker/alias_suggestions.py +111 -0
  151. tracekite_core-0.1.1/src/tracekite/services/linker/base.py +507 -0
  152. tracekite_core-0.1.1/src/tracekite/services/linker/confidence_math.py +75 -0
  153. tracekite_core-0.1.1/src/tracekite/services/linker/contract_drift.py +80 -0
  154. tracekite_core-0.1.1/src/tracekite/services/linker/crossings.py +48 -0
  155. tracekite_core-0.1.1/src/tracekite/services/linker/deprecations.py +60 -0
  156. tracekite_core-0.1.1/src/tracekite/services/linker/edge_policy.py +87 -0
  157. tracekite_core-0.1.1/src/tracekite/services/linker/engine.py +303 -0
  158. tracekite_core-0.1.1/src/tracekite/services/linker/history.py +185 -0
  159. tracekite_core-0.1.1/src/tracekite/services/linker/hooks.py +125 -0
  160. tracekite_core-0.1.1/src/tracekite/services/linker/impact.py +255 -0
  161. tracekite_core-0.1.1/src/tracekite/services/linker/incremental.py +202 -0
  162. tracekite_core-0.1.1/src/tracekite/services/linker/map_view.py +76 -0
  163. tracekite_core-0.1.1/src/tracekite/services/linker/modules.py +63 -0
  164. tracekite_core-0.1.1/src/tracekite/services/linker/normalize.py +287 -0
  165. tracekite_core-0.1.1/src/tracekite/services/linker/partitions.py +139 -0
  166. tracekite_core-0.1.1/src/tracekite/services/linker/path_algebra.py +124 -0
  167. tracekite_core-0.1.1/src/tracekite/services/linker/ports.py +65 -0
  168. tracekite_core-0.1.1/src/tracekite/services/linker/r0_alias.py +303 -0
  169. tracekite_core-0.1.1/src/tracekite/services/linker/r10_dataset.py +135 -0
  170. tracekite_core-0.1.1/src/tracekite/services/linker/r11_agent.py +159 -0
  171. tracekite_core-0.1.1/src/tracekite/services/linker/r12_owner.py +89 -0
  172. tracekite_core-0.1.1/src/tracekite/services/linker/r13_webhook.py +80 -0
  173. tracekite_core-0.1.1/src/tracekite/services/linker/r14_operation.py +97 -0
  174. tracekite_core-0.1.1/src/tracekite/services/linker/r1_compose.py +65 -0
  175. tracekite_core-0.1.1/src/tracekite/services/linker/r2_k8s.py +219 -0
  176. tracekite_core-0.1.1/src/tracekite/services/linker/r3_library.py +160 -0
  177. tracekite_core-0.1.1/src/tracekite/services/linker/r4_gateway.py +95 -0
  178. tracekite_core-0.1.1/src/tracekite/services/linker/r5_grpc.py +174 -0
  179. tracekite_core-0.1.1/src/tracekite/services/linker/r6_topic.py +290 -0
  180. tracekite_core-0.1.1/src/tracekite/services/linker/r7_http.py +259 -0
  181. tracekite_core-0.1.1/src/tracekite/services/linker/r8_graphql.py +134 -0
  182. tracekite_core-0.1.1/src/tracekite/services/linker/r9_env.py +105 -0
  183. tracekite_core-0.1.1/src/tracekite/services/linker/r9_env_index.py +174 -0
  184. tracekite_core-0.1.1/src/tracekite/services/linker/reconciliation.py +82 -0
  185. tracekite_core-0.1.1/src/tracekite/services/linker/registry.py +169 -0
  186. tracekite_core-0.1.1/src/tracekite/services/linker/reliability.py +138 -0
  187. tracekite_core-0.1.1/src/tracekite/services/linker/review_labels.py +36 -0
  188. tracekite_core-0.1.1/src/tracekite/services/linker/rollup_view.py +110 -0
  189. tracekite_core-0.1.1/src/tracekite/services/linker/rollups.py +155 -0
  190. tracekite_core-0.1.1/src/tracekite/services/linker/service.py +121 -0
  191. tracekite_core-0.1.1/src/tracekite/services/linker/traverse.py +47 -0
  192. tracekite_core-0.1.1/src/tracekite/services/linker/values.py +143 -0
  193. tracekite_core-0.1.1/src/tracekite/services/linker/vendors.py +106 -0
  194. tracekite_core-0.1.1/src/tracekite/services/linker_store.py +119 -0
  195. tracekite_core-0.1.1/src/tracekite/services/manifest_lines.py +142 -0
  196. tracekite_core-0.1.1/src/tracekite/services/messaging_extractor.py +693 -0
  197. tracekite_core-0.1.1/src/tracekite/services/parallel_map.py +178 -0
  198. tracekite_core-0.1.1/src/tracekite/services/parse_budget.py +54 -0
  199. tracekite_core-0.1.1/src/tracekite/services/php_route_extractor.py +100 -0
  200. tracekite_core-0.1.1/src/tracekite/services/rb_route_extractor.py +139 -0
  201. tracekite_core-0.1.1/src/tracekite/services/redaction.py +152 -0
  202. tracekite_core-0.1.1/src/tracekite/services/reingest.py +90 -0
  203. tracekite_core-0.1.1/src/tracekite/services/repo_service.py +221 -0
  204. tracekite_core-0.1.1/src/tracekite/services/repo_summary.py +26 -0
  205. tracekite_core-0.1.1/src/tracekite/services/scan.py +299 -0
  206. tracekite_core-0.1.1/src/tracekite/services/scip_import.py +132 -0
  207. tracekite_core-0.1.1/src/tracekite/services/sharded_scan.py +110 -0
  208. tracekite_core-0.1.1/src/tracekite/services/sink_merge.py +53 -0
  209. tracekite_core-0.1.1/src/tracekite/source_meta.py +158 -0
  210. tracekite_core-0.1.1/src/tracekite/status_classify.py +64 -0
  211. tracekite_core-0.1.1/src/tracekite/telemetry.py +92 -0
  212. tracekite_core-0.1.1/src/tracekite/utils/__init__.py +0 -0
  213. tracekite_core-0.1.1/src/tracekite/utils/canonical.py +78 -0
  214. tracekite_core-0.1.1/src/tracekite/utils/evidence.py +77 -0
  215. tracekite_core-0.1.1/src/tracekite/utils/hashing.py +141 -0
  216. tracekite_core-0.1.1/src/tracekite/utils/paths.py +110 -0
  217. tracekite_core-0.1.1/src/tracekite/utils/rendezvous_ids.py +82 -0
  218. tracekite_core-0.1.1/src/tracekite/wire.py +143 -0
@@ -0,0 +1,111 @@
1
+ # See https://docs.github.com/en/get-started/getting-started-with-git/ignoring-files for more about ignoring files.
2
+
3
+ # Environment variables — never commit real credentials
4
+ # Every .env variant is secret-bearing. Backups like `.env.bak-19k` were
5
+ # NOT matched by the old three-pattern list and would have been committed.
6
+ .env*
7
+ !.env.example
8
+
9
+ # compiled output
10
+ /build/
11
+ dist
12
+ tmp
13
+ out-tsc
14
+ *.tsbuildinfo
15
+ .expo
16
+ .expo-shared
17
+
18
+ # dependencies
19
+ node_modules
20
+
21
+ # Python
22
+ __pycache__/
23
+ *.py[cod]
24
+ *.egg-info/
25
+ .pytest_cache/
26
+ .mypy_cache/
27
+ .ruff_cache/
28
+ .venv/
29
+ venv/
30
+
31
+ # Test coverage
32
+ .coverage
33
+ .coverage.*
34
+ coverage.xml
35
+ htmlcov/
36
+
37
+ # IDEs and editors
38
+ /.idea
39
+ .project
40
+ .classpath
41
+ .c9/
42
+ *.launch
43
+ .settings/
44
+ *.sublime-workspace
45
+
46
+ # IDE - VSCode
47
+ .vscode/*
48
+ !.vscode/settings.json
49
+ !.vscode/tasks.json
50
+ !.vscode/launch.json
51
+ !.vscode/extensions.json
52
+
53
+ # misc
54
+ /.sass-cache
55
+ /connect.lock
56
+ /coverage
57
+ /libpeerconnection.log
58
+ npm-debug.log
59
+ yarn-error.log
60
+ testem.log
61
+ /typings
62
+
63
+ # System Files
64
+ .DS_Store
65
+ Thumbs.db
66
+
67
+ .cursor/rules/nx-rules.mdc
68
+ .github/instructions/nx.instructions.md
69
+
70
+ # Local Neo4j instance (data + binaries)
71
+ .neo4j/
72
+ neo4j_data/
73
+ neo4j_logs/
74
+
75
+ # Runtime state — data, not source. Cloned repos land in $WORKSPACE_DIR,
76
+ # which defaults to /tmp outside the tree and is a Docker named volume
77
+ # in compose (docker-compose.yml), never a path under the repo.
78
+ var/
79
+ *.pid
80
+
81
+ # Working artifacts of building this, not part of what is published.
82
+ # The roadmap CSVs are a closed task list (89/89) and a capability matrix
83
+ # kept alongside it; `.agents/memory` is an agent's notes between sessions.
84
+ # Nothing in the tree may read them — `test_source_hygiene.py` carries its
85
+ # own frozen copy of the ids for exactly that reason.
86
+ docs/design/*-roadmap.csv
87
+
88
+ # Pasted conversation fragments. They arrive with a `Pasted-...` name, carry
89
+ # whatever was on the clipboard — another project's tracker ids, findings
90
+ # about a running system — and are nobody's source.
91
+ attached_assets/
92
+
93
+ # Assistant runtime state is not project source. The release-owned TraceKite
94
+ # plugin and its two marketplace manifests are narrow exceptions below.
95
+ # `AGENTS.md` and `CLAUDE.md` are deliberately not ignored: they are written
96
+ # repository rules, not runtime state.
97
+ .claude/
98
+ .superpowers/
99
+ .cursor/
100
+ .windsurf/
101
+ .aider*
102
+ .github/copilot-instructions.md
103
+ **/skills/*/SKILL.md
104
+ .mcp.json
105
+ .agents/
106
+ !.agents/
107
+ .agents/*
108
+ !.agents/plugins/
109
+ .agents/plugins/*
110
+ !.agents/plugins/marketplace.json
111
+ !plugins/tracekite/skills/tracekite/SKILL.md
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright 2026 The TraceKite Authors
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
@@ -0,0 +1,78 @@
1
+ Metadata-Version: 2.5
2
+ Name: tracekite-core
3
+ Version: 0.1.1
4
+ Summary: Establish what is connected across repositories, and how you know.
5
+ Project-URL: Homepage, https://github.com/TraceKite/tracekite
6
+ Project-URL: Repository, https://github.com/TraceKite/tracekite
7
+ Project-URL: Issues, https://github.com/TraceKite/tracekite/issues
8
+ Project-URL: Documentation, https://github.com/TraceKite/tracekite#readme
9
+ Project-URL: Changelog, https://github.com/TraceKite/tracekite/blob/main/CHANGELOG.md
10
+ Author: TraceKite
11
+ License-Expression: Apache-2.0
12
+ License-File: LICENSE
13
+ Keywords: code-intelligence,dependencies,graph,mcp
14
+ Classifier: Development Status :: 3 - Alpha
15
+ Classifier: License :: OSI Approved :: Apache Software License
16
+ Classifier: Programming Language :: Python :: 3 :: Only
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Programming Language :: Python :: 3.14
19
+ Requires-Python: >=3.13
20
+ Requires-Dist: pydantic>=2.13.4
21
+ Requires-Dist: pyyaml>=6.0.3
22
+ Requires-Dist: tree-sitter-c-sharp==0.23.1
23
+ Requires-Dist: tree-sitter-c==0.23.6
24
+ Requires-Dist: tree-sitter-cpp==0.23.4
25
+ Requires-Dist: tree-sitter-go>=0.25.0
26
+ Requires-Dist: tree-sitter-java>=0.23.5
27
+ Requires-Dist: tree-sitter-javascript>=0.25.0
28
+ Requires-Dist: tree-sitter-json==0.24.8
29
+ Requires-Dist: tree-sitter-kotlin==1.1.0
30
+ Requires-Dist: tree-sitter-php==0.23.11
31
+ Requires-Dist: tree-sitter-python>=0.25.0
32
+ Requires-Dist: tree-sitter-ruby==0.23.1
33
+ Requires-Dist: tree-sitter-rust>=0.24.2
34
+ Requires-Dist: tree-sitter-scala==0.24.0
35
+ Requires-Dist: tree-sitter-typescript>=0.23.2
36
+ Requires-Dist: tree-sitter-yaml==0.7.2
37
+ Requires-Dist: tree-sitter>=0.26.0
38
+ Provides-Extra: languages
39
+ Requires-Dist: tree-sitter-css>=0.23.2; extra == 'languages'
40
+ Requires-Dist: tree-sitter-html>=0.23.2; extra == 'languages'
41
+ Provides-Extra: neo4j
42
+ Requires-Dist: neo4j>=6.2.0; extra == 'neo4j'
43
+ Provides-Extra: server
44
+ Requires-Dist: fastapi>=0.140.0; extra == 'server'
45
+ Requires-Dist: gitpython>=3.1.57; extra == 'server'
46
+ Requires-Dist: httpx>=0.28.1; extra == 'server'
47
+ Requires-Dist: pydantic-settings>=2.14.2; extra == 'server'
48
+ Requires-Dist: python-multipart>=0.0.32; extra == 'server'
49
+ Requires-Dist: uvicorn[standard]>=0.51.0; extra == 'server'
50
+ Description-Content-Type: text/markdown
51
+
52
+ # tracekite-core
53
+
54
+ `tracekite-core` scans source repositories and establishes dependency edges only
55
+ when both sides meet on a deterministic key. Every returned edge includes
56
+ file-and-line evidence, while ambiguous signals are declined and counted.
57
+
58
+ The distribution contains the library and the `tracekite` CLI without requiring
59
+ FastAPI or Neo4j:
60
+
61
+ ```bash
62
+ pip install tracekite-core
63
+ tracekite link /path/to/service-a /path/to/service-b
64
+ ```
65
+
66
+ Use `tracekite mcp` to expose `services`, `consumers_of`, `trace`, and
67
+ `deprecations` over MCP stdio. With no path arguments, it scans the current
68
+ repository on the first graph query.
69
+
70
+ `tracekite ingest` talks to a running TraceKite server and needs the server
71
+ extra:
72
+
73
+ ```bash
74
+ pip install 'tracekite-core[server]'
75
+ ```
76
+
77
+ Documentation and source are available in the
78
+ [TraceKite repository](https://github.com/TraceKite/tracekite).
@@ -0,0 +1,27 @@
1
+ # tracekite-core
2
+
3
+ `tracekite-core` scans source repositories and establishes dependency edges only
4
+ when both sides meet on a deterministic key. Every returned edge includes
5
+ file-and-line evidence, while ambiguous signals are declined and counted.
6
+
7
+ The distribution contains the library and the `tracekite` CLI without requiring
8
+ FastAPI or Neo4j:
9
+
10
+ ```bash
11
+ pip install tracekite-core
12
+ tracekite link /path/to/service-a /path/to/service-b
13
+ ```
14
+
15
+ Use `tracekite mcp` to expose `services`, `consumers_of`, `trace`, and
16
+ `deprecations` over MCP stdio. With no path arguments, it scans the current
17
+ repository on the first graph query.
18
+
19
+ `tracekite ingest` talks to a running TraceKite server and needs the server
20
+ extra:
21
+
22
+ ```bash
23
+ pip install 'tracekite-core[server]'
24
+ ```
25
+
26
+ Documentation and source are available in the
27
+ [TraceKite repository](https://github.com/TraceKite/tracekite).
@@ -0,0 +1,29 @@
1
+ """Make the external source tree self-contained in wheels and sdists."""
2
+
3
+ from pathlib import Path
4
+
5
+ from hatchling.builders.hooks.plugin.interface import BuildHookInterface
6
+
7
+
8
+ class CustomBuildHook(BuildHookInterface):
9
+ def initialize(self, version: str, build_data: dict) -> None:
10
+ project = Path(self.root)
11
+ package = self.config["package"]
12
+ embedded = project / "src" / package
13
+ checkout = project.parents[1]
14
+
15
+ if self.target_name == "sdist":
16
+ if embedded.is_dir():
17
+ return
18
+ build_data["force_include"][str(checkout / "backend/tracekite")] = \
19
+ f"src/{package}"
20
+ build_data["force_include"][str(checkout / "config")] = \
21
+ f"src/{package}/_control_plane"
22
+ return
23
+
24
+ source = embedded if embedded.is_dir() else checkout / "backend/tracekite"
25
+ build_data["force_include"][str(source)] = package
26
+ if source == embedded:
27
+ return
28
+ build_data["force_include"][str(checkout / "config")] = \
29
+ f"{package}/_control_plane"
@@ -0,0 +1,85 @@
1
+ # The library distribution: the engine, and nothing that serves it.
2
+ #
3
+ # `dependencies` below is not hand-maintained guesswork — it is the measured
4
+ # import closure of the core and parsers layers, and
5
+ # `backend/tests/test_packaging.py` fails if the two drift apart. A dependency
6
+ # list that is merely aspirational is how "no heavy deps" quietly stops being
7
+ # true.
8
+ #
9
+ # Deliberately absent: neo4j, fastapi, starlette, uvicorn, pydantic-settings.
10
+ # A host that already runs a graph database must not be made to install a
11
+ # second one, and a host with no web server must not acquire one.
12
+ [build-system]
13
+ requires = ["hatchling"]
14
+ build-backend = "hatchling.build"
15
+
16
+ [project]
17
+ name = "tracekite-core"
18
+ version = "0.1.1"
19
+ description = "Establish what is connected across repositories, and how you know."
20
+ readme = "README.md"
21
+ requires-python = ">=3.13"
22
+ license = "Apache-2.0"
23
+ license-files = ["LICENSE"]
24
+ authors = [{ name = "TraceKite" }]
25
+ keywords = ["code-intelligence", "dependencies", "graph", "mcp"]
26
+ classifiers = [
27
+ "Development Status :: 3 - Alpha",
28
+ "License :: OSI Approved :: Apache Software License",
29
+ "Programming Language :: Python :: 3 :: Only",
30
+ "Programming Language :: Python :: 3.13",
31
+ "Programming Language :: Python :: 3.14",
32
+ ]
33
+
34
+ dependencies = [
35
+ "pydantic>=2.13.4",
36
+ "pyyaml>=6.0.3",
37
+ "tree-sitter>=0.26.0",
38
+ "tree-sitter-c==0.23.6",
39
+ "tree-sitter-c-sharp==0.23.1",
40
+ "tree-sitter-cpp==0.23.4",
41
+ "tree-sitter-go>=0.25.0",
42
+ "tree-sitter-java>=0.23.5",
43
+ "tree-sitter-javascript>=0.25.0",
44
+ "tree-sitter-json==0.24.8",
45
+ "tree-sitter-kotlin==1.1.0",
46
+ "tree-sitter-php==0.23.11",
47
+ "tree-sitter-python>=0.25.0",
48
+ "tree-sitter-ruby==0.23.1",
49
+ "tree-sitter-rust>=0.24.2",
50
+ "tree-sitter-scala==0.24.0",
51
+ "tree-sitter-typescript>=0.23.2",
52
+ "tree-sitter-yaml==0.7.2",
53
+ ]
54
+
55
+ [project.urls]
56
+ Homepage = "https://github.com/TraceKite/tracekite"
57
+ Repository = "https://github.com/TraceKite/tracekite"
58
+ Issues = "https://github.com/TraceKite/tracekite/issues"
59
+ Documentation = "https://github.com/TraceKite/tracekite#readme"
60
+ Changelog = "https://github.com/TraceKite/tracekite/blob/main/CHANGELOG.md"
61
+
62
+ # The application's extras, so one repository serves both surfaces without a
63
+ # second copy of the engine (the "no duplicate code" rule, at package level).
64
+ [project.optional-dependencies]
65
+ # Grammars whose imports are guarded: parsing degrades with a log line when
66
+ # they are absent, so they are opt-in rather than a cost every host pays.
67
+ languages = ["tree-sitter-html>=0.23.2", "tree-sitter-css>=0.23.2"]
68
+ neo4j = ["neo4j>=6.2.0"]
69
+ server = ["fastapi>=0.140.0", "uvicorn[standard]>=0.51.0",
70
+ "pydantic-settings>=2.14.2", "python-multipart>=0.0.32",
71
+ "gitpython>=3.1.57", "httpx>=0.28.1"]
72
+
73
+ [project.scripts]
74
+ tracekite = "tracekite.cli:main"
75
+
76
+ [tool.hatch.build.targets.wheel]
77
+ bypass-selection = true
78
+
79
+ # Source still lives under `backend/tracekite`. The build hook maps that tree and
80
+ # the calibrated control plane into both the wheel and the sdist. For a wheel
81
+ # rebuilt from the sdist, it uses the sdist's own `src/tracekite` copy instead of
82
+ # reaching outside the extracted archive.
83
+ [tool.hatch.build.hooks.custom]
84
+ path = "hatch_build.py"
85
+ package = "tracekite"
File without changes