Skip to content

Releases

v1.1.0: Much better call coverage, and --exclude-tests

Choose a tag to compare

@RuchiPurohit RuchiPurohit released this 23 Oct 01:51
685c161

Codeskope now finds far more of the calls in a typical TypeScript codebase. On a 176-file Express backend, call edges went from 94 to 1,462. A new --exclude-tests option keeps test helpers from crowding out results.

Highlights

Much better call coverage

  • Arrow functions are indexed. Functions written as const handler = async () => {}, const f = function () {} or class fields like handle = () => {} are now symbols. Previously, codebases written in this style were mostly missing from the graph.
  • Calls inside callbacks count. A call inside .map(...), a promise chain, or a test's it(...) is credited to the surrounding named function. Calls in constructors are credited to their class. Top-level code is credited to its file.
  • Type-annotated variables resolve. A call to const handler: Handler = ... now finds handler itself, not just its type.

--exclude-tests

Test code often calls shared helpers (fixtures, seeders, app factories) more than your application does, so those helpers can dominate dependents and impact results. To index application code only:

codeskope index . --exclude-tests

This leaves out *.test.ts(x) and *.spec.ts(x) files and anything under __tests__, __mocks__, test or tests. The setting is saved in the index, so codeskope update keeps it. Run index without the flag to bring tests back.

  • MCP: start the server with codeskope-mcp --root . --exclude-tests. refresh_index now reports excludeTests in its output.
  • Visualization: a new Exclude tests checkbox under Scope hides test files from the interactive graph without re-indexing.

Fixes

  • Global installs work. npm i -g codeskope no longer crashes on startup with "Cannot find package 'typescript'".
  • Indexing from another directory works. codeskope index /path/to/project run from a different directory now picks up the project's @types. Before, you got inflated compiler errors and missing calls.
  • No more duplicate-name crash. Files where the same name is declared twice (block-scoped helpers, overload signatures) no longer fail with "Node already exists".

Breaking changes

  • Diagnostic names changed.
    • external-call is now unindexed-target. It means the callee is in your project but isn't something Codeskope indexes. Calls to libraries were never reported, and still aren't.
    • unmodeled-caller is removed. Every call Codeskope resolves now has a caller.
    • If you filter diagnostics by kind, update those names.
  • A caller can be a file. dependents, impact and the MCP relationship tools can return a file as a caller. That means top-level code in that file calls the symbol, for example module setup or test bodies. If your code assumes every caller is a function or method, handle file nodes too.

Upgrading

npm install --save-dev codeskope@2   # or: pnpm add -D codeskope@2
codeskope index .                    # rebuild the index to get the new coverage

Indexes from 1.x still load, but they don't have the new call coverage until you rebuild them with index.

v1.0.0: Codegraph is now Codeskope

Choose a tag to compare

@RuchiPurohit RuchiPurohit released this 23 Oct 00:06
df80345

Codegraph has been renamed to Codeskope. This is the first release under the new name, published on npm as codeskope. The old repo-codegraph package is deprecated.

Install

npm install --save-dev codeskope # npm
pnpm add -D codeskope # pnpm

Breaking changes

Everything that used the old name now says codeskope:

Before Now
npm package repo-codegraph codeskope
CLI command codegraph codeskope
MCP server command codegraph-mcp codeskope-mcp
MCP server name codegraph codeskope
Index folder .codegraph/ .codeskope/
Index format tag "codegraph" "codeskope"

The library's TypeScript names, such as CodeGraph and createCodeGraphMcpServer, are unchanged.

Migrating from repo-codegraph

  1. Swap the package:
    npm uninstall repo-codegraph && npm install --save-dev codeskope

    or: pnpm remove repo-codegraph && pnpm add -D codeskope

  2. Update your MCP client config. Replace codegraph-mcp with codeskope-mcp, and rename the server entry from codegraph to codeskope. For example:
    claude mcp add codeskope --scope project -- npx --no-install codeskope-mcp --root .
  3. Rebuild the index. Old .codegraph/index.json files can't be read by this version.
    npx codeskope index . # or: pnpm codeskope index .
    You can then delete .codegraph/ and replace it with .codeskope/ in your .gitignore.
  4. Update any scripts that call codegraph so they call codeskope.

Also in this release

  • The README shows every CLI command for both npm and pnpm.
  • npm publish now builds the package first, so a release can't ship stale files.

The fixes from 0.2.2 are included too: the commands now work when installed with pnpm or npm link, and the MCP server reports the package's real version.

v0.2.2: Fix silent exit under pnpm

Choose a tag to compare

@RuchiPurohit RuchiPurohit released this 22 Oct 23:27
335d015

Fixes

  • codegraph and codegraph-mcp now run when installed with pnpm or npm link. In 0.2.1 and earlier, both commands exited silently with code 0 when started through a symlinked bin. They printed nothing and wrote no index. The entry-point check now compares real paths, so symlinked installs work.
  • The MCP server reports the correct version. serverInfo.version was hardcoded to 0.1.0. It now comes from the package version.

Documentation

  • The install command now uses the correct package name. The README said npm install --save-dev codegraph, which installs an unrelated package. It now says repo-codegraph.
  • The CLI section shows every command for both npm and pnpm. A new table lists each command with what it does, its npx codegraph … form and its pnpm codegraph … form.

Upgrading

npm install --save-dev repo-codegraph@0.2.2 # npm
pnpm add -D repo-codegraph@0.2.2 # pnpm

If you're on pnpm v10, run pnpm codegraph index . without a --. pnpm v10 passes -- to the command as a literal argument.

Codegraph v0.2.1 - Interactive Network Visualization

Choose a tag to compare

@RuchiPurohit RuchiPurohit released this 21 Oct 19:48
b4a8677

Highlights

Codegraph v0.2.1 introduces an interactive, local-first network visualization for exploring the files, symbols, and relationships in a TypeScript repository.

What’s new

  • Interactive force-directed graph of indexed files and symbols.
  • Visual representation of DEFINES, IMPORTS, and CALLS relationships.
  • Search for files and symbols.
  • Zoom, pan, graph fitting, relationship filters, and neighborhood focus.
  • Hover labels for graph nodes.
  • Color legends for files, functions, classes, interfaces, and methods.
  • Ask Codegraph interface for deterministic repository questions.
  • Change-impact questions that identify callers and potentially affected symbols.
  • Clickable results that open the relevant source file and location.
  • Local visualization server bound to 127.0.0.1.
  • Self-contained HTML export for IDE previews.
  • Programmatic visualization APIs.
  • Automatic npm publishing when a matching GitHub release is published.

Usage

Index a repository:

npx codegraph index .

Open the interactive network:

npx codegraph visualize .

Export the visualization for an IDE HTML preview:

npx codegraph visualize . --output .codegraph/visualization.html

Start the viewer without automatically opening a browser:

npx codegraph visualize . --no-open

Use a custom port:

npx codegraph visualize . --port 5173

Ask Codegraph examples

  • Where is ProjectSession defined?
  • What calls analyzeProject?
  • What does runCli call?
  • What imports server.ts?
  • When I change analyzeImpact, which symbols may be affected?

Questions are answered locally using the indexed graph. Repository data is not sent to an external language model.

Installation

Install the package as a development dependency:

npm install --save-dev repo-codegraph@0.2.1

The package provides two executables:

  • codegraph for indexing, querying, and visualization.
  • codegraph-mcp for integration with MCP-compatible coding agents.

Validation

  • TypeScript checks passed.
  • Production build passed.
  • 57 tests passed.
  • One local-port test was skipped because the validation sandbox does not permit binding a local port.
  • The release diff passed whitespace validation.

Codegraph v0.2.0 — Interactive Network Visualization

Choose a tag to compare

@RuchiPurohit RuchiPurohit released this 21 Oct 19:19
4d15d67

Highlights

Codegraph v0.2.0 introduces an interactive, local-first network visualization for exploring the files, symbols, and relationships in a TypeScript repository.

What’s new

  • Interactive force-directed graph of indexed files and symbols.
  • Visual representation of DEFINES, IMPORTS, and CALLS relationships.
  • Search for files and symbols.
  • Zoom, pan, graph fitting, relationship filters, and neighborhood focus.
  • Hover labels for graph nodes.
  • Color legends for files, functions, classes, interfaces, and methods.
  • Ask Codegraph interface for deterministic repository questions.
  • Change-impact questions that identify callers and potentially affected symbols.
  • Clickable results that open the relevant source file and location.
  • Local visualization server bound to 127.0.0.1.
  • Self-contained HTML export for IDE previews.
  • Programmatic visualization APIs.
  • Automatic npm publishing when a matching GitHub release is published.

Usage

Index a repository:

npx codegraph index .

Open the interactive network:

npx codegraph visualize .

Export the visualization for an IDE HTML preview:

npx codegraph visualize . --output .codegraph/visualization.html

Start the viewer without automatically opening a browser:

npx codegraph visualize . --no-open

Use a custom port:

npx codegraph visualize . --port 5173

Ask Codegraph examples

  • Where is ProjectSession defined?
  • What calls analyzeProject?
  • What does runCli call?
  • What imports server.ts?
  • When I change analyzeImpact, which symbols may be affected?

Questions are answered locally using the indexed graph. Repository data is not sent to an external language model.

Installation

Install the package as a development dependency:

npm install --save-dev repo-codegraph@0.2.0

The package provides two executables:

  • codegraph for indexing, querying, and visualization.
  • codegraph-mcp for integration with MCP-compatible coding agents.

Validation

  • TypeScript checks passed.
  • Production build passed.
  • 57 tests passed.
  • One local-port test was skipped because the validation sandbox does not permit binding a local port.
  • The release diff passed whitespace validation.