tscode-kg 0.2.0__py3-none-any.whl
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.
- tscode_kg/__init__.py +42 -0
- tscode_kg/__main__.py +6 -0
- tscode_kg/analysis.py +1829 -0
- tscode_kg/app.py +1355 -0
- tscode_kg/bridge.py +114 -0
- tscode_kg/centrality.py +434 -0
- tscode_kg/cli/__init__.py +1 -0
- tscode_kg/cli/cmd_analyze.py +69 -0
- tscode_kg/cli/cmd_bridges.py +38 -0
- tscode_kg/cli/cmd_build.py +86 -0
- tscode_kg/cli/cmd_centrality.py +124 -0
- tscode_kg/cli/cmd_explain.py +58 -0
- tscode_kg/cli/cmd_framework_nodes.py +43 -0
- tscode_kg/cli/cmd_hooks.py +125 -0
- tscode_kg/cli/cmd_init.py +234 -0
- tscode_kg/cli/cmd_mcp.py +35 -0
- tscode_kg/cli/cmd_model.py +52 -0
- tscode_kg/cli/cmd_query.py +75 -0
- tscode_kg/cli/cmd_snapshot.py +431 -0
- tscode_kg/cli/cmd_viz.py +175 -0
- tscode_kg/cli/main.py +56 -0
- tscode_kg/coderank.py +564 -0
- tscode_kg/config.py +36 -0
- tscode_kg/explain.py +270 -0
- tscode_kg/extractor.py +827 -0
- tscode_kg/framework_detector.py +106 -0
- tscode_kg/kg.py +193 -0
- tscode_kg/layout3d.py +492 -0
- tscode_kg/mcp_server.py +1412 -0
- tscode_kg/snapshots.py +64 -0
- tscode_kg/viz3d.py +1457 -0
- tscode_kg/viz3d_timeline.py +369 -0
- tscode_kg-0.2.0.dist-info/METADATA +196 -0
- tscode_kg-0.2.0.dist-info/RECORD +37 -0
- tscode_kg-0.2.0.dist-info/WHEEL +4 -0
- tscode_kg-0.2.0.dist-info/entry_points.txt +15 -0
- tscode_kg-0.2.0.dist-info/licenses/LICENSE +24 -0
tscode_kg/__init__.py
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"""
|
|
2
|
+
tscode_kg: Knowledge graph for TypeScript/JavaScript codebases.
|
|
3
|
+
|
|
4
|
+
Pure tree-sitter AST extraction → SQLite (authoritative) → sqlite-vec (semantic index).
|
|
5
|
+
|
|
6
|
+
Primary entry point::
|
|
7
|
+
|
|
8
|
+
from tscode_kg import TypeScriptKG
|
|
9
|
+
|
|
10
|
+
kg = TypeScriptKG(repo_root="/path/to/ts-repo")
|
|
11
|
+
stats = kg.build(wipe=True)
|
|
12
|
+
result = kg.query("authentication middleware")
|
|
13
|
+
pack = kg.pack("error handling utilities")
|
|
14
|
+
pack.save("context.md")
|
|
15
|
+
|
|
16
|
+
KGExtractor SDK::
|
|
17
|
+
|
|
18
|
+
from tscode_kg import TSCodeExtractor
|
|
19
|
+
"""
|
|
20
|
+
|
|
21
|
+
__version__ = "0.2.0"
|
|
22
|
+
__author__ = "Eric G. Suchanek, PhD"
|
|
23
|
+
|
|
24
|
+
from tscode_kg.extractor import TSCodeExtractor
|
|
25
|
+
|
|
26
|
+
__all__ = [
|
|
27
|
+
"TSCodeExtractor",
|
|
28
|
+
]
|
|
29
|
+
|
|
30
|
+
try:
|
|
31
|
+
from tscode_kg.analysis import TSCodeKGAnalyzer
|
|
32
|
+
from tscode_kg.kg import BuildStats, QueryResult, SnippetPack, TypeScriptKG
|
|
33
|
+
|
|
34
|
+
__all__ += [
|
|
35
|
+
"TypeScriptKG",
|
|
36
|
+
"TSCodeKGAnalyzer",
|
|
37
|
+
"BuildStats",
|
|
38
|
+
"QueryResult",
|
|
39
|
+
"SnippetPack",
|
|
40
|
+
]
|
|
41
|
+
except ImportError:
|
|
42
|
+
pass # kgmodule-utils[semantic] not installed; extractor still works standalone
|