@abdulmunimjemal/codescope 0.1.0 → 0.3.0

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.
package/README.md CHANGED
@@ -28,15 +28,20 @@ a changed file in **~0.5 ms** — roughly **3,000× cheaper than a full re-index
28
28
 
29
29
  ## How it compares to codegraph
30
30
 
31
- If you know [codegraph](https://github.com/colbymchenry/codegraph) (~35k★): it's
32
- the mature, feature-rich option 20+ languages, impact/test-affected analysis, a
33
- task-context builder, agent auto-install and it already does incremental
34
- indexing and file-watching. **codescope doesn't try to out-feature it.** In a
35
- measured head-to-head ([BENCHMARKS.md](./BENCHMARKS.md)) codescope's edge is being
36
- **leaner**: ~3× smaller index DB and faster pure indexing on the same repo, a
37
- ~1k-LOC auditable codebase, and zero-config `npx codescope mcp .`. Pick codescope
38
- if you want something small, fast, and easy to read; pick codegraph if you want
39
- the deepest feature set and widest language coverage.
31
+ [codegraph](https://github.com/colbymchenry/codegraph) (~35k★) is the mature
32
+ incumbent and shares codescope's architecture. In a **measured head-to-head**
33
+ ([BENCHMARKS.md](./BENCHMARKS.md), both tools run on the same repos), codescope
34
+ **wins the efficiency axes**:
35
+
36
+ - **~4× faster indexing** (696 ms vs 2,855 ms on a 262-file repo; 5.2 s vs 20 s on 3,500 files).
37
+ - **3–5× smaller index** on disk (2.5 MB vs 8.2 MB; 22.9 MB vs 112.8 MB).
38
+ - **Fewer tokens per answer** for definition lookups on every repo tested; callers is ≈parity.
39
+ - **Feature parity:** `callers`, `callees`, `impact`, `context`, **`affected`** (test-impact), and **`install`** (agent auto-wiring) — plus **20 languages**.
40
+
41
+ codegraph still leads on **maturity & adoption** (35k★, a real user base) and
42
+ indexes a few extra node kinds (constants, properties, routes). Pick codescope
43
+ when footprint, index speed, and token cost matter; pick codegraph for the most
44
+ battle-tested option.
40
45
 
41
46
  ## Install
42
47
 
@@ -50,11 +55,20 @@ collides with an existing package; the installed command is still `codescope`.)
50
55
 
51
56
  ## Quick start
52
57
 
53
- Point your agent at codescope as an MCP server. It indexes the repo, starts
54
- watching for changes, and serves the graph over stdio:
58
+ The one-liner wire codescope into your agents automatically, from your repo:
59
+
60
+ ```bash
61
+ npx @abdulmunimjemal/codescope install # adds codescope to Claude Code + Cursor
62
+ ```
63
+
64
+ That writes the MCP server config (non-destructively) so your agent launches
65
+ codescope on the repo. Restart the agent and you're done. `--agent claude|cursor`
66
+ targets one; `--global` writes to your home dir instead of the project.
67
+
68
+ Prefer to wire it by hand? The server command is:
55
69
 
56
70
  ```bash
57
- codescope mcp /path/to/your/repo
71
+ codescope mcp /path/to/your/repo # index, watch, and serve over stdio
58
72
  ```
59
73
 
60
74
  **Claude Code** (`.mcp.json` or `claude mcp add`):
@@ -77,6 +91,10 @@ codescope index . # build the graph, print stats
77
91
  codescope search useState # fuzzy symbol search
78
92
  codescope get GraphStore # jump to a definition
79
93
  codescope callers parseSource # who calls this
94
+ codescope callees indexAll # what it calls
95
+ codescope impact GraphStore # blast radius before a change
96
+ codescope context "auth flow" # ranked relevance map for a task
97
+ codescope affected src/store.ts # which tests are affected by a change
80
98
  codescope neighborhood handleRequest --depth 3
81
99
  codescope watch . # keep the graph fresh, log updates
82
100
  ```
@@ -87,7 +105,10 @@ codescope watch . # keep the graph fresh, log updates
87
105
  |------|-----------------|
88
106
  | `search_symbols(query, kind?, limit?)` | fuzzy substring search over definitions — use instead of grep/glob |
89
107
  | `get_symbol(name, limit?)` | jump to a definition by exact name (kind, `file:line`, signature) |
90
- | `find_callers(name, limit?)` | who calls this function/method |
108
+ | `find_callers(name, limit?)` | who calls this function/method (distinct callers) |
109
+ | `find_callees(name, limit?)` | what this symbol calls — its outgoing dependencies |
110
+ | `impact(name, depth?, limit?)` | transitive callers (blast radius) before you change something |
111
+ | `context(query, maxSymbols?)` | a ranked relevance map for a task — matches + neighbours, the fastest way to orient |
91
112
  | `find_references(name, kind?, limit?)` | all calls + imports of a name |
92
113
  | `file_outline(path)` | every symbol in a file, in order — a compact alternative to reading it |
93
114
  | `neighborhood(name, depth?, limit?)` | the call neighbourhood (callers + callees) around a symbol, as a subgraph |
@@ -119,7 +140,10 @@ The index lives in `.codescope/graph.db` (add `.codescope/` to your
119
140
 
120
141
  ## Languages
121
142
 
122
- TypeScript, JavaScript, TSX/JSX, Python, Go, Rust, Java, Ruby, C, C++, C#, PHP.
143
+ 20 languages: TypeScript, JavaScript, TSX/JSX, Python, Go, Rust, Java, Ruby, C,
144
+ C++, C#, PHP, Scala, Solidity, Zig, Kotlin, Objective-C, Lua, Bash, and OCaml.
145
+ Definition extraction (functions, classes, methods, …) works for all; call and
146
+ import edges are available for the languages whose grammars expose them.
123
147
 
124
148
  ## Programmatic API
125
149