codebeacon 0.3.0__tar.gz → 0.3.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {codebeacon-0.3.0 → codebeacon-0.3.2}/PKG-INFO +85 -11
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.de.md +69 -7
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.es.md +68 -7
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.fr.md +69 -7
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.ja.md +70 -7
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.ko.md +85 -10
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.md +84 -10
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.pt-BR.md +68 -7
- {codebeacon-0.3.0 → codebeacon-0.3.2}/README.zh-CN.md +69 -7
- codebeacon-0.3.2/codebeacon/__init__.py +1 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/cli.py +84 -1
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/config.py +57 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/discover/detector.py +12 -4
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/semantic.py +6 -88
- codebeacon-0.3.2/codebeacon/semantic_pipeline.py +457 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/pyproject.toml +1 -1
- codebeacon-0.3.2/skill/SKILL.md +189 -0
- codebeacon-0.3.0/codebeacon/__init__.py +0 -1
- codebeacon-0.3.0/skill/SKILL.md +0 -127
- {codebeacon-0.3.0 → codebeacon-0.3.2}/.cursorrules +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/.github/CODEOWNERS +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/.github/dependabot.yml +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/.github/workflows/ci.yml +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/.github/workflows/release.yml +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/.gitignore +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/AGENTS.md +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/CLAUDE.md +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/LICENSE +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/__main__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/cache.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/common/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/common/filters.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/common/safety.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/common/symbols.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/common/types.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/contextmap/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/contextmap/generator.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/discover/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/discover/ignore.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/discover/scanner.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/export/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/export/callflow_html.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/export/hooks.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/export/mcp.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/export/merge.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/export/obsidian.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/export/tree_html.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/base.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/components.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/dependencies.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/entities.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/README.md +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/actix.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/angular.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/aspnet.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/django.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/express.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/fastapi.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/flask.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/gin.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/ktor.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/laravel.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/nestjs.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/rails.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/react.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/spring_boot.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/svelte.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/tauri.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/vapor.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/queries/vue.scm +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/routes.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/extract/services.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/graph/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/graph/analyze.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/graph/build.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/graph/cluster.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/graph/enrich.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/graph/write.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/plugins/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/plugins/githooks.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/plugins/skills.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/skill/SKILL.md +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/wave.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/wiki/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/wiki/generator.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/wiki/index.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon/wiki/templates.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/codebeacon.yaml.example +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/docs/TRANSLATION_STATUS.md +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/public-plan.md +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/skill/install.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/__init__.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/conftest.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/actix/main.rs +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/angular/app.component.ts +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/aspnet/UserController.cs +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/django/views.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/express/userRouter.js +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/fastapi/main.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/flask/app.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/gin/main.go +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/ktor/UserRoutes.kt +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/laravel/UserController.php +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/nestjs/user.controller.ts +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/rails/users_controller.rb +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/react/UserPage.tsx +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/spring_boot/UserController.java +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/sveltekit/+page.svelte +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/vapor/routes.swift +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/fixtures/vue/UserList.vue +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_discover.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_entities.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_filters.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_graph.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_plugins.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_resolve.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_routes.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_safety_and_writes.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_services.py +0 -0
- {codebeacon-0.3.0 → codebeacon-0.3.2}/tests/test_wiki.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: codebeacon
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.2
|
|
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
|
|
@@ -96,6 +96,7 @@ Existing tools solve this partially. Route analyzers map your controllers but mi
|
|
|
96
96
|
- **gitignore-style `.codebeaconignore`** — last-match-wins with `!` negation, dir patterns (`build/`), anchored patterns (`/secrets.txt`), trailing-whitespace rules
|
|
97
97
|
- **Zero configuration** — auto-detects frameworks and languages; generates `codebeacon.yaml` for repeat runs
|
|
98
98
|
- **Deep-dive mode** — `--deep-dive` generates per-project `.codebeacon/` + `CLAUDE.md` for every sub-project; running `codebeacon scan . --update` from any sub-project folder automatically syncs all projects in the workspace
|
|
99
|
+
- **Workspace auto-rediscovery** — on every `scan` / `sync`, codebeacon re-scans the workspace and appends any new project folders to `codebeacon.yaml` before extraction, so freshly added sub-projects are never silently skipped; pass `--no-rediscover` to opt out for hand-curated configs
|
|
99
100
|
|
|
100
101
|
---
|
|
101
102
|
|
|
@@ -183,6 +184,12 @@ project-root/
|
|
|
183
184
|
entities/<Name>.md
|
|
184
185
|
components/<Name>.md
|
|
185
186
|
obsidian/ ← Obsidian vault (one note per graph node)
|
|
187
|
+
semantic/
|
|
188
|
+
original.jsonl ← durable archive of every applied AI-semantic result
|
|
189
|
+
(skipped on rescans, never re-emitted as a task)
|
|
190
|
+
semantic-tasks.jsonl ← pending AI-semantic batch (present only between
|
|
191
|
+
`semantic-prepare` and `semantic-apply`)
|
|
192
|
+
semantic-results.jsonl ← agent-written results (same lifecycle as above)
|
|
186
193
|
```
|
|
187
194
|
|
|
188
195
|
### Deep Dive Mode
|
|
@@ -242,11 +249,20 @@ codebeacon install
|
|
|
242
249
|
This copies `SKILL.md` to `~/.claude/skills/codebeacon/` and registers the `/codebeacon` trigger in `~/.claude/CLAUDE.md`. Restart your Claude Code session, then type `/codebeacon` to scan the current directory.
|
|
243
250
|
|
|
244
251
|
```
|
|
245
|
-
/codebeacon
|
|
246
|
-
/codebeacon /path/to/project
|
|
247
|
-
/codebeacon sync
|
|
252
|
+
/codebeacon # scan current directory + auto AI-semantic
|
|
253
|
+
/codebeacon /path/to/project # scan a specific path + auto AI-semantic
|
|
254
|
+
/codebeacon sync # re-scan from codebeacon.yaml + auto AI-semantic
|
|
255
|
+
/codebeacon <path> --no-semantic # scan only, skip the AI-semantic step
|
|
256
|
+
/codebeacon <path> --wiki-only # regenerate wiki from existing beacon.json
|
|
257
|
+
/codebeacon semantic-prepare # emit a fresh tasks file only
|
|
258
|
+
/codebeacon semantic-apply # merge a results file the agent already wrote
|
|
259
|
+
/codebeacon serve <path> # start MCP server pointing at .codebeacon/
|
|
260
|
+
/codebeacon query <term> # search the graph
|
|
261
|
+
/codebeacon path <src> <tgt> # shortest path
|
|
248
262
|
```
|
|
249
263
|
|
|
264
|
+
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
|
+
|
|
250
266
|
### MCP Server
|
|
251
267
|
|
|
252
268
|
Run codebeacon as a persistent MCP server so any MCP-compatible client can query your knowledge graph directly.
|
|
@@ -318,14 +334,25 @@ codebeacon scan /workspace # workspace root (multi-project)
|
|
|
318
334
|
codebeacon scan . --update # incremental: mtime/size fast path + content-hash fallback
|
|
319
335
|
codebeacon scan . --wiki-only # skip re-extraction, regenerate wiki/obsidian/context map from existing beacon.json
|
|
320
336
|
codebeacon scan . --obsidian-dir <path> # write Obsidian vault to custom location
|
|
321
|
-
codebeacon scan . --semantic # enable
|
|
337
|
+
codebeacon scan . --semantic # enable structured-comment semantic extraction (Javadoc/JSDoc/docstring refs)
|
|
322
338
|
codebeacon scan . --list-only # detect frameworks only, don't extract
|
|
323
339
|
codebeacon scan /workspace --deep-dive # per-project + combined workspace outputs
|
|
324
340
|
|
|
325
341
|
# Config-driven mode
|
|
326
342
|
codebeacon init [path] # auto-generate codebeacon.yaml
|
|
327
|
-
codebeacon sync # run from codebeacon.yaml
|
|
343
|
+
codebeacon sync # run from codebeacon.yaml (auto-appends new workspace projects)
|
|
328
344
|
codebeacon sync --config <file> # use a specific config file
|
|
345
|
+
codebeacon sync --no-rediscover # don't auto-append newly added projects (hand-curated yaml mode)
|
|
346
|
+
|
|
347
|
+
# AI-semantic enrichment (the agent does the LLM work, codebeacon does the bookkeeping)
|
|
348
|
+
codebeacon semantic-prepare [--dir .codebeacon] [--max-tasks N]
|
|
349
|
+
# rehydrate semantic archive onto beacon.json, emit fresh tasks
|
|
350
|
+
# for NEW candidates only (god-node folders + unresolved targets);
|
|
351
|
+
# writes .codebeacon/semantic-tasks.jsonl
|
|
352
|
+
codebeacon semantic-apply [--dir .codebeacon]
|
|
353
|
+
# read .codebeacon/semantic-results.jsonl, merge as INFERRED
|
|
354
|
+
# references edges, append to .codebeacon/semantic/original.jsonl
|
|
355
|
+
# archive, clear pending files, regenerate wiki/obsidian/context map
|
|
329
356
|
|
|
330
357
|
# Query the knowledge graph
|
|
331
358
|
codebeacon query <term> [--dir .codebeacon] [--limit N] # search nodes by label substring
|
|
@@ -342,6 +369,51 @@ codebeacon install # install Claude Code skill
|
|
|
342
369
|
|
|
343
370
|
---
|
|
344
371
|
|
|
372
|
+
## AI-Semantic Enrichment (via the `/codebeacon` skill)
|
|
373
|
+
|
|
374
|
+
Tree-sitter parsing finds what's in the AST. **AI-semantic** finds what's only in the *comments* — the `@see UserService` in a Javadoc, the `:class:`OrderRepository`` in a Python docstring, the contractual references documented next to a route handler. codebeacon ships two layers for this:
|
|
375
|
+
|
|
376
|
+
| Layer | Flag | Cost | What it catches |
|
|
377
|
+
|---|---|---|---|
|
|
378
|
+
| Structured-comment parsing | `--semantic` | free, local, no LLM | Javadoc `@see` / `{@link}`, JSDoc `@see` / `@param` types, Python `:class:` / `:func:` / `See Also` |
|
|
379
|
+
| **AI-semantic** | auto in `/codebeacon` skill | uses the agent's existing model — **no extra API key** | unresolved class/type/service references that regex can't catch (free-form prose, indirect mentions, type-only hints) |
|
|
380
|
+
|
|
381
|
+
The CLI itself never makes an LLM API call. The AI-semantic layer is intentionally **owned by the running agent** inside the `/codebeacon` Claude Code skill — that way the user's model choice (Opus / Sonnet / Haiku / anything) is honored, and codebeacon never needs `ANTHROPIC_API_KEY` or any cloud configuration.
|
|
382
|
+
|
|
383
|
+
### How it runs
|
|
384
|
+
|
|
385
|
+
When you invoke `/codebeacon` in Claude Code:
|
|
386
|
+
|
|
387
|
+
1. `scan` / `sync` builds `beacon.json` from the AST (no LLM).
|
|
388
|
+
2. `codebeacon semantic-prepare` re-applies the prior archive to the fresh graph, then writes `.codebeacon/semantic-tasks.jsonl` containing **only new candidates** — files that score high (unresolved-target edges + god-node folders) and have never been processed before.
|
|
389
|
+
3. The skill loops over the tasks file. For each line, the agent (using its current model) reads the `excerpt` field and returns inferred references inline. Results are written to `.codebeacon/semantic-results.jsonl`.
|
|
390
|
+
4. `codebeacon semantic-apply` merges the results as `INFERRED references` edges into `beacon.json`, **appends them to `.codebeacon/semantic/original.jsonl`** (the durable archive), clears the pending tasks/results files, and regenerates wiki + obsidian + context map.
|
|
391
|
+
5. Next scan: `semantic-prepare` rehydrates the archive onto the freshly built graph (so historical inferences don't disappear) and emits a tasks file with **only newly discovered candidates** since the last archive. Already-processed files are skipped via `task_id` (SHA1 of `file_path|node_id`).
|
|
392
|
+
|
|
393
|
+
This gives you incremental, idempotent enrichment: the agent never re-analyzes the same file twice, and accumulated AI signal survives every rescan.
|
|
394
|
+
|
|
395
|
+
### Direct CLI usage
|
|
396
|
+
|
|
397
|
+
If you're not running through the skill (e.g. CI), you can drive the same two commands manually and supply your own `semantic-results.jsonl`:
|
|
398
|
+
|
|
399
|
+
```bash
|
|
400
|
+
codebeacon scan .
|
|
401
|
+
codebeacon semantic-prepare --dir .codebeacon --max-tasks 50
|
|
402
|
+
|
|
403
|
+
# now write .codebeacon/semantic-results.jsonl yourself; each line is:
|
|
404
|
+
# {"task_id":"...", "source_node_id":"...", "edges":[
|
|
405
|
+
# {"target_name":"UserService","relation":"references","confidence_score":0.7}
|
|
406
|
+
# ]}
|
|
407
|
+
|
|
408
|
+
codebeacon semantic-apply --dir .codebeacon
|
|
409
|
+
```
|
|
410
|
+
|
|
411
|
+
### Opt out
|
|
412
|
+
|
|
413
|
+
Pass `--no-semantic` (or `--wiki-only`, or `--list-only`) when invoking the skill to skip the AI step entirely. The structured-comment layer still runs when you pass `--semantic` to `scan` / `sync`.
|
|
414
|
+
|
|
415
|
+
---
|
|
416
|
+
|
|
345
417
|
## Visual Exploration
|
|
346
418
|
|
|
347
419
|
Every scan writes two self-contained HTML files alongside `beacon.json`:
|
|
@@ -423,7 +495,9 @@ wave:
|
|
|
423
495
|
max_parallel: 5 # parallel threads
|
|
424
496
|
|
|
425
497
|
semantic:
|
|
426
|
-
enabled: false # override with --semantic
|
|
498
|
+
enabled: false # structured-comment extraction; override with --semantic.
|
|
499
|
+
# AI-semantic does NOT live here — it is invoked by the
|
|
500
|
+
# /codebeacon skill, see "AI-Semantic Enrichment" above.
|
|
427
501
|
|
|
428
502
|
deep_dive: false # set to true to generate per-project outputs
|
|
429
503
|
```
|
|
@@ -485,13 +559,13 @@ codebeacon is not a replacement for either tool — it's the union of what both
|
|
|
485
559
|
|
|
486
560
|
## Privacy & Security
|
|
487
561
|
|
|
488
|
-
All processing is local. Your source code never leaves your machine.
|
|
562
|
+
All AST processing is local. Your source code never leaves your machine when you run codebeacon directly.
|
|
489
563
|
|
|
490
564
|
- Tree-sitter AST parsing runs entirely in-process
|
|
491
565
|
- No telemetry, no analytics, no network calls during normal operation
|
|
492
|
-
- The
|
|
493
|
-
|
|
494
|
-
|
|
566
|
+
- The CLI **never calls an LLM provider on its own** — codebeacon ships no API client, no key handling, no model name
|
|
567
|
+
- `--semantic` activates **structured-comment parsing only** (Javadoc `@see` / `{@link}`, JSDoc `@see` / `@param` types, Python `:class:` / `:func:` / `See Also`). Fully local.
|
|
568
|
+
- **AI-semantic** (the deeper LLM-driven layer) is invoked by the `/codebeacon` Claude Code skill. The agent reads `semantic-tasks.jsonl`, runs the analysis under whatever model the user already picked, and writes `semantic-results.jsonl`. The Python CLI only prepares the task batch and merges the results — it has no idea which model was used. Pass `--no-semantic` in the skill to skip the LLM step entirely.
|
|
495
569
|
|
|
496
570
|
---
|
|
497
571
|
|
|
@@ -55,6 +55,7 @@ Bestehende Tools lösen dieses Problem nur teilweise. Route-Analyzer erfassen Ih
|
|
|
55
55
|
- **`.codebeaconignore` im gitignore-Stil** — last-match-wins mit `!`-Negation, Verzeichnis-Patterns (`build/`), verankerte Patterns (`/secrets.txt`), Trailing-Whitespace-Regeln
|
|
56
56
|
- **Keine Konfiguration notwendig** — erkennt Frameworks und Sprachen automatisch; generiert `codebeacon.yaml` für Folgeläufe
|
|
57
57
|
- **Deep-Dive-Modus** — `--deep-dive` erzeugt für jedes Sub-Projekt eigene `.codebeacon/` + `CLAUDE.md`; ein Update-Aufruf aus **beliebigem** Sub-Projekt-Ordner synchronisiert automatisch alle Projekte im Workspace
|
|
58
|
+
- **Automatische Workspace-Wiedererkennung** — bei jedem `scan`/`sync` scannt codebeacon den Workspace erneut und hängt vor der Extraktion automatisch neue Projekte an die `codebeacon.yaml` an, sodass frisch hinzugefügte Sub-Projekte nicht unbemerkt übersprungen werden; `--no-rediscover` deaktiviert dies für handgepflegte Konfigurationen
|
|
58
59
|
|
|
59
60
|
---
|
|
60
61
|
|
|
@@ -240,7 +241,10 @@ wave:
|
|
|
240
241
|
max_parallel: 5 # parallele Threads
|
|
241
242
|
|
|
242
243
|
semantic:
|
|
243
|
-
enabled: false #
|
|
244
|
+
enabled: false # nur strukturierte Kommentaranalyse;
|
|
245
|
+
# mit --semantic überschreiben. AI-semantik lebt NICHT
|
|
246
|
+
# hier — sie wird vom /codebeacon-Skill
|
|
247
|
+
# (= laufender Agent) ausgelöst.
|
|
244
248
|
|
|
245
249
|
deep_dive: false # auf true setzen für Pro-Projekt-Ausgabe
|
|
246
250
|
```
|
|
@@ -358,12 +362,13 @@ Java, Kotlin, Python, JavaScript, TypeScript, Go, Ruby, PHP, C#, Rust, Swift, HT
|
|
|
358
362
|
codebeacon scan . # aktuelles Verzeichnis
|
|
359
363
|
codebeacon scan . --update # inkrementell: nur geänderte Dateien
|
|
360
364
|
codebeacon scan . --wiki-only # Extraktion überspringen, Wiki/Obsidian/Kontext aus vorhandenem beacon.json regenerieren
|
|
361
|
-
codebeacon scan . --semantic #
|
|
365
|
+
codebeacon scan . --semantic # Extraktion strukturierter Kommentar-Referenzen (Javadoc/JSDoc/docstring)
|
|
362
366
|
codebeacon scan . --list-only # nur Frameworks erkennen
|
|
363
367
|
codebeacon scan /workspace --deep-dive # Pro-Projekt- + kombinierte Workspace-Ausgabe
|
|
364
368
|
|
|
365
369
|
codebeacon init [pfad] # codebeacon.yaml generieren
|
|
366
|
-
codebeacon sync # von codebeacon.yaml ausführen
|
|
370
|
+
codebeacon sync # von codebeacon.yaml ausführen (hängt neue Workspace-Projekte automatisch an)
|
|
371
|
+
codebeacon sync --no-rediscover # neue Projekte nicht automatisch anhängen (handgepflegter yaml-Modus)
|
|
367
372
|
|
|
368
373
|
codebeacon query <Begriff> [--dir .codebeacon] [--limit N] # Knoten per Label-Substring suchen
|
|
369
374
|
codebeacon path <Quelle> <Ziel> [--dir .codebeacon] # kürzester Abhängigkeitspfad
|
|
@@ -372,12 +377,69 @@ codebeacon path <Quelle> <Ziel> [--dir .codebeacon] # kürzester Abhän
|
|
|
372
377
|
codebeacon hook install [path] # Merge-Driver + Post-Commit-Inkrement-Rebuild installieren
|
|
373
378
|
codebeacon merge-driver <base> <cur> <other> # von git nach `hook install` aufgerufen; Union-Merge von beacon.json
|
|
374
379
|
|
|
380
|
+
# AI-semantische Anreicherung (LLM macht der Agent, codebeacon nur die Buchführung)
|
|
381
|
+
codebeacon semantic-prepare [--dir .codebeacon] [--max-tasks N]
|
|
382
|
+
# spielt vorhandenes Archiv wieder auf das frische
|
|
383
|
+
# beacon.json an und gibt Aufgaben nur für NEUE
|
|
384
|
+
# Kandidaten aus (god-node-Ordner + unaufgelöste Ziele)
|
|
385
|
+
codebeacon semantic-apply [--dir .codebeacon]
|
|
386
|
+
# mergt .codebeacon/semantic-results.jsonl als
|
|
387
|
+
# INFERRED references-Kanten in beacon.json,
|
|
388
|
+
# hängt an .codebeacon/semantic/original.jsonl an,
|
|
389
|
+
# räumt Pending-Dateien auf und regeneriert
|
|
390
|
+
# wiki/obsidian/Kontextkarte
|
|
391
|
+
|
|
375
392
|
codebeacon serve [--dir .codebeacon] # MCP-Server starten (stdio)
|
|
376
393
|
codebeacon install # Claude-Code-Skill installieren
|
|
377
394
|
```
|
|
378
395
|
|
|
379
396
|
---
|
|
380
397
|
|
|
398
|
+
## AI-semantische Anreicherung (via `/codebeacon`-Skill)
|
|
399
|
+
|
|
400
|
+
Tree-sitter-Parsing findet, was im AST steht. **AI-semantik** findet, was nur in den *Kommentaren* lebt — das `@see UserService` in einer Javadoc, das `:class:`OrderRepository`` in einer Python-Docstring, die vertraglichen Referenzen neben einem Route-Handler. codebeacon liefert dafür zwei Schichten:
|
|
401
|
+
|
|
402
|
+
| Schicht | Flag | Kosten | Was sie erfasst |
|
|
403
|
+
|---|---|---|---|
|
|
404
|
+
| Strukturierte Kommentaranalyse | `--semantic` | kostenlos, lokal, kein LLM | Javadoc `@see` / `{@link}`, JSDoc `@see` / `@param`-Typen, Python `:class:` / `:func:` / `See Also` |
|
|
405
|
+
| **AI-semantik** | automatisch im `/codebeacon`-Skill | nutzt das aktuelle Modell des Agenten — **kein extra API-Schlüssel** | nicht aufgelöste Klassen-/Typ-/Service-Referenzen, die Regex nicht findet (freier Prosa, indirekte Erwähnungen, reine Typ-Hinweise) |
|
|
406
|
+
|
|
407
|
+
Das CLI selbst **ruft niemals einen LLM-Anbieter auf**. Die AI-semantik-Schicht gehört bewusst dem **laufenden Agenten** innerhalb des `/codebeacon` Claude-Code-Skills — so wird die Modellwahl des Nutzers (Opus / Sonnet / Haiku / etc.) respektiert, und codebeacon braucht weder `ANTHROPIC_API_KEY` noch irgendeine Cloud-Konfiguration.
|
|
408
|
+
|
|
409
|
+
### Wie es läuft
|
|
410
|
+
|
|
411
|
+
Wenn Sie `/codebeacon` in Claude Code aufrufen:
|
|
412
|
+
|
|
413
|
+
1. `scan` / `sync` baut `beacon.json` aus dem AST (kein LLM-Aufruf).
|
|
414
|
+
2. `codebeacon semantic-prepare` spielt das frühere Archiv wieder auf den frischen Graphen ein und schreibt dann `.codebeacon/semantic-tasks.jsonl` mit **nur neuen Kandidaten** — hochbewertete Dateien (Kanten zu nicht aufgelösten Zielen + god-node-Ordner), die noch nie verarbeitet wurden.
|
|
415
|
+
3. Der Skill iteriert die Tasks-Datei. Für jede Zeile liest der Agent (mit dem Modell der aktuellen Sitzung) das `excerpt`-Feld und liefert inline gefolgerte References. Ergebnisse werden in `.codebeacon/semantic-results.jsonl` geschrieben.
|
|
416
|
+
4. `codebeacon semantic-apply` mergt die Ergebnisse als `INFERRED references`-Kanten in `beacon.json`, **hängt sie an `.codebeacon/semantic/original.jsonl`** (das dauerhafte Archiv) an, räumt die Pending-Dateien auf und regeneriert Wiki + Obsidian + Kontextkarte.
|
|
417
|
+
5. Beim nächsten Scan: `semantic-prepare` rehydriert das Archiv auf den frisch gebauten Graphen (damit historische Inferenzen nicht durch ein erneutes Scannen verschwinden) und gibt eine Tasks-Datei mit **nur den seit dem letzten Archiv neu entdeckten Kandidaten** aus. Bereits verarbeitete Dateien werden per `task_id` (SHA1 von `file_path|node_id`) übersprungen.
|
|
418
|
+
|
|
419
|
+
Das ergibt inkrementelle, idempotente Anreicherung: der Agent analysiert dieselbe Datei nie zweimal, und das angesammelte AI-Signal überlebt jeden Rescan.
|
|
420
|
+
|
|
421
|
+
### Direkte CLI-Nutzung
|
|
422
|
+
|
|
423
|
+
Wenn Sie nicht über den Skill gehen (z. B. CI), können Sie dieselben zwei Befehle manuell ausführen und Ihr eigenes `semantic-results.jsonl` liefern:
|
|
424
|
+
|
|
425
|
+
```bash
|
|
426
|
+
codebeacon scan .
|
|
427
|
+
codebeacon semantic-prepare --dir .codebeacon --max-tasks 50
|
|
428
|
+
|
|
429
|
+
# jetzt selbst .codebeacon/semantic-results.jsonl schreiben; jede Zeile:
|
|
430
|
+
# {"task_id":"...", "source_node_id":"...", "edges":[
|
|
431
|
+
# {"target_name":"UserService","relation":"references","confidence_score":0.7}
|
|
432
|
+
# ]}
|
|
433
|
+
|
|
434
|
+
codebeacon semantic-apply --dir .codebeacon
|
|
435
|
+
```
|
|
436
|
+
|
|
437
|
+
### Deaktivieren
|
|
438
|
+
|
|
439
|
+
Übergeben Sie `--no-semantic` (oder `--wiki-only`, oder `--list-only`) beim Aufruf des Skills, um den AI-Schritt komplett zu überspringen. Die strukturierte Kommentaranalyse läuft weiterhin, wenn Sie `--semantic` an `scan` / `sync` übergeben.
|
|
440
|
+
|
|
441
|
+
---
|
|
442
|
+
|
|
381
443
|
## Vergleich
|
|
382
444
|
|
|
383
445
|
| | codesight | graphify | **codebeacon** |
|
|
@@ -406,11 +468,11 @@ codebeacon install # Claude-Code-Skill installieren
|
|
|
406
468
|
|
|
407
469
|
## Datenschutz und Sicherheit
|
|
408
470
|
|
|
409
|
-
|
|
471
|
+
Die gesamte AST-Verarbeitung läuft lokal. Wenn Sie codebeacon direkt aufrufen, verlässt Ihr Quellcode niemals Ihren Rechner. Keine Telemetrie, keine Netzwerkaufrufe im normalen Betrieb.
|
|
410
472
|
|
|
411
|
-
-
|
|
412
|
-
|
|
413
|
-
|
|
473
|
+
- Die CLI selbst **ruft niemals einen LLM-Anbieter auf** — das codebeacon-Paket enthält weder API-Client, noch Schlüsselverwaltung, noch Modellnamen.
|
|
474
|
+
- `--semantic` aktiviert **ausschließlich die strukturierte Kommentaranalyse** (Javadoc `@see` / `{@link}`, JSDoc `@see` / `@param`-Typen, Python `:class:` / `:func:` / `See Also`). Vollständig lokal.
|
|
475
|
+
- **AI-semantik** (die tiefere LLM-Schicht) wird vom `/codebeacon` Claude-Code-Skill ausgelöst. Der Agent liest `semantic-tasks.jsonl`, führt die Analyse mit dem **Modell der laufenden Sitzung** aus und schreibt `semantic-results.jsonl`. Die Python-CLI bereitet nur das Aufgaben-Batch vor und mergt die Ergebnisse — sie weiß nicht einmal, welches Modell verwendet wurde. Übergeben Sie `--no-semantic` an den Skill, um den LLM-Schritt vollständig zu überspringen.
|
|
414
476
|
|
|
415
477
|
---
|
|
416
478
|
|
|
@@ -55,6 +55,7 @@ Las herramientas existentes resuelven esto de forma parcial. Los analizadores de
|
|
|
55
55
|
- **`.codebeaconignore` estilo gitignore** — last-match-wins con negación `!`, patrones de directorio (`build/`), patrones anclados (`/secrets.txt`), reglas de espacio final
|
|
56
56
|
- **Cero configuración** — detecta frameworks y lenguajes automáticamente; genera `codebeacon.yaml` para ejecuciones posteriores
|
|
57
57
|
- **Modo Deep Dive** — `--deep-dive` genera `.codebeacon/` + `CLAUDE.md` propios para cada sub-proyecto; ejecutar el comando de actualización desde **cualquier** sub-proyecto sincroniza automáticamente todos los proyectos del workspace
|
|
58
|
+
- **Auto-redescubrimiento del workspace** — en cada `scan`/`sync`, codebeacon re-escanea el workspace y añade automáticamente al `codebeacon.yaml` los nuevos proyectos antes de extraer, de modo que los sub-proyectos recién añadidos nunca se omitan silenciosamente; usa `--no-rediscover` para optar por el modo de configuración curada manualmente
|
|
58
59
|
|
|
59
60
|
---
|
|
60
61
|
|
|
@@ -239,7 +240,9 @@ wave:
|
|
|
239
240
|
max_parallel: 5 # hilos paralelos
|
|
240
241
|
|
|
241
242
|
semantic:
|
|
242
|
-
enabled: false #
|
|
243
|
+
enabled: false # solo extracción de comentarios estructurados;
|
|
244
|
+
# --semantic lo activa. El AI-semántico NO vive aquí:
|
|
245
|
+
# lo dispara el skill /codebeacon (= el agente en ejecución).
|
|
243
246
|
|
|
244
247
|
deep_dive: false # establecer true para salida por proyecto
|
|
245
248
|
```
|
|
@@ -357,12 +360,13 @@ Los parsers de Java, Kotlin, Python, JavaScript, TypeScript, Go, Ruby, PHP, C#,
|
|
|
357
360
|
codebeacon scan . # directorio actual
|
|
358
361
|
codebeacon scan . --update # incremental: solo archivos modificados
|
|
359
362
|
codebeacon scan . --wiki-only # saltar extracción, regenerar wiki/obsidian/contexto desde beacon.json existente
|
|
360
|
-
codebeacon scan . --semantic # extracción
|
|
363
|
+
codebeacon scan . --semantic # extracción de referencias de comentarios estructurados (Javadoc/JSDoc/docstring)
|
|
361
364
|
codebeacon scan . --list-only # solo detectar frameworks
|
|
362
365
|
codebeacon scan /workspace --deep-dive # salida por proyecto + workspace combinado
|
|
363
366
|
|
|
364
367
|
codebeacon init [ruta] # generar codebeacon.yaml
|
|
365
|
-
codebeacon sync # ejecutar desde codebeacon.yaml
|
|
368
|
+
codebeacon sync # ejecutar desde codebeacon.yaml (añade nuevos proyectos del workspace automáticamente)
|
|
369
|
+
codebeacon sync --no-rediscover # no añadir automáticamente nuevos proyectos (modo yaml curado a mano)
|
|
366
370
|
|
|
367
371
|
codebeacon query <término> [--dir .codebeacon] [--limit N] # buscar nodos por substring de etiqueta
|
|
368
372
|
codebeacon path <origen> <destino> [--dir .codebeacon] # ruta más corta de dependencias
|
|
@@ -371,12 +375,69 @@ codebeacon path <origen> <destino> [--dir .codebeacon] # ruta más corta d
|
|
|
371
375
|
codebeacon hook install [path] # instala merge driver + hook post-commit incremental
|
|
372
376
|
codebeacon merge-driver <base> <cur> <other> # invocado por git tras `hook install`; union-merge de beacon.json
|
|
373
377
|
|
|
378
|
+
# Enriquecimiento AI-semántico (el LLM lo ejecuta el agente, codebeacon lleva la contabilidad)
|
|
379
|
+
codebeacon semantic-prepare [--dir .codebeacon] [--max-tasks N]
|
|
380
|
+
# rehidrata el archivo histórico sobre el nuevo beacon.json
|
|
381
|
+
# y emite tareas solo para candidatos NUEVOS
|
|
382
|
+
# (carpetas god-node + objetivos no resueltos)
|
|
383
|
+
codebeacon semantic-apply [--dir .codebeacon]
|
|
384
|
+
# fusiona .codebeacon/semantic-results.jsonl como
|
|
385
|
+
# aristas INFERRED references en beacon.json,
|
|
386
|
+
# añade al archivo .codebeacon/semantic/original.jsonl,
|
|
387
|
+
# limpia los archivos pendientes y regenera
|
|
388
|
+
# wiki/obsidian/mapa de contexto
|
|
389
|
+
|
|
374
390
|
codebeacon serve [--dir .codebeacon] # servidor MCP (stdio)
|
|
375
391
|
codebeacon install # instalar skill de Claude Code
|
|
376
392
|
```
|
|
377
393
|
|
|
378
394
|
---
|
|
379
395
|
|
|
396
|
+
## Enriquecimiento AI-semántico (mediante el skill `/codebeacon`)
|
|
397
|
+
|
|
398
|
+
El análisis con tree-sitter encuentra lo que está en el AST. **AI-semántico** encuentra lo que vive sólo en los *comentarios* — el `@see UserService` en un Javadoc, el `:class:`OrderRepository`` en una docstring de Python, las referencias contractuales documentadas junto a un handler de ruta. codebeacon ofrece dos capas para esto:
|
|
399
|
+
|
|
400
|
+
| Capa | Flag | Coste | Qué captura |
|
|
401
|
+
|---|---|---|---|
|
|
402
|
+
| Análisis de comentarios estructurados | `--semantic` | gratis, local, sin LLM | Javadoc `@see` / `{@link}`, JSDoc `@see` / tipos de `@param`, Python `:class:` / `:func:` / `See Also` |
|
|
403
|
+
| **AI-semántico** | automático en el skill `/codebeacon` | usa el modelo actual del agente — **sin API key adicional** | referencias de clase/tipo/servicio que el regex no atrapa (texto libre, menciones indirectas, sólo hints de tipo) |
|
|
404
|
+
|
|
405
|
+
El CLI por sí mismo **nunca llama a un LLM**. La capa AI-semántica es propiedad intencional del **agente en ejecución** dentro del skill `/codebeacon` de Claude Code — así se respeta el modelo elegido por el usuario (Opus / Sonnet / Haiku / lo que sea) y codebeacon nunca necesita `ANTHROPIC_API_KEY` ni configuración en la nube.
|
|
406
|
+
|
|
407
|
+
### Cómo funciona
|
|
408
|
+
|
|
409
|
+
Cuando invocas `/codebeacon` en Claude Code:
|
|
410
|
+
|
|
411
|
+
1. `scan` / `sync` construye `beacon.json` desde el AST (sin LLM).
|
|
412
|
+
2. `codebeacon semantic-prepare` reaplica el archivo histórico sobre el grafo nuevo y luego escribe `.codebeacon/semantic-tasks.jsonl` con **sólo los candidatos nuevos** — archivos con puntuación alta (aristas a objetivos no resueltos + carpetas god-node) que nunca se han procesado.
|
|
413
|
+
3. El skill itera sobre el archivo de tareas. Por cada línea, el agente (usando el modelo de su sesión actual) lee el campo `excerpt` y devuelve referencias inferidas en línea. Los resultados se escriben en `.codebeacon/semantic-results.jsonl`.
|
|
414
|
+
4. `codebeacon semantic-apply` mezcla los resultados como aristas `INFERRED references` en `beacon.json`, **los anexa a `.codebeacon/semantic/original.jsonl`** (el archivo durable), limpia los ficheros pendientes y regenera wiki + obsidian + mapa de contexto.
|
|
415
|
+
5. En la próxima ejecución: `semantic-prepare` rehidrata el archivo sobre el grafo recién construido (para que las inferencias históricas no desaparezcan en una nueva exploración) y emite un fichero de tareas con **sólo candidatos nuevos** desde la última actualización del archivo. Los archivos ya procesados se omiten vía `task_id` (SHA1 de `file_path|node_id`).
|
|
416
|
+
|
|
417
|
+
Esto da enriquecimiento incremental e idempotente: el agente nunca reanaliza el mismo archivo dos veces, y la señal AI acumulada sobrevive a cada re-escaneo.
|
|
418
|
+
|
|
419
|
+
### Uso directo del CLI
|
|
420
|
+
|
|
421
|
+
Si no usas el skill (p. ej. en CI), puedes ejecutar las mismas dos órdenes manualmente y suministrar tu propio `semantic-results.jsonl`:
|
|
422
|
+
|
|
423
|
+
```bash
|
|
424
|
+
codebeacon scan .
|
|
425
|
+
codebeacon semantic-prepare --dir .codebeacon --max-tasks 50
|
|
426
|
+
|
|
427
|
+
# ahora escribe tú mismo .codebeacon/semantic-results.jsonl; cada línea:
|
|
428
|
+
# {"task_id":"...", "source_node_id":"...", "edges":[
|
|
429
|
+
# {"target_name":"UserService","relation":"references","confidence_score":0.7}
|
|
430
|
+
# ]}
|
|
431
|
+
|
|
432
|
+
codebeacon semantic-apply --dir .codebeacon
|
|
433
|
+
```
|
|
434
|
+
|
|
435
|
+
### Desactivar
|
|
436
|
+
|
|
437
|
+
Pasa `--no-semantic` (o `--wiki-only`, o `--list-only`) al invocar el skill para saltarte por completo el paso AI. La capa de comentarios estructurados sigue funcionando cuando pasas `--semantic` a `scan` / `sync`.
|
|
438
|
+
|
|
439
|
+
---
|
|
440
|
+
|
|
380
441
|
## Comparativa
|
|
381
442
|
|
|
382
443
|
| | codesight | graphify | **codebeacon** |
|
|
@@ -405,11 +466,11 @@ codebeacon install # instalar skill de Claude Code
|
|
|
405
466
|
|
|
406
467
|
## Privacidad y seguridad
|
|
407
468
|
|
|
408
|
-
Todo el procesamiento es local.
|
|
469
|
+
Todo el procesamiento AST es local. Al ejecutar codebeacon directamente, su código fuente nunca sale de su máquina. Sin telemetría ni llamadas de red durante el uso normal.
|
|
409
470
|
|
|
410
|
-
-
|
|
411
|
-
|
|
412
|
-
|
|
471
|
+
- El propio CLI **nunca llama a un proveedor LLM** — el paquete codebeacon no incluye cliente API, ni manejo de claves, ni nombre de modelo.
|
|
472
|
+
- `--semantic` activa **solo el análisis de comentarios estructurados** (Javadoc `@see` / `{@link}`, JSDoc `@see` / tipos de `@param`, Python `:class:` / `:func:` / `See Also`). 100 % local.
|
|
473
|
+
- **AI-semántico** (la capa LLM más profunda) lo dispara el skill `/codebeacon` de Claude Code. El agente lee `semantic-tasks.jsonl`, ejecuta el análisis con el **modelo de su sesión actual** y escribe `semantic-results.jsonl`. El CLI Python solo prepara el lote de tareas y fusiona los resultados; ni siquiera sabe qué modelo se utilizó. Pase `--no-semantic` al skill para omitir por completo el paso LLM.
|
|
413
474
|
|
|
414
475
|
---
|
|
415
476
|
|
|
@@ -55,6 +55,7 @@ Les outils existants ne résolvent ce problème qu'en partie. Les analyseurs de
|
|
|
55
55
|
- **`.codebeaconignore` style gitignore** — last-match-wins avec négation `!`, patterns de répertoire (`build/`), patterns ancrés (`/secrets.txt`), règles sur espaces de fin
|
|
56
56
|
- **Zéro configuration** — détecte automatiquement les frameworks et langages ; génère `codebeacon.yaml` pour les exécutions suivantes
|
|
57
57
|
- **Mode Deep Dive** — `--deep-dive` génère un `.codebeacon/` + `CLAUDE.md` propre à chaque sous-projet ; une commande de mise à jour depuis **n'importe quel** sous-projet synchronise automatiquement tous les projets du workspace
|
|
58
|
+
- **Redécouverte automatique du workspace** — à chaque `scan`/`sync`, codebeacon réanalyse le workspace et ajoute automatiquement les nouveaux projets au `codebeacon.yaml` avant l'extraction, de sorte que les sous-projets fraîchement ajoutés ne soient jamais oubliés en silence ; utilisez `--no-rediscover` pour conserver une configuration yaml gérée manuellement
|
|
58
59
|
|
|
59
60
|
---
|
|
60
61
|
|
|
@@ -239,7 +240,10 @@ wave:
|
|
|
239
240
|
max_parallel: 5 # threads parallèles
|
|
240
241
|
|
|
241
242
|
semantic:
|
|
242
|
-
enabled: false #
|
|
243
|
+
enabled: false # uniquement l'extraction de commentaires structurés ;
|
|
244
|
+
# activée par --semantic. L'AI-sémantique N'EST PAS ici :
|
|
245
|
+
# elle est déclenchée par le skill /codebeacon
|
|
246
|
+
# (= l'agent en cours d'exécution).
|
|
243
247
|
|
|
244
248
|
deep_dive: false # mettre à true pour une sortie par projet
|
|
245
249
|
```
|
|
@@ -357,12 +361,13 @@ Les parsers Java, Kotlin, Python, JavaScript, TypeScript, Go, Ruby, PHP, C#, Rus
|
|
|
357
361
|
codebeacon scan . # répertoire courant
|
|
358
362
|
codebeacon scan . --update # incrémental : fichiers modifiés seulement
|
|
359
363
|
codebeacon scan . --wiki-only # ignorer la ré-extraction, régénérer wiki/obsidian/contexte depuis beacon.json existant
|
|
360
|
-
codebeacon scan . --semantic # extraction
|
|
364
|
+
codebeacon scan . --semantic # extraction des références dans commentaires structurés (Javadoc/JSDoc/docstring)
|
|
361
365
|
codebeacon scan . --list-only # détecter les frameworks uniquement
|
|
362
366
|
codebeacon scan /workspace --deep-dive # sortie par projet + workspace combiné
|
|
363
367
|
|
|
364
368
|
codebeacon init [chemin] # générer codebeacon.yaml
|
|
365
|
-
codebeacon sync # exécuter depuis codebeacon.yaml
|
|
369
|
+
codebeacon sync # exécuter depuis codebeacon.yaml (ajoute automatiquement les nouveaux projets du workspace)
|
|
370
|
+
codebeacon sync --no-rediscover # ne pas ajouter automatiquement les nouveaux projets (mode yaml géré manuellement)
|
|
366
371
|
|
|
367
372
|
codebeacon query <terme> [--dir .codebeacon] [--limit N] # rechercher des nœuds par sous-chaîne de label
|
|
368
373
|
codebeacon path <source> <cible> [--dir .codebeacon] # chemin de dépendances le plus court
|
|
@@ -371,12 +376,69 @@ codebeacon path <source> <cible> [--dir .codebeacon] # chemin de dépendan
|
|
|
371
376
|
codebeacon hook install [path] # installer merge driver + hook post-commit incrémental
|
|
372
377
|
codebeacon merge-driver <base> <cur> <other> # invoqué par git après `hook install` ; union-merge de beacon.json
|
|
373
378
|
|
|
379
|
+
# Enrichissement AI-sémantique (le LLM est exécuté par l'agent, codebeacon tient la comptabilité)
|
|
380
|
+
codebeacon semantic-prepare [--dir .codebeacon] [--max-tasks N]
|
|
381
|
+
# réapplique l'archive existante au beacon.json frais
|
|
382
|
+
# puis n'émet de tâches que pour les candidats NEUFS
|
|
383
|
+
# (dossiers god-node + cibles non résolues)
|
|
384
|
+
codebeacon semantic-apply [--dir .codebeacon]
|
|
385
|
+
# fusionne .codebeacon/semantic-results.jsonl comme
|
|
386
|
+
# arêtes INFERRED references dans beacon.json,
|
|
387
|
+
# ajoute à l'archive .codebeacon/semantic/original.jsonl,
|
|
388
|
+
# nettoie les fichiers en attente et régénère
|
|
389
|
+
# wiki/obsidian/carte de contexte
|
|
390
|
+
|
|
374
391
|
codebeacon serve [--dir .codebeacon] # serveur MCP (stdio)
|
|
375
392
|
codebeacon install # installer le skill Claude Code
|
|
376
393
|
```
|
|
377
394
|
|
|
378
395
|
---
|
|
379
396
|
|
|
397
|
+
## Enrichissement AI-sémantique (via le skill `/codebeacon`)
|
|
398
|
+
|
|
399
|
+
L'analyse tree-sitter trouve ce qui est dans l'AST. **AI-sémantique** trouve ce qui ne vit que dans les *commentaires* — le `@see UserService` dans une Javadoc, le `:class:`OrderRepository`` dans une docstring Python, les références contractuelles documentées à côté d'un handler de route. codebeacon propose deux couches pour cela :
|
|
400
|
+
|
|
401
|
+
| Couche | Flag | Coût | Ce qu'elle capture |
|
|
402
|
+
|---|---|---|---|
|
|
403
|
+
| Analyse de commentaires structurés | `--semantic` | gratuit, local, sans LLM | Javadoc `@see` / `{@link}`, JSDoc `@see` / types `@param`, Python `:class:` / `:func:` / `See Also` |
|
|
404
|
+
| **AI-sémantique** | auto dans le skill `/codebeacon` | utilise le modèle courant de l'agent — **aucune clé API supplémentaire** | références de classe/type/service que la regex ne peut pas attraper (prose libre, mentions indirectes, hints de type uniquement) |
|
|
405
|
+
|
|
406
|
+
Le CLI lui-même **n'appelle jamais un LLM**. La couche AI-sémantique est intentionnellement **propriété de l'agent en cours d'exécution** à l'intérieur du skill Claude Code `/codebeacon` — ainsi le modèle choisi par l'utilisateur (Opus / Sonnet / Haiku / autre) est respecté et codebeacon n'a jamais besoin de `ANTHROPIC_API_KEY` ni d'aucune configuration cloud.
|
|
407
|
+
|
|
408
|
+
### Comment ça tourne
|
|
409
|
+
|
|
410
|
+
Quand vous invoquez `/codebeacon` dans Claude Code :
|
|
411
|
+
|
|
412
|
+
1. `scan` / `sync` construit `beacon.json` à partir de l'AST (aucun appel LLM).
|
|
413
|
+
2. `codebeacon semantic-prepare` réapplique l'archive précédente au graphe frais puis écrit `.codebeacon/semantic-tasks.jsonl` contenant **uniquement les nouveaux candidats** — fichiers à score élevé (arêtes vers cibles non résolues + dossiers god-node) qui n'ont jamais été traités.
|
|
414
|
+
3. Le skill itère sur le fichier de tâches. Pour chaque ligne, l'agent (en utilisant le modèle de sa session courante) lit le champ `excerpt` et renvoie inline les références inférées. Les résultats sont écrits dans `.codebeacon/semantic-results.jsonl`.
|
|
415
|
+
4. `codebeacon semantic-apply` fusionne les résultats en arêtes `INFERRED references` dans `beacon.json`, **les ajoute à `.codebeacon/semantic/original.jsonl`** (l'archive durable), nettoie les fichiers en attente et régénère wiki + obsidian + carte de contexte.
|
|
416
|
+
5. Au prochain scan : `semantic-prepare` réhydrate l'archive sur le graphe fraîchement construit (pour que les inférences historiques ne disparaissent pas lors d'un re-scan) et n'émet dans le fichier de tâches que **les candidats nouvellement découverts** depuis la dernière mise à jour de l'archive. Les fichiers déjà traités sont sautés via `task_id` (SHA1 de `file_path|node_id`).
|
|
417
|
+
|
|
418
|
+
Vous obtenez ainsi un enrichissement incrémental et idempotent : l'agent ne réanalyse jamais deux fois le même fichier et le signal AI accumulé survit à chaque re-scan.
|
|
419
|
+
|
|
420
|
+
### Utilisation directe du CLI
|
|
421
|
+
|
|
422
|
+
Si vous n'utilisez pas le skill (par ex. en CI), vous pouvez piloter les deux mêmes commandes manuellement et fournir votre propre `semantic-results.jsonl` :
|
|
423
|
+
|
|
424
|
+
```bash
|
|
425
|
+
codebeacon scan .
|
|
426
|
+
codebeacon semantic-prepare --dir .codebeacon --max-tasks 50
|
|
427
|
+
|
|
428
|
+
# écrivez vous-même .codebeacon/semantic-results.jsonl ; chaque ligne :
|
|
429
|
+
# {"task_id":"...", "source_node_id":"...", "edges":[
|
|
430
|
+
# {"target_name":"UserService","relation":"references","confidence_score":0.7}
|
|
431
|
+
# ]}
|
|
432
|
+
|
|
433
|
+
codebeacon semantic-apply --dir .codebeacon
|
|
434
|
+
```
|
|
435
|
+
|
|
436
|
+
### Désactivation
|
|
437
|
+
|
|
438
|
+
Passez `--no-semantic` (ou `--wiki-only`, ou `--list-only`) lors de l'invocation du skill pour sauter complètement l'étape AI. La couche de commentaires structurés fonctionne toujours quand vous passez `--semantic` à `scan` / `sync`.
|
|
439
|
+
|
|
440
|
+
---
|
|
441
|
+
|
|
380
442
|
## Comparaison
|
|
381
443
|
|
|
382
444
|
| | codesight | graphify | **codebeacon** |
|
|
@@ -405,11 +467,11 @@ codebeacon install # installer le skill Claude Code
|
|
|
405
467
|
|
|
406
468
|
## Confidentialité et sécurité
|
|
407
469
|
|
|
408
|
-
Tout le traitement est local.
|
|
470
|
+
Tout le traitement AST est local. Lorsque vous lancez codebeacon directement, le code source ne quitte jamais votre machine. Aucune télémétrie ni appel réseau pendant le fonctionnement normal.
|
|
409
471
|
|
|
410
|
-
-
|
|
411
|
-
|
|
412
|
-
|
|
472
|
+
- Le CLI lui-même **n'appelle jamais un fournisseur LLM** — le paquet codebeacon ne contient aucun client API, ni gestion de clé, ni nom de modèle.
|
|
473
|
+
- `--semantic` n'active que **l'analyse des commentaires structurés** (Javadoc `@see` / `{@link}`, JSDoc `@see` / types `@param`, Python `:class:` / `:func:` / `See Also`). 100 % local.
|
|
474
|
+
- **AI-sémantique** (la couche LLM plus profonde) est déclenchée par le skill `/codebeacon` de Claude Code. L'agent lit `semantic-tasks.jsonl`, exécute l'analyse avec **le modèle de sa session courante** et écrit `semantic-results.jsonl`. Le CLI Python prépare uniquement le lot de tâches et fusionne les résultats — il ne sait même pas quel modèle a été utilisé. Passez `--no-semantic` au skill pour ignorer entièrement l'étape LLM.
|
|
413
475
|
|
|
414
476
|
---
|
|
415
477
|
|