clast-ai 0.2.2 → 0.2.4

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.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clast",
3
- "version": "0.2.2",
3
+ "version": "0.2.4",
4
4
  "description": "Code index for coding agents: symbol search, exact symbol source, type-aware call graph, references, type hierarchy, change impact, dead code and exact counts for any repository. TypeScript, JavaScript, Python, Java, C#, Go, Rust, C, C++, Ruby, PHP, Swift and Dart.",
5
5
  "author": {
6
6
  "name": "Thomas"
package/CHANGELOG.md ADDED
@@ -0,0 +1,112 @@
1
+ # Changelog
2
+
3
+ ## 0.2.4
4
+
5
+ - The server instructions and the usage skill tell the agent not to use clast for a rename or a
6
+ signature change of a distinctive name (one grep finds every site). In the refactor benchmark the
7
+ clast sessions had made about three extra calls on such tasks; after the change they make none
8
+ (8.3 calls against 8.3 for plain grep on OnAir).
9
+
10
+ ## 0.2.3
11
+
12
+ - `clast-ai guide` prints the usage guide (the Claude Code plugin's `explore` skill) as Markdown,
13
+ for agents that take their instructions from a file: `clast-ai guide >> AGENTS.md`.
14
+ - Checked with other agents: Codex CLI 0.167 starts the server (`codex mcp add clast -- clast-ai`,
15
+ also through `npx`) and calls the tools in a session; Gemini CLI connects to it. Install steps for
16
+ both are in the README.
17
+ - README rewritten; the changelog and the full benchmark tables moved to `CHANGELOG.md` and
18
+ `docs/benchmarks.md`.
19
+
20
+ ## 0.2.2
21
+
22
+ - The clean-up of older installs also finds servers registered as `node .../dist/server/index.js` (how
23
+ the 0.1 README registered a build from source) and reads the configuration from `CLAUDE_CONFIG_DIR`
24
+ when that is set. Both were found by installing the plugin into an empty configuration next to an
25
+ old-style registration.
26
+
27
+ ## 0.2.1
28
+
29
+ - `clast-ai migrate`: finds and removes what older installs left behind (duplicate MCP registrations
30
+ next to the plugin, entries written by the old VS Code extension, the v0.1 index file). The plugin
31
+ runs it automatically, once per version, at the first session after an install or update.
32
+ - The plugin uses a global `clast-ai` only when it is at least as new as the plugin itself, so a
33
+ plugin update is not held back by an older global install.
34
+
35
+ ## 0.2.0
36
+
37
+ New tools (7 to 13):
38
+
39
+ - `clast_references`: every use of a symbol, not just calls.
40
+ - `clast_hierarchy`: supertypes, subtypes, implementers and overrides, including Go structural
41
+ interfaces and Ruby mixins.
42
+ - `clast_overview`: map of a repository or directory.
43
+ - `clast_grep`: text search over all text files with the enclosing symbol on every hit.
44
+ - `clast_changes`: symbols touched by a git diff, plus their callers.
45
+ - `clast_impact`: for one symbol, what has to change with it (declarations, overrides, implementations,
46
+ overloads), every direct caller by file and line, the reach through indirect callers, and the test
47
+ files to run, including tests that only reach it through its callers.
48
+ - `clast_unused`: dead code. A name counts as unused when it is never referenced outside its own
49
+ definitions, or only from other unused code (so a deleted feature's helpers are found with it).
50
+ Reported separately: code used only by tests, names that still appear in a string, config or
51
+ template, and (Java, C#, C, C++, Rust) methods whose every call binds to another definition. Left
52
+ out, with counts: entry points, decorated or attribute-marked symbols, subclasses of library types
53
+ and their methods, object-literal members, exported Go methods, C# extension classes.
54
+ - `clast_stats`: exact counts grouped by directory, file, kind or name: inventory, symbols by name
55
+ pattern, direct and indirect subtypes, call sites by name and receiver, text matches, external
56
+ dependencies, and pattern-based inventories of HTTP / RPC endpoints and database access.
57
+
58
+ Call graph:
59
+
60
+ - Calls are resolved at query time using declared receiver types, imports and aliases, field types
61
+ across files, return types of call chains, inheritance and `super`.
62
+ - Edges are shown as certain, uncertain, or `?` (matched by name only).
63
+ - Argument counts separate overloads. A bare name means all overloads; `path:line` selects one.
64
+ - A call bound to a subclass override no longer counts as a caller of the base method.
65
+ - Language rules: Go packages and structural interfaces, Rust `impl Trait for Arc<T>` and std types,
66
+ C# generic arity / partial / static classes, Ruby mixins and bare calls, Java static imports, Python
67
+ submodule calls and imported instances, TypeScript renamed re-exports, C macro bodies, C++ namespace
68
+ functions.
69
+
70
+ Search:
71
+
72
+ - Ranked by exact name, prefix, abbreviation, typo and plain words.
73
+ - Descriptive queries also match what function bodies mention (marked `[body]`).
74
+ - Overloads fold into one hit.
75
+
76
+ Performance and storage:
77
+
78
+ - `node:sqlite` on disk (WAL, FTS5) replaces in-memory sql.js.
79
+ - Parsing runs in worker threads, with an inline fallback if a worker fails.
80
+ - The server connects first and indexes afterwards; on a first build, tools wait for the index.
81
+ - A watcher re-indexes changed files, and every tool re-checks the files it quotes.
82
+
83
+ Other:
84
+
85
+ - Swift and Dart added (14 languages).
86
+ - All dependencies updated (MCP SDK 1.32, web-tree-sitter 0.27).
87
+ - 291 tests, plus `bench/bench.mjs`, `bench/resolution.mjs` and the A/B harness `bench/ab.mjs`.
88
+ - Installable as a Claude Code plugin from this repository (`/plugin marketplace add xls/clast`,
89
+ `/plugin install clast@clast`): the MCP server, a usage skill, and the slash commands
90
+ `/clast:deadcode`, `/clast:impact`, `/clast:audit` and `/clast:status`. The old VS Code extension
91
+ scaffold that wrote the server into `.claude/settings.local.json` is removed.
92
+ - The navigation tools ask Claude Code to keep them loaded instead of deferring them behind tool
93
+ search; deferred, the agent never called them.
94
+ - Ruby classes and their ancestors are compared by qualified name (`Rails::Generators::Base` is not
95
+ `ActiveRecord::Base`; `Thor::Group` is not a project class called `Group`).
96
+ - C++ functions declared through a head-building macro (`FN(jstring, nativeStart)(args)`) are indexed
97
+ under their real name.
98
+ - C / C++ function pointers whose calling convention is a macro (`err_t (MY_CALL* find)(args)`) are
99
+ indexed as a field called `find`, not as a method called `err_t`.
100
+
101
+ ## Upgrading from 0.1
102
+
103
+ How to upgrade: see [Upgrading from an older install](README.md#coming-from-an-older-install). What changed:
104
+
105
+ - Node.js 22.22+ is required (was 18).
106
+ - The index moved from `.clast/clast.db` (sql.js) to `.clast/index.db` (`node:sqlite`). Nothing is
107
+ migrated: the index is a cache and is rebuilt on first start. The old file is ignored; the plugin
108
+ (or `clast-ai migrate --apply`) deletes it.
109
+ - A later schema change deletes and rebuilds the index automatically (the schema is at version 26).
110
+ - Tool output is compact text instead of JSON.
111
+ - `clast_call_graph` defaults to depth 1 and gained `within` and `includeTests`.
112
+ - The binary entry point is `dist/cli.js`; `dist/server/index.js` still starts the server for old configs.