You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -23,7 +23,7 @@ Four intelligence layers. Ten MCP tools. One `pip install`.
23
23
24
24
Your AI coding agent reads files. It does not know who owns them, which ones change together, which ones are dead, or why they were built the way they were. It has the source code and zero institutional knowledge.
25
25
26
-
repowise fixes that. It indexes your codebase into four intelligence layers — dependency graph, git history, auto-generated documentation, and architectural decisions — and exposes them to Claude Code (and any MCP-compatible AI agent) through ten precisely designed tools. **27× fewer tokens per query. 36% cheaper. Same answer quality.**
26
+
repowise fixes that. It indexes your codebase into four intelligence layers — dependency graph, git history, auto-generated documentation, and architectural decisions — and exposes them to Claude Code (and any MCP-compatible AI agent) through eleven precisely designed tools. **27× fewer tokens per query. 36% cheaper. Same answer quality.**
27
27
28
28
The result: your agent answers *"why does auth work this way?"* instead of *"here is what auth.ts contains."*
29
29
@@ -115,7 +115,7 @@ Add to your Claude Code config (optional, `repowise init` already initializes `.
115
115
116
116
---
117
117
118
-
## Ten MCP tools
118
+
## Eleven MCP tools
119
119
120
120
Most tools are designed around data entities — one module, one file, one symbol — which forces AI agents into long chains of sequential calls. repowise tools are designed around **tasks**. Pass multiple targets in one call. Get complete context back.
121
121
@@ -131,6 +131,7 @@ Most tools are designed around data entities — one module, one file, one symbo
131
131
|`get_dependency_path(from, to)`| Connection path between two files, modules, or symbols | When tracing how two things are connected |
132
132
|`get_dead_code(min_confidence?, include_internals?, include_zombie_packages?)`| Unreachable code sorted by confidence and cleanup impact | Cleanup tasks |
133
133
|`get_architecture_diagram(module?)`| Mermaid diagram for the repo or a specific module | Documentation and presentation |
134
+
|`annotate_file(target, notes)`| Attach human-authored notes to a wiki page — survives re-indexing | Adding rationale, known issues, or context that the LLM shouldn't overwrite |
134
135
135
136
### Tool call comparison — a real task
136
137
@@ -274,7 +275,7 @@ repowise dead-code
274
275
✗ analytics/v1/tracker.ts file 0.41 recent activity — review first
More languages coming soon — Swift, Scala, PHP, Dart, and Elixir are on the roadmap.
412
-
413
-
Adding a new language requires one `.scm` tree-sitter query file and one config entry. No changes to the parser. PRs welcome. See [Adding a new language](docs/CONTRIBUTING.md#adding-a-new-language).
417
+
Dart and Elixir are on the roadmap. Adding a new language requires one `.scm` tree-sitter query file and one config entry. No changes to the parser core. PRs welcome. See [Adding a new language](docs/CONTRIBUTING.md#adding-a-new-language).
Copy file name to clipboardExpand all lines: docs/CHANGELOG.md
+29Lines changed: 29 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,6 +9,35 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
9
9
10
10
---
11
11
12
+
## [0.2.3] — 2026-04-11
13
+
14
+
### Added
15
+
-**`annotate_file` MCP tool** — attach human-authored notes to any wiki page. Notes survive LLM-driven re-generation and appear in `get_context` responses and the web UI. Pass an empty string to clear notes.
16
+
-**`repowise export --full`** — full JSON export now includes decision records, dead code findings, git hotspots, and per-page provenance metadata (confidence, freshness, model, provider).
17
+
-**Rust import resolution** — `use crate::`, `super::`, and `self::` imports now resolve to local files via crate root detection (`lib.rs`/`main.rs`). External crates mapped to `external:` nodes.
18
+
-**Go import resolution** — `go.mod` module path parsing enables accurate local vs external package classification. Local imports resolve by suffix matching against the module path.
19
+
-**C/C++ parser improvements** — added captures for `template_declaration`, `type_definition` (typedef struct/enum), `preproc_def` (#define), `preproc_function_def`, and forward declarations.
20
+
-**Go parser** — added `const_spec` and `var_spec` captures for package-level constants and variables.
21
+
-**Rust parser** — added `macro_definition` capture for `macro_rules!` macros.
22
+
-**Dynamic import detection** — dead code analysis now scans for `importlib.import_module()` and `__import__()` calls; files in the same package receive reduced confidence (capped at 0.4).
23
+
-**Framework decorator awareness** — Flask, FastAPI, and Django route/endpoint decorators added to `_FRAMEWORK_DECORATORS`. Decorated functions are never flagged as dead code.
24
+
-**`human_notes` column on wiki pages** — persists across re-indexing. Alembic migration `0014_page_human_notes`.
25
+
-**Decision staleness scoring during ingestion** — `compute_staleness()` now runs during `repowise init`, not just `repowise update`.
26
+
27
+
### Changed
28
+
-**CLAUDE.md template** — replaced imperative "MUST use" / "CRITICAL" language with advisory framing. Added `indexed_commit` display. Made `update_decision_records` optional ("SHOULD for architectural changes").
29
+
-**`get_context` freshness** — freshness data now included by default instead of requiring explicit `include=["freshness"]`.
30
+
-**`get_answer` docstring** — removed "do NOT verify by Read" instruction. High-confidence note changed to "verify cited file paths exist before acting on them".
Decisions have a `staleness_score` (0.0 = fresh, 1.0 = very stale) recomputed on every
963
-
`repowise update`. Staleness rises when affected files receive commits after the decision
964
-
was recorded. Decisions with `staleness_score > 0.5` are flagged as stale.
962
+
Decisions have a `staleness_score` (0.0 = fresh, 1.0 = very stale) computed during
963
+
`repowise init` and recomputed on every `repowise update`. Staleness rises when affected
964
+
files receive commits after the decision was recorded. Decisions with `staleness_score > 0.5`
965
+
are flagged as stale.
965
966
966
967
### MCP Tools
967
968
@@ -1008,7 +1009,7 @@ and supports two transports:
1008
1009
-**stdio** — for Claude Code, Cursor, Cline (add to their MCP config)
1009
1010
-**SSE** — for web-based MCP clients (served on port 7338)
1010
1011
1011
-
### Tools (9 total)
1012
+
### Tools (11 total)
1012
1013
1013
1014
| Tool | What it answers | When to call |
1014
1015
|------|----------------|-------------|
@@ -1021,6 +1022,9 @@ and supports two transports:
1021
1022
|`get_dependency_path(from, to)`| Connection path between two files/modules in the dependency graph. | When you need to understand how two things are connected. |
1022
1023
|`get_dead_code`| Dead/unused code findings sorted by confidence and cleanup impact. | Before cleanup tasks. |
1023
1024
|`get_architecture_diagram`| Mermaid diagram for repo or specific module. | For documentation or presentation. |
1025
+
|`get_answer`| One-call RAG: confidence-gated synthesis with cited answers and question cache. | First call on any code question — collapses search → read → reason. |
1026
+
|`get_symbol`| Resolve a qualified symbol id to source body, signature, and docstring. | When the question names a specific class, function, or method. |
1027
+
|`annotate_file`| Attach human-authored notes to a wiki page — survives re-indexing. | Adding rationale, known issues, or context the LLM shouldn't overwrite. |
Copy file name to clipboardExpand all lines: docs/architecture/deep-dives.md
+22-2Lines changed: 22 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,9 +43,9 @@ For each node in the dependency graph:
43
43
44
44
**Why in_degree alone isn't enough:**
45
45
46
-
Consider `plugin_auth.py`. Nothing imports it directly because the plugin framework loads it dynamically at runtime via `importlib.import_module()`. The graph doesn't capture dynamic imports because they don't appear in the AST as static import statements.
46
+
Consider `plugin_auth.py`. Nothing imports it directly because the plugin framework loads it dynamically at runtime via `importlib.import_module()`. The graph doesn't capture dynamic imports as edges because they don't appear in the AST as static import statements.
47
47
48
-
Repowise handles this with multiple layers of filtering:
48
+
Repowise handles this with multiple layers of filtering, including **dynamic import detection** — files in the same package as `importlib.import_module()` or `__import__()` calls automatically get reduced confidence scores:
Files matching these patterns aren't marked `safe_to_delete` even if confidence is high, because they're likely loaded dynamically.
78
86
87
+
**Layer 2b — Framework decorator awareness:**
88
+
89
+
Functions decorated with framework-specific route/endpoint decorators are never flagged as dead code:
90
+
91
+
- Flask: `@app.route`, `@blueprint.route`, `@app.before_request`, `@app.errorhandler`, etc.
92
+
- FastAPI: `@app.get`, `@app.post`, `@router.get`, `@app.on_event`, `@app.middleware`, etc.
93
+
- Django: `@admin.register`, `@receiver`, `@login_required`, etc.
94
+
95
+
**Layer 2c — Dynamic import detection:**
96
+
97
+
Files in the same package as `importlib.import_module()` or `__import__()` calls automatically receive a reduced confidence score (capped at 0.4), since they may be loaded dynamically at runtime.
98
+
79
99
**Layer 3 — Confidence scoring with git metadata:**
80
100
81
101
This is where it gets interesting. A file with zero importers might be dead, or it might be actively used via dynamic loading. Git history helps distinguish:
0 commit comments