codebeacon 0.3.2__tar.gz → 0.3.3__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 (120) hide show
  1. {codebeacon-0.3.2 → codebeacon-0.3.3}/PKG-INFO +14 -1
  2. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.de.md +2 -0
  3. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.es.md +2 -0
  4. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.fr.md +2 -0
  5. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.ja.md +2 -0
  6. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.ko.md +13 -0
  7. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.md +13 -0
  8. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.pt-BR.md +2 -0
  9. {codebeacon-0.3.2 → codebeacon-0.3.3}/README.zh-CN.md +2 -0
  10. codebeacon-0.3.3/codebeacon/__init__.py +1 -0
  11. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/cli.py +65 -0
  12. {codebeacon-0.3.2 → codebeacon-0.3.3/codebeacon}/skill/SKILL.md +1 -0
  13. {codebeacon-0.3.2 → codebeacon-0.3.3}/pyproject.toml +1 -1
  14. {codebeacon-0.3.2 → codebeacon-0.3.3}/skill/install.py +1 -1
  15. codebeacon-0.3.2/codebeacon/__init__.py +0 -1
  16. codebeacon-0.3.2/codebeacon/skill/SKILL.md +0 -129
  17. {codebeacon-0.3.2 → codebeacon-0.3.3}/.cursorrules +0 -0
  18. {codebeacon-0.3.2 → codebeacon-0.3.3}/.github/CODEOWNERS +0 -0
  19. {codebeacon-0.3.2 → codebeacon-0.3.3}/.github/dependabot.yml +0 -0
  20. {codebeacon-0.3.2 → codebeacon-0.3.3}/.github/workflows/ci.yml +0 -0
  21. {codebeacon-0.3.2 → codebeacon-0.3.3}/.github/workflows/release.yml +0 -0
  22. {codebeacon-0.3.2 → codebeacon-0.3.3}/.gitignore +0 -0
  23. {codebeacon-0.3.2 → codebeacon-0.3.3}/AGENTS.md +0 -0
  24. {codebeacon-0.3.2 → codebeacon-0.3.3}/CLAUDE.md +0 -0
  25. {codebeacon-0.3.2 → codebeacon-0.3.3}/LICENSE +0 -0
  26. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/__main__.py +0 -0
  27. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/cache.py +0 -0
  28. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/common/__init__.py +0 -0
  29. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/common/filters.py +0 -0
  30. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/common/safety.py +0 -0
  31. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/common/symbols.py +0 -0
  32. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/common/types.py +0 -0
  33. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/config.py +0 -0
  34. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/contextmap/__init__.py +0 -0
  35. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/contextmap/generator.py +0 -0
  36. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/discover/__init__.py +0 -0
  37. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/discover/detector.py +0 -0
  38. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/discover/ignore.py +0 -0
  39. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/discover/scanner.py +0 -0
  40. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/export/__init__.py +0 -0
  41. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/export/callflow_html.py +0 -0
  42. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/export/hooks.py +0 -0
  43. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/export/mcp.py +0 -0
  44. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/export/merge.py +0 -0
  45. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/export/obsidian.py +0 -0
  46. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/export/tree_html.py +0 -0
  47. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/__init__.py +0 -0
  48. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/base.py +0 -0
  49. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/components.py +0 -0
  50. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/dependencies.py +0 -0
  51. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/entities.py +0 -0
  52. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/README.md +0 -0
  53. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/actix.scm +0 -0
  54. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/angular.scm +0 -0
  55. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/aspnet.scm +0 -0
  56. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/django.scm +0 -0
  57. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/express.scm +0 -0
  58. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/fastapi.scm +0 -0
  59. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/flask.scm +0 -0
  60. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/gin.scm +0 -0
  61. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/ktor.scm +0 -0
  62. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/laravel.scm +0 -0
  63. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/nestjs.scm +0 -0
  64. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/rails.scm +0 -0
  65. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/react.scm +0 -0
  66. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/spring_boot.scm +0 -0
  67. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/svelte.scm +0 -0
  68. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/tauri.scm +0 -0
  69. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/vapor.scm +0 -0
  70. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/queries/vue.scm +0 -0
  71. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/routes.py +0 -0
  72. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/semantic.py +0 -0
  73. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/extract/services.py +0 -0
  74. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/graph/__init__.py +0 -0
  75. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/graph/analyze.py +0 -0
  76. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/graph/build.py +0 -0
  77. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/graph/cluster.py +0 -0
  78. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/graph/enrich.py +0 -0
  79. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/graph/write.py +0 -0
  80. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/plugins/__init__.py +0 -0
  81. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/plugins/githooks.py +0 -0
  82. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/plugins/skills.py +0 -0
  83. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/semantic_pipeline.py +0 -0
  84. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/wave.py +0 -0
  85. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/wiki/__init__.py +0 -0
  86. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/wiki/generator.py +0 -0
  87. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/wiki/index.py +0 -0
  88. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon/wiki/templates.py +0 -0
  89. {codebeacon-0.3.2 → codebeacon-0.3.3}/codebeacon.yaml.example +0 -0
  90. {codebeacon-0.3.2 → codebeacon-0.3.3}/docs/TRANSLATION_STATUS.md +0 -0
  91. {codebeacon-0.3.2 → codebeacon-0.3.3}/public-plan.md +0 -0
  92. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/__init__.py +0 -0
  93. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/conftest.py +0 -0
  94. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/actix/main.rs +0 -0
  95. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/angular/app.component.ts +0 -0
  96. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/aspnet/UserController.cs +0 -0
  97. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/django/views.py +0 -0
  98. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/express/userRouter.js +0 -0
  99. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/fastapi/main.py +0 -0
  100. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/flask/app.py +0 -0
  101. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/gin/main.go +0 -0
  102. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/ktor/UserRoutes.kt +0 -0
  103. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/laravel/UserController.php +0 -0
  104. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/nestjs/user.controller.ts +0 -0
  105. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/rails/users_controller.rb +0 -0
  106. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/react/UserPage.tsx +0 -0
  107. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/spring_boot/UserController.java +0 -0
  108. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/sveltekit/+page.svelte +0 -0
  109. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/vapor/routes.swift +0 -0
  110. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/fixtures/vue/UserList.vue +0 -0
  111. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_discover.py +0 -0
  112. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_entities.py +0 -0
  113. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_filters.py +0 -0
  114. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_graph.py +0 -0
  115. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_plugins.py +0 -0
  116. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_resolve.py +0 -0
  117. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_routes.py +0 -0
  118. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_safety_and_writes.py +0 -0
  119. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_services.py +0 -0
  120. {codebeacon-0.3.2 → codebeacon-0.3.3}/tests/test_wiki.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: codebeacon
3
- Version: 0.3.2
3
+ Version: 0.3.3
4
4
  Summary: Source code AST analysis tool for AI context generation — unified multi-framework knowledge graph
5
5
  Project-URL: Homepage, https://github.com/codebeacon/codebeacon
6
6
  Project-URL: Repository, https://github.com/codebeacon/codebeacon
@@ -259,10 +259,21 @@ This copies `SKILL.md` to `~/.claude/skills/codebeacon/` and registers the `/cod
259
259
  /codebeacon serve <path> # start MCP server pointing at .codebeacon/
260
260
  /codebeacon query <term> # search the graph
261
261
  /codebeacon path <src> <tgt> # shortest path
262
+ /codebeacon upgrade # pip upgrade + refresh this skill (then restart Claude Code)
262
263
  ```
263
264
 
264
265
  By default `scan` and `sync` invocations automatically run the **AI-semantic** pipeline at the end (see the [AI-Semantic Enrichment](#ai-semantic-enrichment-via-the-codebeacon-skill) section). The agent uses whatever model your Claude Code session is currently running on — Opus, Sonnet, Haiku — codebeacon never hardcodes a model and never needs an API key.
265
266
 
267
+ ### Updating to a new version
268
+
269
+ Run **one** command from anywhere:
270
+
271
+ ```bash
272
+ codebeacon upgrade
273
+ ```
274
+
275
+ This pip-upgrades the package, then re-runs `codebeacon install` so `~/.claude/skills/codebeacon/SKILL.md` is overwritten with the new release's copy. Restart your Claude Code session for the new SKILL.md to load. If codebeacon is installed in editable mode (`pip install -e .`), the pip step is skipped — pass `--force` to upgrade anyway.
276
+
266
277
  ### MCP Server
267
278
 
268
279
  Run codebeacon as a persistent MCP server so any MCP-compatible client can query your knowledge graph directly.
@@ -365,6 +376,8 @@ codebeacon merge-driver <base> <cur> <other> # invoked by git after `hook insta
365
376
  # Integrations
366
377
  codebeacon serve [--dir .codebeacon] # start MCP server (stdio)
367
378
  codebeacon install # install Claude Code skill
379
+ codebeacon upgrade # pip install --upgrade + refresh ~/.claude/skills/codebeacon/SKILL.md
380
+ # (`--force` to upgrade even when installed in editable mode)
368
381
  ```
369
382
 
370
383
  ---
@@ -391,6 +391,8 @@ codebeacon semantic-apply [--dir .codebeacon]
391
391
 
392
392
  codebeacon serve [--dir .codebeacon] # MCP-Server starten (stdio)
393
393
  codebeacon install # Claude-Code-Skill installieren
394
+ codebeacon upgrade # pip-Upgrade + ~/.claude/skills/codebeacon/SKILL.md aktualisieren
395
+ # (`--force` falls editable-Installation)
394
396
  ```
395
397
 
396
398
  ---
@@ -389,6 +389,8 @@ codebeacon semantic-apply [--dir .codebeacon]
389
389
 
390
390
  codebeacon serve [--dir .codebeacon] # servidor MCP (stdio)
391
391
  codebeacon install # instalar skill de Claude Code
392
+ codebeacon upgrade # pip upgrade + refrescar ~/.claude/skills/codebeacon/SKILL.md
393
+ # (use `--force` si está instalado en modo editable)
392
394
  ```
393
395
 
394
396
  ---
@@ -390,6 +390,8 @@ codebeacon semantic-apply [--dir .codebeacon]
390
390
 
391
391
  codebeacon serve [--dir .codebeacon] # serveur MCP (stdio)
392
392
  codebeacon install # installer le skill Claude Code
393
+ codebeacon upgrade # pip upgrade + rafraîchir ~/.claude/skills/codebeacon/SKILL.md
394
+ # (`--force` si installé en mode éditable)
393
395
  ```
394
396
 
395
397
  ---
@@ -300,6 +300,8 @@ codebeacon semantic-apply [--dir .codebeacon]
300
300
  # インテグレーション
301
301
  codebeacon serve [--dir .codebeacon] # MCP サーバー起動 (stdio)
302
302
  codebeacon install # Claude Code スキルをインストール
303
+ codebeacon upgrade # pip で更新 + ~/.claude/skills/codebeacon/SKILL.md を再生成
304
+ # (`--force` で editable インストール時も強制実行)
303
305
  ```
304
306
 
305
307
  ---
@@ -217,10 +217,21 @@ codebeacon install
217
217
  /codebeacon serve <path> # .codebeacon/ 을 가리키는 MCP 서버 시작
218
218
  /codebeacon query <term> # 그래프 검색
219
219
  /codebeacon path <src> <tgt> # 최단 경로
220
+ /codebeacon upgrade # pip 업그레이드 + 이 스킬 SKILL.md 갱신 (이후 Claude Code 재시작)
220
221
  ```
221
222
 
222
223
  기본적으로 `scan` 과 `sync` 호출은 마지막에 **AI-시맨틱** 파이프라인을 자동 실행합니다 ([AI-시맨틱 보강](#ai-시맨틱-보강-codebeacon-스킬에서-자동) 섹션 참고). 에이전트는 Claude Code 세션이 **현재 실행 중인 모델**을 그대로 사용 — Opus, Sonnet, Haiku — codebeacon 은 절대 모델을 하드코딩하지 않고 API 키도 필요 없습니다.
223
224
 
225
+ ### 새 버전으로 업그레이드
226
+
227
+ 어디서든 한 줄:
228
+
229
+ ```bash
230
+ codebeacon upgrade
231
+ ```
232
+
233
+ 이 명령은 pip 으로 패키지를 업그레이드한 뒤 `codebeacon install` 을 다시 실행해 `~/.claude/skills/codebeacon/SKILL.md` 을 새 릴리스의 사본으로 덮어씁니다. 새 SKILL.md 가 로드되려면 Claude Code 세션을 재시작하세요. editable 모드 (`pip install -e .`) 로 설치되어 있다면 pip 단계는 스킵됩니다 — 강제로 진행하려면 `--force` 를 붙이세요.
234
+
224
235
  ### MCP 서버
225
236
 
226
237
  codebeacon을 MCP 서버로 실행하면 MCP 호환 클라이언트에서 지식 그래프를 직접 조회할 수 있습니다.
@@ -324,6 +335,8 @@ codebeacon merge-driver <base> <cur> <other> # `hook install` 후 git이 자동
324
335
  # 통합
325
336
  codebeacon serve [--dir .codebeacon] # MCP 서버 시작 (stdio)
326
337
  codebeacon install # Claude Code 스킬 설치
338
+ codebeacon upgrade # pip 으로 업그레이드 + ~/.claude/skills/codebeacon/SKILL.md 갱신
339
+ # (`--force` 로 editable 설치 환경에서도 강제 업그레이드)
327
340
  ```
328
341
 
329
342
  ---
@@ -216,10 +216,21 @@ This copies `SKILL.md` to `~/.claude/skills/codebeacon/` and registers the `/cod
216
216
  /codebeacon serve <path> # start MCP server pointing at .codebeacon/
217
217
  /codebeacon query <term> # search the graph
218
218
  /codebeacon path <src> <tgt> # shortest path
219
+ /codebeacon upgrade # pip upgrade + refresh this skill (then restart Claude Code)
219
220
  ```
220
221
 
221
222
  By default `scan` and `sync` invocations automatically run the **AI-semantic** pipeline at the end (see the [AI-Semantic Enrichment](#ai-semantic-enrichment-via-the-codebeacon-skill) section). The agent uses whatever model your Claude Code session is currently running on — Opus, Sonnet, Haiku — codebeacon never hardcodes a model and never needs an API key.
222
223
 
224
+ ### Updating to a new version
225
+
226
+ Run **one** command from anywhere:
227
+
228
+ ```bash
229
+ codebeacon upgrade
230
+ ```
231
+
232
+ This pip-upgrades the package, then re-runs `codebeacon install` so `~/.claude/skills/codebeacon/SKILL.md` is overwritten with the new release's copy. Restart your Claude Code session for the new SKILL.md to load. If codebeacon is installed in editable mode (`pip install -e .`), the pip step is skipped — pass `--force` to upgrade anyway.
233
+
223
234
  ### MCP Server
224
235
 
225
236
  Run codebeacon as a persistent MCP server so any MCP-compatible client can query your knowledge graph directly.
@@ -322,6 +333,8 @@ codebeacon merge-driver <base> <cur> <other> # invoked by git after `hook insta
322
333
  # Integrations
323
334
  codebeacon serve [--dir .codebeacon] # start MCP server (stdio)
324
335
  codebeacon install # install Claude Code skill
336
+ codebeacon upgrade # pip install --upgrade + refresh ~/.claude/skills/codebeacon/SKILL.md
337
+ # (`--force` to upgrade even when installed in editable mode)
325
338
  ```
326
339
 
327
340
  ---
@@ -389,6 +389,8 @@ codebeacon semantic-apply [--dir .codebeacon]
389
389
 
390
390
  codebeacon serve [--dir .codebeacon] # servidor MCP (stdio)
391
391
  codebeacon install # instalar skill do Claude Code
392
+ codebeacon upgrade # pip upgrade + atualizar ~/.claude/skills/codebeacon/SKILL.md
393
+ # (use `--force` se instalado em modo editable)
392
394
  ```
393
395
 
394
396
  ---
@@ -299,6 +299,8 @@ codebeacon semantic-apply [--dir .codebeacon]
299
299
  # 集成
300
300
  codebeacon serve [--dir .codebeacon] # 启动 MCP 服务器(stdio)
301
301
  codebeacon install # 安装 Claude Code 技能
302
+ codebeacon upgrade # pip 升级 + 刷新 ~/.claude/skills/codebeacon/SKILL.md
303
+ # (editable 安装下用 `--force` 强制升级)
302
304
  ```
303
305
 
304
306
  ---
@@ -0,0 +1 @@
1
+ __version__ = "0.3.3"
@@ -758,6 +758,60 @@ def _cmd_install(args: argparse.Namespace) -> int:
758
758
  return 0
759
759
 
760
760
 
761
+ def _cmd_upgrade(args: argparse.Namespace) -> int:
762
+ """``codebeacon upgrade`` — pip upgrade the package + refresh SKILL.md.
763
+
764
+ Runs `pip install --upgrade codebeacon` in the current interpreter, then
765
+ reinvokes `codebeacon install` so ~/.claude/skills/codebeacon/SKILL.md is
766
+ refreshed to whatever shipped in the new release. Editable installs are
767
+ detected and skipped (pip upgrade would be a no-op anyway).
768
+ """
769
+ import subprocess
770
+ import sys as _sys
771
+ from codebeacon import __version__ as _current
772
+
773
+ print(f"Current version: codebeacon {_current}", flush=True)
774
+
775
+ is_editable = False
776
+ try:
777
+ from importlib.metadata import Distribution
778
+ dist = Distribution.from_name("codebeacon")
779
+ direct_url = dist.read_text("direct_url.json") or ""
780
+ if "\"editable\": true" in direct_url:
781
+ is_editable = True
782
+ except Exception:
783
+ pass
784
+
785
+ if is_editable and not getattr(args, "force", False):
786
+ print(
787
+ "Detected an editable (pip install -e .) install — skipping pip upgrade.\n"
788
+ "Use `git pull` to get new code, or pass --force to upgrade anyway.",
789
+ file=_sys.stderr,
790
+ )
791
+ else:
792
+ cmd = [_sys.executable, "-m", "pip", "install", "--upgrade", "codebeacon"]
793
+ print(f"$ {' '.join(cmd)}")
794
+ rc = subprocess.call(cmd)
795
+ if rc != 0:
796
+ print("pip upgrade failed.", file=_sys.stderr)
797
+ return rc
798
+
799
+ # Refresh SKILL.md by reinvoking the install command. We exec it in a
800
+ # subprocess so the freshly-installed entry point is used (the current
801
+ # process is still running the OLD code from before pip upgrade).
802
+ print("\nRefreshing /codebeacon Claude Code skill ...", flush=True)
803
+ rc = subprocess.call([_sys.executable, "-m", "codebeacon", "install"])
804
+ if rc != 0:
805
+ return rc
806
+
807
+ print(
808
+ "\nUpgrade complete. Restart your Claude Code session so the new "
809
+ "SKILL.md is loaded.",
810
+ flush=True,
811
+ )
812
+ return 0
813
+
814
+
761
815
  def _cmd_semantic_prepare(args: argparse.Namespace) -> int:
762
816
  from codebeacon.semantic_pipeline import prepare
763
817
 
@@ -874,6 +928,17 @@ def build_parser() -> argparse.ArgumentParser:
874
928
  install_p = sub.add_parser("install", help="Install Claude Code skill")
875
929
  install_p.set_defaults(func=_cmd_install)
876
930
 
931
+ # upgrade (pip upgrade + refresh skill)
932
+ upgrade_p = sub.add_parser(
933
+ "upgrade",
934
+ help="Upgrade codebeacon via pip and refresh ~/.claude/skills/codebeacon/SKILL.md",
935
+ )
936
+ upgrade_p.add_argument(
937
+ "--force", action="store_true",
938
+ help="Upgrade even when codebeacon is installed in editable (-e) mode",
939
+ )
940
+ upgrade_p.set_defaults(func=_cmd_upgrade)
941
+
877
942
  # semantic-prepare
878
943
  sem_prep = sub.add_parser(
879
944
  "semantic-prepare",
@@ -24,6 +24,7 @@ Scan source code with AST analysis → build a knowledge graph → generate a na
24
24
  /codebeacon path <src> <tgt> # shortest path
25
25
  /codebeacon init [<path>] # interactive codebeacon.yaml
26
26
  /codebeacon install # install/update this skill
27
+ /codebeacon upgrade # pip upgrade codebeacon + refresh this SKILL.md (then restart Claude Code)
27
28
  ```
28
29
 
29
30
  If no path was given, use `.` (current directory). Do not ask the user for a path.
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "codebeacon"
7
- version = "0.3.2"
7
+ version = "0.3.3"
8
8
  description = "Source code AST analysis tool for AI context generation — unified multi-framework knowledge graph"
9
9
  readme = "README.md"
10
10
  license = { text = "MIT" }
@@ -17,7 +17,7 @@ import sys
17
17
  from pathlib import Path
18
18
 
19
19
 
20
- SKILL_SRC = Path(__file__).parent / "SKILL.md"
20
+ SKILL_SRC = Path(__file__).parent.parent / "codebeacon" / "skill" / "SKILL.md"
21
21
 
22
22
  CLAUDE_TRIGGER_BLOCK = """\
23
23
  # codebeacon
@@ -1 +0,0 @@
1
- __version__ = "0.3.2"
@@ -1,129 +0,0 @@
1
- ---
2
- name: codebeacon
3
- description: Scan a codebase → AST extraction → knowledge graph → wiki + CLAUDE.md context map. Supports 27 frameworks (Spring Boot, NestJS, Django, FastAPI, Flask, Rails, Express, Fastify, Koa, React, Next.js, Vue, Nuxt, Angular, SvelteKit, Gin, Echo, Fiber, Laravel, Actix-Web, Axum, Tauri, Rocket, Warp, ASP.NET Core, Vapor, Ktor).
4
- trigger: /codebeacon
5
- ---
6
-
7
- # /codebeacon
8
-
9
- Scan source code with AST analysis → build a knowledge graph → generate a navigable wiki + `CLAUDE.md` context map ready for AI agents.
10
-
11
- ## Usage
12
-
13
- ```
14
- /codebeacon # scan current directory
15
- /codebeacon <path> # scan specific path or workspace root
16
- /codebeacon <path> --update # incremental: only reprocess changed files
17
- /codebeacon <path> --wiki-only # regenerate wiki without re-extracting
18
- /codebeacon <path> --deep-dive # per-project outputs + combined workspace
19
- /codebeacon sync # sync from codebeacon.yaml (multi-project)
20
- /codebeacon serve <path> # start MCP server pointing at .codebeacon/
21
- ```
22
-
23
- ## What You Must Do When Invoked
24
-
25
- If no path was given, use `.` (current directory). Do not ask the user for a path.
26
-
27
- Follow these steps in order.
28
-
29
- ### Step 1 — Ensure codebeacon is installed
30
-
31
- ```bash
32
- python3 -c "import codebeacon" 2>/dev/null || pip install codebeacon -q --break-system-packages 2>&1 | tail -5
33
- python3 -c "import sys; open('.codebeacon_python', 'w').write(sys.executable)"
34
- ```
35
-
36
- In every subsequent bash block, replace `python3` with `$(cat .codebeacon_python)`.
37
-
38
- If import succeeds, print nothing and move to Step 2.
39
-
40
- ### Step 2 — Detect mode and run
41
-
42
- Check if `codebeacon.yaml` exists in the target directory:
43
-
44
- ```bash
45
- TARGET="${1:-.}"
46
-
47
- if [ -f "$TARGET/codebeacon.yaml" ]; then
48
- echo "Found codebeacon.yaml — running sync mode"
49
- $(cat .codebeacon_python) -m codebeacon sync --config "$TARGET/codebeacon.yaml"
50
- else
51
- echo "Scanning $TARGET ..."
52
- $(cat .codebeacon_python) -m codebeacon scan "$TARGET"
53
- fi
54
- ```
55
-
56
- The command prints wave progress as it goes:
57
- - Framework detection per project
58
- - `[pct%] done/total files processed` (wave progress per project)
59
- - Route / Service / Entity / Component counts after each project
60
- - Final: `Nodes: N, Edges: E, Communities: K`
61
-
62
- Let it run to completion. Do not interrupt.
63
-
64
- ### Step 3 — Report results
65
-
66
- After the command exits, read the REPORT.md:
67
-
68
- ```bash
69
- TARGET="${1:-.}"
70
- OUTPUT_DIR="$TARGET/.codebeacon"
71
- [ -f "$OUTPUT_DIR/REPORT.md" ] && head -40 "$OUTPUT_DIR/REPORT.md"
72
- ```
73
-
74
- Then summarise for the user:
75
- - Which projects/frameworks were detected
76
- - Total nodes, edges, communities
77
- - Output location (`CLAUDE.md` at project root, `.codebeacon/wiki/`, `.codebeacon/beacon.json`, etc.)
78
- - Any god nodes or surprising connections worth mentioning
79
-
80
- ### Step 4 — (Optional) MCP serve
81
-
82
- If the user asked for `serve`:
83
-
84
- ```bash
85
- TARGET="${1:-.}"
86
- $(cat .codebeacon_python) -m codebeacon serve --dir "$TARGET/.codebeacon"
87
- ```
88
-
89
- This blocks — run it only when the user explicitly wants an MCP server.
90
-
91
- ## Output structure
92
-
93
- ```
94
- project-root/
95
- CLAUDE.md ← AI context map (codebeacon block merged; user content preserved)
96
- .cursorrules ← Cursor IDE context (same merge strategy)
97
- AGENTS.md ← OpenAI Agents context (same merge strategy)
98
- .codebeacon/
99
- beacon.json ← full knowledge graph (node-link JSON)
100
- REPORT.md ← god nodes, surprising connections, hub files
101
- wiki/
102
- index.md ← global index (~200 tokens)
103
- overview.md ← platform stats + cross-project connections
104
- routes.md ← all routes table
105
- cross-project/
106
- connections.md ← cross-service edges
107
- <project>/
108
- index.md
109
- routes.md
110
- controllers/<Name>.md
111
- services/<Name>.md
112
- entities/<Name>.md
113
- components/<Name>.md
114
- obsidian/ ← Obsidian vault (one note per node)
115
- ```
116
-
117
- ## Supported frameworks
118
-
119
- | Language | Frameworks |
120
- |----------|-----------|
121
- | Java/Kotlin | Spring Boot, Ktor |
122
- | Python | Django, FastAPI, Flask |
123
- | JavaScript/TypeScript | Express, Fastify, Koa, NestJS, React, Next.js, Vue, Nuxt, Angular, SvelteKit |
124
- | Go | Gin, Echo, Fiber |
125
- | Ruby | Rails |
126
- | PHP | Laravel |
127
- | Rust | Actix-Web, Axum, Tauri, Rocket, Warp |
128
- | C# | ASP.NET Core |
129
- | Swift | Vapor |
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes