
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
Knocoph is a local MCP server that parses TypeScript and JavaScript codebases into a persistent knowledge graph stored in SQLite.
Knocoph (nok-of) is a local MCP server that transforms TypeScript and JavaScript codebases into a persistent code knowledge graph stored in SQLite.
Instead of AI assistants greedily reading entire files and burning context tokens, Knocoph enables structural codebase navigation through deterministic graph queries. Navigate call chains, import graphs, inheritance hierarchies, and symbol dependencies with near-instant responses and minimal token consumption.
Install globally so the knocoph command is available in PATH:
npm install -g knocoph
Add Knocoph to your MCP client configuration (e.g. .mcp.json, claude_desktop_config.json):
{
"servers": {
"knocoph": {
"type": "stdio",
"command": "knocoph",
"env": {
"knocoph_DB": "./.knocoph/graph.db",
"knocoph_ROOT": "."
}
}
}
}
Both env variables are optional — Knocoph uses sensible defaults if they are omitted:
| Variable | Default | Description |
|---|---|---|
knocoph_DB | ./.knocoph/graph.db | Path to the SQLite database file. Relative paths resolve from the working directory (the project root). |
knocoph_ROOT | . | Root directory to auto-index on first run (before any index_project call). Relative paths resolve from the working directory. |
Minimal configuration with defaults (no env block required):
{
"servers": {
"knocoph": {
"type": "stdio",
"command": "knocoph"
}
}
}
To guide your AI assistant (Claude, Copilot, etc.) to use Knocoph MCP tools effectively instead of reading files directly, copy the instructions from MCP_USAGE.md into your AI assistant's system prompt, AGENTS.md, CLAUDE.md or equivalent configuration file.
These instructions teach AI to:
find_symbol before opening filesexplain_impact before making changesget_snippet to fetch exact code ranges rather than entire filesThis approach minimizes token consumption and provides fast, accurate structural answers.
tsconfig.json to resolve @scope/... style imports| Tool | Purpose |
|---|---|
codebase_overview | Get structural summary of entire codebase (files, symbols, kind distribution) |
find_symbol | Locate any symbol by name; optionally include source code snippet |
get_neighbors | Explore incoming/outgoing relationships by symbol name or ID |
get_snippet | Fetch exact source code snippet for a symbol or line range |
explain_impact | Blast radius and dependency analysis; understand why a symbol exists |
query_architecture | File-level view — what symbols does a file define and import/export? |
index_project | Trigger or refresh graph indexing; auto-detects tsconfig.json for path aliases |
If your project uses compilerOptions.paths in tsconfig.json (e.g. @myapp/*, @auth), Knocoph resolves them automatically. When index_project is called, it looks for tsconfig.json in the project root and reads compilerOptions.paths and baseUrl to resolve aliased imports to their real file paths.
No configuration needed for the standard setup:
// tsconfig.json
{
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@myapp/*": ["src/*"], // @myapp/utils → src/utils.ts
"@auth": ["src/auth/index.ts"],
},
},
}
If your tsconfig.json is not at the project root, pass the path explicitly:
index_project { root_dir: ".", tsconfig_path: "./packages/app/tsconfig.json" }
Supported patterns: simple prefix wildcards (@scope/*) and exact matches (@auth). Only the first replacement in each array is used. Complex multi-wildcard patterns are skipped.
# Install globally
npm install -g knocoph
# Run tests (contributors)
npm run test:ci
# Format and lint (contributors)
npm run prettier
npm run lint
FAQs
Knocoph is a local MCP server that parses TypeScript and JavaScript codebases into a persistent knowledge graph stored in SQLite.
The npm package knocoph receives a total of 10 weekly downloads. As such, knocoph popularity was classified as not popular.
We found that knocoph demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.