pycode-kg 0.22.0__tar.gz → 0.23.0__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 (68) hide show
  1. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/PKG-INFO +51 -38
  2. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/README.md +45 -20
  3. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/pyproject.toml +62 -45
  4. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/__init__.py +5 -1
  5. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/__main__.py +4 -0
  6. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/analysis/__init__.py +6 -1
  7. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/analysis/bridge.py +1 -1
  8. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/analysis/centrality.py +3 -1
  9. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/analysis/framework_detector.py +1 -1
  10. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/app.py +4 -0
  11. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/architecture.py +4 -0
  12. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/build_pycodekg_sqlite.py +4 -0
  13. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/__init__.py +5 -0
  14. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_analyze.py +4 -0
  15. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_architecture.py +4 -0
  16. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_bridges.py +4 -0
  17. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_build.py +6 -1
  18. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_build_full.py +6 -1
  19. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_centrality.py +6 -1
  20. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_explain.py +4 -0
  21. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_framework_nodes.py +4 -0
  22. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_hooks.py +5 -1
  23. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_init.py +4 -0
  24. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_mcp.py +4 -0
  25. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_model.py +4 -0
  26. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_query.py +4 -0
  27. pycode_kg-0.23.0/src/pycode_kg/cli/cmd_quilt.py +284 -0
  28. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_snapshot.py +4 -0
  29. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/cmd_viz.py +7 -2
  30. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/main.py +4 -0
  31. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/cli/options.py +4 -0
  32. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/config.py +4 -0
  33. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/explain.py +4 -0
  34. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/graph.py +2 -0
  35. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/graph_html.py +4 -0
  36. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/index.py +6 -1
  37. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/kg.py +6 -11
  38. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/layout3d.py +2 -0
  39. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/mcp_server.py +2 -0
  40. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/module/__init__.py +4 -0
  41. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/module/base.py +10 -3
  42. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/module/extractor.py +2 -0
  43. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/module/types.py +6 -1
  44. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/pycodekg.py +3 -1
  45. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/pycodekg_thorough_analysis.py +567 -880
  46. pycode_kg-0.23.0/src/pycode_kg/ranking/__init__.py +6 -0
  47. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/ranking/cli_rank.py +6 -1
  48. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/ranking/coderank.py +4 -0
  49. pycode_kg-0.23.0/src/pycode_kg/render.py +68 -0
  50. pycode_kg-0.23.0/src/pycode_kg/report.py +604 -0
  51. pycode_kg-0.23.0/src/pycode_kg/resolution.py +95 -0
  52. pycode_kg-0.23.0/src/pycode_kg/scene3d.py +407 -0
  53. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/snapshots.py +1 -1
  54. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/store.py +6 -1
  55. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/theme.py +46 -0
  56. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/utils.py +4 -0
  57. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/visitor.py +28 -0
  58. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/viz3d.py +218 -34
  59. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/viz3d_timeline.py +4 -0
  60. pycode_kg-0.22.0/src/pycode_kg/analysis/hybrid_rank.py +0 -53
  61. pycode_kg-0.22.0/src/pycode_kg/pycodekg_query.py +0 -1
  62. pycode_kg-0.22.0/src/pycode_kg/pycodekg_snippet_packer.py +0 -1
  63. pycode_kg-0.22.0/src/pycode_kg/pycodekg_viz.py +0 -1
  64. pycode_kg-0.22.0/src/pycode_kg/pycodekg_viz3d.py +0 -1
  65. pycode_kg-0.22.0/src/pycode_kg/ranking/__init__.py +0 -1
  66. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/LICENSE +0 -0
  67. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/.DS_Store +0 -0
  68. {pycode_kg-0.22.0 → pycode_kg-0.23.0}/src/pycode_kg/sql/004_add_centrality_table.sql +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pycode-kg
3
- Version: 0.22.0
3
+ Version: 0.23.0
4
4
  Summary: A tool to build a searchable knowledge graph from Python repositories
5
5
  License-Expression: Elastic-2.0
6
6
  License-File: LICENSE
@@ -16,15 +16,13 @@ Classifier: Programming Language :: Python :: 3
16
16
  Classifier: Programming Language :: Python :: 3.12
17
17
  Classifier: Programming Language :: Python :: 3.13
18
18
  Provides-Extra: all
19
- Provides-Extra: dev
20
19
  Provides-Extra: viz
21
20
  Provides-Extra: viz3d
22
21
  Requires-Dist: PyQt5 (>=5.15.0) ; extra == "all"
23
22
  Requires-Dist: PyQt5 (>=5.15.0) ; extra == "viz3d"
24
23
  Requires-Dist: click (>=8.1.0,<9)
25
- Requires-Dist: detect-secrets (>=1.5.0) ; extra == "all"
26
- Requires-Dist: detect-secrets (>=1.5.0) ; extra == "dev"
27
- Requires-Dist: kgmodule-utils[semantic,viz3d] (>=0.11.0)
24
+ Requires-Dist: kgmodule-utils[semantic,viz3d] (>=0.12.1)
25
+ Requires-Dist: kgmodule-utils[viz3d-render] (>=0.12.1) ; extra == "viz3d"
28
26
  Requires-Dist: markdown (>=3.6) ; extra == "all"
29
27
  Requires-Dist: markdown (>=3.6) ; extra == "viz3d"
30
28
  Requires-Dist: mcp (>=1.0.0,<2)
@@ -33,34 +31,24 @@ Requires-Dist: numpy (>=1.24.0)
33
31
  Requires-Dist: pandas (>=2.0.0)
34
32
  Requires-Dist: param (>=2.0.0) ; extra == "all"
35
33
  Requires-Dist: param (>=2.0.0) ; extra == "viz3d"
36
- Requires-Dist: pdoc (>=14.0.0) ; extra == "all"
37
- Requires-Dist: pdoc (>=14.0.0) ; extra == "dev"
38
34
  Requires-Dist: plotly (>=5.14.0) ; extra == "all"
39
35
  Requires-Dist: plotly (>=5.14.0) ; extra == "viz"
40
- Requires-Dist: pre-commit (>=4.5.1) ; extra == "all"
41
- Requires-Dist: pre-commit (>=4.5.1) ; extra == "dev"
42
- Requires-Dist: pytest (>=8.0.0) ; extra == "all"
43
- Requires-Dist: pytest (>=8.0.0) ; extra == "dev"
44
- Requires-Dist: pytest-cov (>=5.0.0) ; extra == "all"
45
- Requires-Dist: pytest-cov (>=5.0.0) ; extra == "dev"
46
36
  Requires-Dist: pyvis (>=0.3.2) ; extra == "all"
47
37
  Requires-Dist: pyvis (>=0.3.2) ; extra == "viz"
48
38
  Requires-Dist: pyvista (>=0.44.0) ; extra == "all"
49
- Requires-Dist: pyvista (>=0.44.0) ; extra == "viz3d"
50
39
  Requires-Dist: pyvistaqt (>=0.11.0) ; extra == "all"
51
40
  Requires-Dist: pyvistaqt (>=0.11.0) ; extra == "viz3d"
41
+ Requires-Dist: quiltwright (>=0.4.0) ; extra == "all"
42
+ Requires-Dist: quiltwright (>=0.4.0) ; extra == "viz3d"
52
43
  Requires-Dist: rich (>=14.3.3,<15)
53
- Requires-Dist: ruff (>=0.4.0) ; extra == "all"
54
- Requires-Dist: ruff (>=0.4.0) ; extra == "dev"
55
44
  Requires-Dist: sentence-transformers (>=5.4.1)
56
45
  Requires-Dist: sqlite-vec (==0.1.9)
46
+ Requires-Dist: starlette (>=0.49.1,<1.4.0)
57
47
  Requires-Dist: streamlit (>=1.56.0) ; extra == "all"
58
48
  Requires-Dist: streamlit (>=1.56.0) ; extra == "viz"
59
49
  Requires-Dist: torch (>=2.5.1)
60
50
  Requires-Dist: trame-vtk (>=2.0.0) ; extra == "all"
61
51
  Requires-Dist: trame-vtk (>=2.0.0) ; extra == "viz3d"
62
- Requires-Dist: ty (>=0.0.41) ; extra == "all"
63
- Requires-Dist: ty (>=0.0.41) ; extra == "dev"
64
52
  Project-URL: Homepage, https://github.com/Flux-Frontiers/pycode_kg
65
53
  Project-URL: Repository, https://github.com/Flux-Frontiers/pycode_kg
66
54
  Description-Content-Type: text/markdown
@@ -72,7 +60,7 @@ Description-Content-Type: text/markdown
72
60
 
73
61
  [![Python](https://img.shields.io/badge/python-3.12%20%7C%203.13-blue.svg)](https://www.python.org/)
74
62
  [![License: Elastic-2.0](https://img.shields.io/badge/License-Elastic%202.0-blue.svg)](https://www.elastic.co/licensing/elastic-license)
75
- [![Version](https://img.shields.io/badge/version-0.22.0-blue.svg)](https://github.com/Flux-Frontiers/pycode_kg/releases)
63
+ [![Version](https://img.shields.io/badge/version-0.23.0-blue.svg)](https://github.com/Flux-Frontiers/pycode_kg/releases)
76
64
  [![CI](https://github.com/Flux-Frontiers/pycode_kg/actions/workflows/ci.yml/badge.svg)](https://github.com/Flux-Frontiers/pycode_kg/actions/workflows/ci.yml)
77
65
  [![Poetry](https://img.shields.io/endpoint?url=https://python-poetry.org/badge/v0.json)](https://python-poetry.org/)
78
66
  [![DOI](https://zenodo.org/badge/1202379010.svg)](https://zenodo.org/badge/latestdoi/1202379010)
@@ -81,7 +69,7 @@ Description-Content-Type: text/markdown
81
69
 
82
70
  **PyCodeKG turns a Python codebase into a deterministic, queryable knowledge graph — and uses it to produce architectural analyses you can act on, with or without an LLM in the loop.**
83
71
 
84
- It walks the AST of every module, class, function, and method in your repo, extracts the typed relationships that actually hold the code together (`CONTAINS`, `CALLS`, `IMPORTS`, `INHERITS`, `RESOLVES_TO`), and stores the result in SQLite. A sqlite-vec vector index sits alongside the graph so that *"authentication flow"* and *"verify_jwt"* both find the right place to start exploring. From there you can rank functions by structural importance, trace fan-in across import aliases, detect circular imports and dead code, render the call graph in 3D, snapshot metrics for diffing across releases, or hand the whole thing to Claude over MCP.
72
+ It walks the AST of every module, class, function, and method in your repo, extracts the typed relationships that actually hold the code together (`CONTAINS`, `CALLS`, `IMPORTS`, `INHERITS`, `RESOLVES_TO`), and stores the result in SQLite. A sqlite-vec vector index sits alongside the graph so that *"authentication flow"* and *"verify_jwt"* both find the right place to start exploring. From there you can rank functions by structural importance, trace fan-in across import aliases, detect circular imports and dead code, render the call graph in 3D, grow the repo as a tree you can put on a holographic display, snapshot metrics for diffing across releases, or hand the whole thing to Claude over MCP.
85
73
 
86
74
  The original motivation was simple: **produce thorough, defensible analyses of Python codebases that don't depend on inference**. Every result is computed from the AST and the graph — no model is asked to guess. When an LLM is present, it consumes the *same* grounded output as a structured context pack, and the hallucinations that plague "embed-the-repo" tools largely disappear.
87
75
 
@@ -93,15 +81,11 @@ Everything runs on your laptop. No cloud APIs, no quotas, no source code leaving
93
81
 
94
82
  ## Sister projects
95
83
 
96
- PyCodeKG is part of a growing family of knowledge-graph systems that share the same hybrid semantic-plus-structural design — each one applies it to a different kind of corpus:
97
-
98
- - **[DocKG](https://github.com/Flux-Frontiers/doc_kg)** — Markdown and prose. Indexes PyCodeKG's own documentation, so the docs you're reading are themselves a queryable graph.
99
- - **[MetaboKG](https://github.com/Flux-Frontiers/metabo_kg)** — metabolic pathway data (KEGG, SBML, BioPAX), with FBA / ODE simulation on top of the graph.
100
- - **[DiaryKG](https://github.com/Flux-Frontiers/diary_kg)** — personal journals and diary corpora; semantic search and graph traversal over a writer's body of work.
101
- - **[FTreeKG](https://github.com/Flux-Frontiers/FTreeKG)** — filesystem trees as a queryable graph of directories, files, and contents.
102
- - **[AgentKG](https://github.com/Flux-Frontiers/agent_kg)** — conversational memory as a knowledge graph: turns, decisions, commitments, preferences, and the relationships between them.
103
-
104
- Together they form **KGRAG**, a federated retrieval layer where one query can span code, documentation, journals, filesystems, agent memory, and domain data simultaneously.
84
+ PyCodeKG is one of ten knowledge graphs sharing the same hybrid
85
+ semantic-plus-structural design — code, prose, journals, filesystems, agent
86
+ memory, metabolic pathways — federated by **[KGRAG](https://github.com/Flux-Frontiers/KGRAG)**
87
+ so a single query can span all of them. The full list is in
88
+ [docs/SISTER_PROJECTS.md](docs/SISTER_PROJECTS.md).
105
89
 
106
90
  ---
107
91
 
@@ -184,7 +168,7 @@ pycodekg init --repo . # download model, build graph, install
184
168
  pycodekg analyze . # the architectural report
185
169
  ```
186
170
 
187
- That's the recommended path. Variants (minimal install, MCP-only, contributor setup) are in [docs/INSTALLATION.md](docs/INSTALLATION.md). Every CLI subcommand is also exposed as a script alias (`pycodekg-analyze`, `pycodekg-build`, `pycodekg-mcp`, …) for use in Makefiles and Poetry projects.
171
+ That's the recommended path. Variants (minimal install, MCP-only, contributor setup) are in [docs/INSTALLATION.md](docs/INSTALLATION.md). Every capability is a subcommand of the single `pycodekg` entry point — `pycodekg analyze`, `pycodekg build`, `pycodekg mcp` — so that one name is all a Makefile or an MCP config needs.
188
172
 
189
173
  ---
190
174
 
@@ -201,6 +185,33 @@ The graph is built around four node kinds (module, class, function, method) and
201
185
 
202
186
  ---
203
187
 
188
+ ## The repo as a tree
189
+
190
+ `pycodekg viz3d --layout organic` grows the graph instead of plotting it. A
191
+ skeleton is grown toward the code by space colonization, so the shape is the
192
+ data rather than decoration:
193
+
194
+ - **The trunk** is the repository; its radius follows the pipe model, so it
195
+ reports how much code the tree carries.
196
+ - **Each limb** is a module. Its *length* is how many definitions the module
197
+ holds — the biggest module reaches furthest — and its *thickness* follows
198
+ from the tips it carries.
199
+ - **Each leaf** is a class, function, or method, tinted by kind.
200
+
201
+ `pycodekg quilt` renders that tree for a [Looking
202
+ Glass](https://lookingglassfactory.com/) light-field display: a multi-view
203
+ quilt the panel fuses into real depth, with `--cast` to send it straight to
204
+ the device. Every render prints its disparity budget first, so you know
205
+ whether the display will fuse the views or ghost them. Details in
206
+ [docs/VIZ3D.md](docs/VIZ3D.md).
207
+
208
+ The growth engine is shared across the KG fleet
209
+ ([kgmodule-utils](https://pypi.org/project/kgmodule-utils/)) and the
210
+ light-field output is [quiltwright](https://pypi.org/project/quiltwright/);
211
+ what lives here is only the mapping from code to wood.
212
+
213
+ ---
214
+
204
215
  ## What you can do with it
205
216
 
206
217
  | If you want to… | Reach for | Detail |
@@ -214,6 +225,8 @@ The graph is built around four node kinds (module, class, function, method) and
214
225
  | **Browse the graph interactively** | `pycodekg viz` (Streamlit) | [docs/INSTALLATION.md](docs/INSTALLATION.md) |
215
226
  | **Share a graph as one file** | `pycodekg viz-export -o graph.html` | opens from `file://`, no server |
216
227
  | **See call graphs in 3-D** *(active development — functional but rough)* | `pycodekg viz3d --layout funnel` | [docs/VIZ3D.md](docs/VIZ3D.md) |
228
+ | **Grow the repo as a tree** | `pycodekg viz3d --layout organic` | modules are limbs, definitions are leaves |
229
+ | **Render it for a Looking Glass display** | `pycodekg quilt --spec 16-landscape` | [docs/VIZ3D.md](docs/VIZ3D.md) |
217
230
  | **Wire it into Claude / Copilot / Cline** | `pycodekg mcp` | [docs/MCP.md](docs/MCP.md) |
218
231
 
219
232
  If you only read one doc after this one, read [docs/Analyze.md](docs/Analyze.md) — that's where most of the day-to-day value lives.
@@ -229,21 +242,20 @@ src/pycode_kg/
229
242
  ├── store.py # SQLite persistence + canonical edges
230
243
  ├── index.py # sqlite-vec semantic index
231
244
  ├── pycodekg.py # Public façade
232
- ├── pycodekg_query.py # Hybrid query
233
- ├── pycodekg_snippet_packer.py # Source-grounded packs
234
245
  ├── pycodekg_thorough_analysis.py # `analyze` engine
235
246
  ├── architecture.py # `architecture` description generator
236
247
  ├── ranking/ # PageRank, bridge centrality, framework nodes
237
248
  ├── snapshots.py # Temporal metric snapshots
238
249
  ├── analysis/ # Coupling, cycles, orphans, hotspots
239
- ├── cli/ # All `pycodekg-*` entry points
250
+ ├── cli/ # `pycodekg` subcommands
240
251
  ├── mcp_server.py # MCP server (nineteen tools)
241
252
  ├── app.py # Streamlit web app
242
253
  ├── viz3d.py / layout3d.py # PyVista/PyQt5 3-D viewer
254
+ ├── scene3d.py # Organic tree: repo → trunk, module → limb
243
255
  └── viz3d_timeline.py # Metric history timeline
244
256
  ```
245
257
 
246
- The MCP server, the CLI, and the Streamlit app are thin wrappers over the same store + index + ranking core — there is exactly one code path for each capability. The latest architectural deep-dive is in [docs/analysis_v0.22.0.md](docs/analysis_v0.22.0.md), produced (of course) by `pycodekg analyze` against this very repo.
258
+ The MCP server, the CLI, and the Streamlit app are thin wrappers over the same store + index + ranking core — there is exactly one code path for each capability. The latest architectural deep-dive is in [docs/analysis_v0.23.0.md](docs/analysis_v0.23.0.md), produced (of course) by `pycodekg analyze` against this very repo.
247
259
 
248
260
  ---
249
261
 
@@ -258,7 +270,8 @@ The MCP server, the CLI, and the Streamlit app are thin wrappers over the same s
258
270
  | [docs/CODERANK.md](docs/CODERANK.md) | SIR PageRank, bridge centrality, framework hubs |
259
271
  | [docs/MCP.md](docs/MCP.md) | MCP server setup for Claude / Kilo / Copilot / Cline, tool reference |
260
272
  | [docs/CHEATSHEET.md](docs/CHEATSHEET.md) | Every CLI flag and every MCP tool — one page |
261
- | [docs/VIZ3D.md](docs/VIZ3D.md) | The 3-D PyVista viewer and layouts |
273
+ | [docs/VIZ3D.md](docs/VIZ3D.md) | The 3-D viewer, the organic tree, and Looking Glass output |
274
+ | [docs/SISTER_PROJECTS.md](docs/SISTER_PROJECTS.md) | The other KGRAG graphs and the shared foundations |
262
275
  | [CHANGELOG.md](CHANGELOG.md) | Release history |
263
276
 
264
277
  ---
@@ -269,13 +282,13 @@ If you use PyCodeKG in your research or project, please cite it:
269
282
 
270
283
  [![DOI](https://zenodo.org/badge/1202379010.svg)](https://zenodo.org/badge/latestdoi/1202379010)
271
284
 
272
- > Suchanek, E. G. (2026). *PyCodeKG: A Knowledge Graph for Python Codebases* (Version 0.22.0) [Software]. Flux-Frontiers. https://doi.org/10.5281/zenodo.19737993
285
+ > Suchanek, E. G. (2026). *PyCodeKG: A Knowledge Graph for Python Codebases* (Version 0.23.0) [Software]. Flux-Frontiers. https://doi.org/10.5281/zenodo.19737993
273
286
 
274
287
  ```bibtex
275
288
  @software{suchanek_pycode_kg,
276
289
  author = {Suchanek, Eric G.},
277
290
  title = {{PyCodeKG}: A Knowledge Graph for Python Codebases},
278
- version = {0.22.0},
291
+ version = {0.23.0},
279
292
  year = {2026},
280
293
  publisher = {Flux-Frontiers},
281
294
  url = {https://github.com/Flux-Frontiers/pycode_kg},
@@ -294,7 +307,7 @@ If you use PyCodeKG in your research or project, please cite it:
294
307
  ## Support & acknowledgments
295
308
 
296
309
  - **Issues** — [GitHub Issues](https://github.com/Flux-Frontiers/pycode_kg/issues)
297
- - Sister projects [DocKG](https://github.com/Flux-Frontiers/doc_kg) and [MetaboKG](https://github.com/Flux-Frontiers/metabo_kg)
310
+ - [Sister projects](docs/SISTER_PROJECTS.md) — the rest of the KGRAG family
298
311
  - sqlite-vec, sentence-transformers, PyVista, Streamlit, and FastMCP for the foundations
299
312
 
300
313
  ---
@@ -5,7 +5,7 @@
5
5
 
6
6
  [![Python](https://img.shields.io/badge/python-3.12%20%7C%203.13-blue.svg)](https://www.python.org/)
7
7
  [![License: Elastic-2.0](https://img.shields.io/badge/License-Elastic%202.0-blue.svg)](https://www.elastic.co/licensing/elastic-license)
8
- [![Version](https://img.shields.io/badge/version-0.22.0-blue.svg)](https://github.com/Flux-Frontiers/pycode_kg/releases)
8
+ [![Version](https://img.shields.io/badge/version-0.23.0-blue.svg)](https://github.com/Flux-Frontiers/pycode_kg/releases)
9
9
  [![CI](https://github.com/Flux-Frontiers/pycode_kg/actions/workflows/ci.yml/badge.svg)](https://github.com/Flux-Frontiers/pycode_kg/actions/workflows/ci.yml)
10
10
  [![Poetry](https://img.shields.io/endpoint?url=https://python-poetry.org/badge/v0.json)](https://python-poetry.org/)
11
11
  [![DOI](https://zenodo.org/badge/1202379010.svg)](https://zenodo.org/badge/latestdoi/1202379010)
@@ -14,7 +14,7 @@
14
14
 
15
15
  **PyCodeKG turns a Python codebase into a deterministic, queryable knowledge graph — and uses it to produce architectural analyses you can act on, with or without an LLM in the loop.**
16
16
 
17
- It walks the AST of every module, class, function, and method in your repo, extracts the typed relationships that actually hold the code together (`CONTAINS`, `CALLS`, `IMPORTS`, `INHERITS`, `RESOLVES_TO`), and stores the result in SQLite. A sqlite-vec vector index sits alongside the graph so that *"authentication flow"* and *"verify_jwt"* both find the right place to start exploring. From there you can rank functions by structural importance, trace fan-in across import aliases, detect circular imports and dead code, render the call graph in 3D, snapshot metrics for diffing across releases, or hand the whole thing to Claude over MCP.
17
+ It walks the AST of every module, class, function, and method in your repo, extracts the typed relationships that actually hold the code together (`CONTAINS`, `CALLS`, `IMPORTS`, `INHERITS`, `RESOLVES_TO`), and stores the result in SQLite. A sqlite-vec vector index sits alongside the graph so that *"authentication flow"* and *"verify_jwt"* both find the right place to start exploring. From there you can rank functions by structural importance, trace fan-in across import aliases, detect circular imports and dead code, render the call graph in 3D, grow the repo as a tree you can put on a holographic display, snapshot metrics for diffing across releases, or hand the whole thing to Claude over MCP.
18
18
 
19
19
  The original motivation was simple: **produce thorough, defensible analyses of Python codebases that don't depend on inference**. Every result is computed from the AST and the graph — no model is asked to guess. When an LLM is present, it consumes the *same* grounded output as a structured context pack, and the hallucinations that plague "embed-the-repo" tools largely disappear.
20
20
 
@@ -26,15 +26,11 @@ Everything runs on your laptop. No cloud APIs, no quotas, no source code leaving
26
26
 
27
27
  ## Sister projects
28
28
 
29
- PyCodeKG is part of a growing family of knowledge-graph systems that share the same hybrid semantic-plus-structural design — each one applies it to a different kind of corpus:
30
-
31
- - **[DocKG](https://github.com/Flux-Frontiers/doc_kg)** — Markdown and prose. Indexes PyCodeKG's own documentation, so the docs you're reading are themselves a queryable graph.
32
- - **[MetaboKG](https://github.com/Flux-Frontiers/metabo_kg)** — metabolic pathway data (KEGG, SBML, BioPAX), with FBA / ODE simulation on top of the graph.
33
- - **[DiaryKG](https://github.com/Flux-Frontiers/diary_kg)** — personal journals and diary corpora; semantic search and graph traversal over a writer's body of work.
34
- - **[FTreeKG](https://github.com/Flux-Frontiers/FTreeKG)** — filesystem trees as a queryable graph of directories, files, and contents.
35
- - **[AgentKG](https://github.com/Flux-Frontiers/agent_kg)** — conversational memory as a knowledge graph: turns, decisions, commitments, preferences, and the relationships between them.
36
-
37
- Together they form **KGRAG**, a federated retrieval layer where one query can span code, documentation, journals, filesystems, agent memory, and domain data simultaneously.
29
+ PyCodeKG is one of ten knowledge graphs sharing the same hybrid
30
+ semantic-plus-structural design — code, prose, journals, filesystems, agent
31
+ memory, metabolic pathways — federated by **[KGRAG](https://github.com/Flux-Frontiers/KGRAG)**
32
+ so a single query can span all of them. The full list is in
33
+ [docs/SISTER_PROJECTS.md](docs/SISTER_PROJECTS.md).
38
34
 
39
35
  ---
40
36
 
@@ -117,7 +113,7 @@ pycodekg init --repo . # download model, build graph, install
117
113
  pycodekg analyze . # the architectural report
118
114
  ```
119
115
 
120
- That's the recommended path. Variants (minimal install, MCP-only, contributor setup) are in [docs/INSTALLATION.md](docs/INSTALLATION.md). Every CLI subcommand is also exposed as a script alias (`pycodekg-analyze`, `pycodekg-build`, `pycodekg-mcp`, …) for use in Makefiles and Poetry projects.
116
+ That's the recommended path. Variants (minimal install, MCP-only, contributor setup) are in [docs/INSTALLATION.md](docs/INSTALLATION.md). Every capability is a subcommand of the single `pycodekg` entry point — `pycodekg analyze`, `pycodekg build`, `pycodekg mcp` — so that one name is all a Makefile or an MCP config needs.
121
117
 
122
118
  ---
123
119
 
@@ -134,6 +130,33 @@ The graph is built around four node kinds (module, class, function, method) and
134
130
 
135
131
  ---
136
132
 
133
+ ## The repo as a tree
134
+
135
+ `pycodekg viz3d --layout organic` grows the graph instead of plotting it. A
136
+ skeleton is grown toward the code by space colonization, so the shape is the
137
+ data rather than decoration:
138
+
139
+ - **The trunk** is the repository; its radius follows the pipe model, so it
140
+ reports how much code the tree carries.
141
+ - **Each limb** is a module. Its *length* is how many definitions the module
142
+ holds — the biggest module reaches furthest — and its *thickness* follows
143
+ from the tips it carries.
144
+ - **Each leaf** is a class, function, or method, tinted by kind.
145
+
146
+ `pycodekg quilt` renders that tree for a [Looking
147
+ Glass](https://lookingglassfactory.com/) light-field display: a multi-view
148
+ quilt the panel fuses into real depth, with `--cast` to send it straight to
149
+ the device. Every render prints its disparity budget first, so you know
150
+ whether the display will fuse the views or ghost them. Details in
151
+ [docs/VIZ3D.md](docs/VIZ3D.md).
152
+
153
+ The growth engine is shared across the KG fleet
154
+ ([kgmodule-utils](https://pypi.org/project/kgmodule-utils/)) and the
155
+ light-field output is [quiltwright](https://pypi.org/project/quiltwright/);
156
+ what lives here is only the mapping from code to wood.
157
+
158
+ ---
159
+
137
160
  ## What you can do with it
138
161
 
139
162
  | If you want to… | Reach for | Detail |
@@ -147,6 +170,8 @@ The graph is built around four node kinds (module, class, function, method) and
147
170
  | **Browse the graph interactively** | `pycodekg viz` (Streamlit) | [docs/INSTALLATION.md](docs/INSTALLATION.md) |
148
171
  | **Share a graph as one file** | `pycodekg viz-export -o graph.html` | opens from `file://`, no server |
149
172
  | **See call graphs in 3-D** *(active development — functional but rough)* | `pycodekg viz3d --layout funnel` | [docs/VIZ3D.md](docs/VIZ3D.md) |
173
+ | **Grow the repo as a tree** | `pycodekg viz3d --layout organic` | modules are limbs, definitions are leaves |
174
+ | **Render it for a Looking Glass display** | `pycodekg quilt --spec 16-landscape` | [docs/VIZ3D.md](docs/VIZ3D.md) |
150
175
  | **Wire it into Claude / Copilot / Cline** | `pycodekg mcp` | [docs/MCP.md](docs/MCP.md) |
151
176
 
152
177
  If you only read one doc after this one, read [docs/Analyze.md](docs/Analyze.md) — that's where most of the day-to-day value lives.
@@ -162,21 +187,20 @@ src/pycode_kg/
162
187
  ├── store.py # SQLite persistence + canonical edges
163
188
  ├── index.py # sqlite-vec semantic index
164
189
  ├── pycodekg.py # Public façade
165
- ├── pycodekg_query.py # Hybrid query
166
- ├── pycodekg_snippet_packer.py # Source-grounded packs
167
190
  ├── pycodekg_thorough_analysis.py # `analyze` engine
168
191
  ├── architecture.py # `architecture` description generator
169
192
  ├── ranking/ # PageRank, bridge centrality, framework nodes
170
193
  ├── snapshots.py # Temporal metric snapshots
171
194
  ├── analysis/ # Coupling, cycles, orphans, hotspots
172
- ├── cli/ # All `pycodekg-*` entry points
195
+ ├── cli/ # `pycodekg` subcommands
173
196
  ├── mcp_server.py # MCP server (nineteen tools)
174
197
  ├── app.py # Streamlit web app
175
198
  ├── viz3d.py / layout3d.py # PyVista/PyQt5 3-D viewer
199
+ ├── scene3d.py # Organic tree: repo → trunk, module → limb
176
200
  └── viz3d_timeline.py # Metric history timeline
177
201
  ```
178
202
 
179
- The MCP server, the CLI, and the Streamlit app are thin wrappers over the same store + index + ranking core — there is exactly one code path for each capability. The latest architectural deep-dive is in [docs/analysis_v0.22.0.md](docs/analysis_v0.22.0.md), produced (of course) by `pycodekg analyze` against this very repo.
203
+ The MCP server, the CLI, and the Streamlit app are thin wrappers over the same store + index + ranking core — there is exactly one code path for each capability. The latest architectural deep-dive is in [docs/analysis_v0.23.0.md](docs/analysis_v0.23.0.md), produced (of course) by `pycodekg analyze` against this very repo.
180
204
 
181
205
  ---
182
206
 
@@ -191,7 +215,8 @@ The MCP server, the CLI, and the Streamlit app are thin wrappers over the same s
191
215
  | [docs/CODERANK.md](docs/CODERANK.md) | SIR PageRank, bridge centrality, framework hubs |
192
216
  | [docs/MCP.md](docs/MCP.md) | MCP server setup for Claude / Kilo / Copilot / Cline, tool reference |
193
217
  | [docs/CHEATSHEET.md](docs/CHEATSHEET.md) | Every CLI flag and every MCP tool — one page |
194
- | [docs/VIZ3D.md](docs/VIZ3D.md) | The 3-D PyVista viewer and layouts |
218
+ | [docs/VIZ3D.md](docs/VIZ3D.md) | The 3-D viewer, the organic tree, and Looking Glass output |
219
+ | [docs/SISTER_PROJECTS.md](docs/SISTER_PROJECTS.md) | The other KGRAG graphs and the shared foundations |
195
220
  | [CHANGELOG.md](CHANGELOG.md) | Release history |
196
221
 
197
222
  ---
@@ -202,13 +227,13 @@ If you use PyCodeKG in your research or project, please cite it:
202
227
 
203
228
  [![DOI](https://zenodo.org/badge/1202379010.svg)](https://zenodo.org/badge/latestdoi/1202379010)
204
229
 
205
- > Suchanek, E. G. (2026). *PyCodeKG: A Knowledge Graph for Python Codebases* (Version 0.22.0) [Software]. Flux-Frontiers. https://doi.org/10.5281/zenodo.19737993
230
+ > Suchanek, E. G. (2026). *PyCodeKG: A Knowledge Graph for Python Codebases* (Version 0.23.0) [Software]. Flux-Frontiers. https://doi.org/10.5281/zenodo.19737993
206
231
 
207
232
  ```bibtex
208
233
  @software{suchanek_pycode_kg,
209
234
  author = {Suchanek, Eric G.},
210
235
  title = {{PyCodeKG}: A Knowledge Graph for Python Codebases},
211
- version = {0.22.0},
236
+ version = {0.23.0},
212
237
  year = {2026},
213
238
  publisher = {Flux-Frontiers},
214
239
  url = {https://github.com/Flux-Frontiers/pycode_kg},
@@ -227,7 +252,7 @@ If you use PyCodeKG in your research or project, please cite it:
227
252
  ## Support & acknowledgments
228
253
 
229
254
  - **Issues** — [GitHub Issues](https://github.com/Flux-Frontiers/pycode_kg/issues)
230
- - Sister projects [DocKG](https://github.com/Flux-Frontiers/doc_kg) and [MetaboKG](https://github.com/Flux-Frontiers/metabo_kg)
255
+ - [Sister projects](docs/SISTER_PROJECTS.md) — the rest of the KGRAG family
231
256
  - sqlite-vec, sentence-transformers, PyVista, Streamlit, and FastMCP for the foundations
232
257
 
233
258
  ---
@@ -1,13 +1,12 @@
1
1
  # pyproject.toml — PyCodeKG package configuration (PEP 621)
2
2
  #
3
3
  # Author: Eric G. Suchanek, PhD
4
- # Last Revision: 2026-08-11
4
+ # Last Revision: 2026-08-15
5
5
  #
6
6
  # Build system : Poetry 2.x with PEP 621 [project] table
7
7
  #
8
8
  # Quick install (pip)
9
9
  # -------------------
10
- # pip install -e ".[dev]" core + dev tools (pytest, ruff, ty, etc.)
11
10
  # pip install -e ".[viz]" core + Streamlit/Plotly/PyVis visualizer
12
11
  # pip install -e ".[viz3d]" core + PyVista 3D visualizer
13
12
  # pip install -e ".[all]" everything above
@@ -15,17 +14,19 @@
15
14
  #
16
15
  # Quick install (poetry)
17
16
  # ----------------------
18
- # poetry install --all-extras everything
19
- # poetry install --extras "dev" core + dev tools only
17
+ # poetry install --with dev --all-extras everything
18
+ # poetry install --with dev core + dev tools (pytest, ruff, ty, etc.)
20
19
  # poetry install --extras "viz" core + Streamlit/Plotly visualizer only
21
20
  # poetry install --extras "viz3d" core + 3D visualizer only
22
21
  # poetry install core runtime only
23
22
  #
23
+ # Dev tooling lives in the Poetry `dev` group, not an extra, so it stays out
24
+ # of published wheel metadata. pip-only setups can't install it — use poetry
25
+ # for development.
26
+ #
24
27
  # First-time setup
25
28
  # ----------------
26
- # python -m venv .venv
27
- # source .venv/bin/activate # Windows: .venv\Scripts\activate
28
- # pip install -e ".[dev]"
29
+ # poetry install --with dev
29
30
  #
30
31
  # Run tests
31
32
  # ---------
@@ -70,7 +71,7 @@ torch = [
70
71
  # ---------------------------------------------------------------------------
71
72
  [project]
72
73
  name = "pycode-kg"
73
- version = "0.22.0"
74
+ version = "0.23.0"
74
75
  description = "A tool to build a searchable knowledge graph from Python repositories"
75
76
  readme = "README.md"
76
77
  license = "Elastic-2.0"
@@ -102,6 +103,16 @@ dependencies = [
102
103
  "pandas>=2.0.0",
103
104
  "rich>=14.3.3,<15",
104
105
  "sentence-transformers>=5.4.1",
106
+ # Upper-bounded to keep resolution single-valued across extras: mcp and
107
+ # sse-starlette float to any 1.x, but streamlit (viz extra) caps starlette
108
+ # at <1.4.0. Without this ceiling a bare install resolves 1.6.0 while
109
+ # --extras viz resolves 1.3.1, poetry locks BOTH with no distinguishing
110
+ # markers, and an install can unpack the two wheels over the same
111
+ # starlette/ directory — splicing applications.py into a file matching
112
+ # neither RECORD hash and surfacing as a SyntaxError importing
113
+ # mcp.server.fastmcp. 1.3.1 is also the only version pycodekg-mcp is
114
+ # tested against. Floor matches sse-starlette's own requirement.
115
+ "starlette>=0.49.1,<1.4.0",
105
116
  # Core, not optional: kg.py hard-codes vector_backend="sqlite-vec", so every
106
117
  # build/query path goes through kg_utils.vector_backend.SqliteVecBackend,
107
118
  # which imports sqlite_vec at connect time. Exact pin — sqlite-vec is pre-1.0
@@ -126,19 +137,10 @@ dependencies = [
126
137
  # Its only dependency is numpy, which `[semantic]` already pulls, so it adds
127
138
  # nothing to the install — it just declares what layout3d actually imports.
128
139
  # Unlike `[viz]`, there is no pyvis to leak into a bare install.
129
- "kgmodule-utils[semantic,viz3d]>=0.11.0",
140
+ "kgmodule-utils[semantic,viz3d]>=0.12.1",
130
141
  ]
131
142
 
132
143
  [project.optional-dependencies]
133
- dev = [
134
- "detect-secrets>=1.5.0",
135
- "ty>=0.0.41",
136
- "pdoc>=14.0.0",
137
- "pre-commit>=4.5.1",
138
- "pytest>=8.0.0",
139
- "pytest-cov>=5.0.0",
140
- "ruff>=0.4.0",
141
- ]
142
144
  viz = [
143
145
  "plotly>=5.14.0",
144
146
  "pyvis>=0.3.2",
@@ -148,9 +150,16 @@ viz3d = [
148
150
  "markdown>=3.6",
149
151
  "param>=2.0.0",
150
152
  "PyQt5>=5.15.0",
151
- "pyvista>=0.44.0",
153
+ # pyvista comes from the SDK, which is what needs it: tree_mesh, leaf_glyphs
154
+ # and smooth_paths live there. The main dependency above stays on plain
155
+ # [viz3d] (numpy only) so the nine repos that take pycode-kg do not acquire
156
+ # VTK for a layout import; rendering stays opt-in, here.
157
+ "kgmodule-utils[viz3d-render]>=0.12.1",
152
158
  "pyvistaqt>=0.11.0",
153
159
  "trame-vtk>=2.0.0",
160
+ # Looking Glass quilts. 0.4.0 supplies depth_report() and widened
161
+ # requires-python to <3.14, which retires the old marker gate.
162
+ "quiltwright>=0.4.0",
154
163
  ]
155
164
 
156
165
  # Cross-KG sibling packages (doc-kg, pycode-kg, agent-kg, kg-rag) are NOT
@@ -160,25 +169,44 @@ viz3d = [
160
169
  # doc-kg and pycode-kg each depend on the other. Install them by hand:
161
170
  # pip install doc-kg pycode-kg # both on PyPI
162
171
  # pip install agent-kg kg-rag # both on PyPI as of 2026-07-29
172
+ # Union of the user-facing extras: keep this the exact sum of `viz` + `viz3d`
173
+ # above, edited in the same commit as either. Two poetry resolver limits force
174
+ # the hand-copy shape: a self-referential "pycode-kg[viz,viz3d]" is rejected
175
+ # ("listed as a dependency of itself"), and repeating kgmodule-utils[viz3d-render]
176
+ # here collides with the viz3d entry ("<empty>" constraint), so bare pyvista
177
+ # stands in for it — pyvista>=0.44.0 is that extra's entire payload.
178
+ # Dev tooling is deliberately absent: it lives in the Poetry dev group below.
163
179
  all = [
164
- "detect-secrets>=1.5.0",
165
180
  "markdown>=3.6",
166
181
  "param>=2.0.0",
167
- "pdoc>=14.0.0",
168
182
  "plotly>=5.14.0",
169
- "pre-commit>=4.5.1",
170
183
  "PyQt5>=5.15.0",
171
- "pytest>=8.0.0",
172
- "pytest-cov>=5.0.0",
184
+ "pyvis>=0.3.2",
173
185
  "pyvista>=0.44.0",
174
186
  "pyvistaqt>=0.11.0",
175
- "pyvis>=0.3.2",
176
- "ruff>=0.4.0",
187
+ "quiltwright>=0.4.0",
177
188
  "streamlit>=1.56.0",
178
189
  "trame-vtk>=2.0.0",
179
- "ty>=0.0.41",
180
190
  ]
181
191
 
192
+ # Dev tooling. A group rather than an extra so pytest/ruff/ty/pre-commit stay
193
+ # out of the published wheel metadata — `pip install pycode-kg[dev]` was never
194
+ # meant to be a thing consumers do. Optional to preserve the contract that a
195
+ # bare `poetry install` is core runtime only (same shape as `kg` below).
196
+ #
197
+ # poetry install --with dev
198
+ [tool.poetry.group.dev]
199
+ optional = true
200
+
201
+ [tool.poetry.group.dev.dependencies]
202
+ detect-secrets = ">=1.5.0"
203
+ pdoc = ">=14.0.0"
204
+ pre-commit = ">=4.5.1"
205
+ pytest = ">=9.0.3"
206
+ pytest-cov = ">=5.0.0"
207
+ ruff = ">=0.4.0,<0.16"
208
+ ty = ">=0.0.41"
209
+
182
210
  # Maintainer tooling, not a dependency of this package. `.mcp.json` serves a
183
211
  # `dockg` MCP server from `.venv/bin/dockg`, so the CLI has to be in this repo's
184
212
  # environment — but nothing under src/ imports doc_kg, and declaring it as a real
@@ -198,30 +226,19 @@ all = [
198
226
  optional = true
199
227
 
200
228
  [tool.poetry.group.kg.dependencies]
201
- doc-kg = ">=0.21.1"
229
+ doc-kg = ">=0.21.2"
202
230
 
203
231
  [project.urls]
204
232
  Homepage = "https://github.com/Flux-Frontiers/pycode_kg"
205
233
  Repository = "https://github.com/Flux-Frontiers/pycode_kg"
206
234
 
207
235
  [project.scripts]
208
- pycodekg = "pycode_kg.cli.main:cli"
209
- pycodekg-analyze = "pycode_kg.cli.cmd_analyze:analyze"
210
- pycodekg-architecture = "pycode_kg.cli.cmd_architecture:architecture"
211
- pycodekg-build = "pycode_kg.cli.cmd_build_full:build"
212
- pycodekg-build-index = "pycode_kg.cli.cmd_build:build_index"
213
- pycodekg-build-sqlite = "pycode_kg.cli.cmd_build:build_sqlite"
214
- pycodekg-centrality = "pycode_kg.cli.cmd_centrality:cmd_centrality"
215
- pycodekg-download-model = "pycode_kg.cli.cmd_model:download_model"
216
- pycodekg-init = "pycode_kg.cli.cmd_init:init"
217
- pycodekg-install-hooks = "pycode_kg.cli.cmd_hooks:install_hooks"
218
- pycodekg-mcp = "pycode_kg.mcp_server:main"
219
- pycodekg-pack = "pycode_kg.cli.cmd_query:pack"
220
- pycodekg-query = "pycode_kg.cli.cmd_query:query"
221
- pycodekg-update = "pycode_kg.cli.cmd_build_full:update"
222
- pycodekg-viz = "pycode_kg.cli.cmd_viz:viz"
223
- pycodekg-viz-timeline = "pycode_kg.cli.cmd_viz:viz_timeline"
224
- pycodekg-viz3d = "pycode_kg.cli.cmd_viz:viz3d"
236
+ # The convenience aliases (`pycodekg-analyze`, `pycodekg-build`, ...) went in
237
+ # 0.23.0: nothing invoked them. `pycodekg-mcp` stays -- the documented Claude
238
+ # Desktop and Copilot configs put that path in users' config files, so dropping
239
+ # it would break their MCP server on upgrade.
240
+ pycodekg = "pycode_kg.cli.main:cli"
241
+ pycodekg-mcp = "pycode_kg.mcp_server:main"
225
242
 
226
243
  # ---------------------------------------------------------------------------
227
244
  # Tool configuration
@@ -30,9 +30,13 @@ Low-level primitives (v0 contract, locked)::
30
30
  KGModule SDK (build new domain KGs)::
31
31
 
32
32
  from pycode_kg import KGModule, KGExtractor, PyCodeKGExtractor, NodeSpec, EdgeSpec
33
+
34
+ Author: Eric G. Suchanek, PhD
35
+
36
+ License: Elastic 2.0
33
37
  """
34
38
 
35
- __version__ = "0.22.0"
39
+ __version__ = "0.23.0"
36
40
  __author__ = "Eric G. Suchanek, PhD"
37
41
 
38
42
  # Low-level primitives (locked v0 contract)
@@ -3,6 +3,10 @@
3
3
  Dispatcher for python -m pycode_kg <command> [args...]
4
4
 
5
5
  Routes to Click group-based CLI.
6
+
7
+ Author: Eric G. Suchanek, PhD
8
+
9
+ License: Elastic 2.0
6
10
  """
7
11
 
8
12
  from pycode_kg.cli.main import cli
@@ -1,4 +1,9 @@
1
- """Analysis primitives for PyCodeKG."""
1
+ """Analysis primitives for PyCodeKG.
2
+
3
+ Author: Eric G. Suchanek, PhD
4
+
5
+ License: Elastic 2.0
6
+ """
2
7
 
3
8
  from kg_utils.analysis.scores import MetricRef, ScoreSet, available_metrics, load_scores
4
9
 
@@ -4,7 +4,7 @@ Measures module interaction complexity: how many unique modules each module call
4
4
  For well-modularized codebases, identifies orchestrator and hub modules.
5
5
 
6
6
  Author: Eric G. Suchanek, PhD
7
- Last Revision: 2026-08-03 11:37:06
7
+ Last Revision: 2026-08-14 20:59:39
8
8
  License: Elastic 2.0
9
9
  """
10
10
 
@@ -12,7 +12,9 @@ Public API:
12
12
  - :func:`aggregate_module_scores` — roll node scores up to module level.
13
13
 
14
14
  Author: Eric G. Suchanek, PhD
15
- Last Revision: 2026-08-03 11:37:06
15
+ Last Revision: 2026-08-14 22:45:27
16
+
17
+ License: Elastic 2.0
16
18
  """
17
19
 
18
20
  from __future__ import annotations
@@ -3,7 +3,7 @@ Framework Detector for PyCodeKG.
3
3
  Identifies repo-defining abstractions using centrality and cross-module signals.
4
4
 
5
5
  Author: Eric G. Suchanek, PhD
6
- Last Revision: 2026-08-03 11:37:06
6
+ Last Revision: 2026-08-14 20:59:39
7
7
  License: Elastic 2.0
8
8
  """
9
9
 
@@ -10,6 +10,10 @@ Interactive knowledge-graph explorer with:
10
10
 
11
11
  Run with:
12
12
  poetry run pycodekg-viz
13
+
14
+ Author: Eric G. Suchanek, PhD
15
+
16
+ License: Elastic 2.0
13
17
  """
14
18
 
15
19
  from __future__ import annotations