MCPcopy Index your code
hub / github.com/apmantza/pi-lens

github.com/apmantza/pi-lens @v3.8.65

Chat with this repo
repository ↗ · DeepWiki ↗ · release v3.8.65 ↗ · + Follow
3,632 symbols 11,763 edges 661 files 534 documented · 15%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

pi-lens

pi-lens

pi-lens gives AI coding agents fast, language-aware feedback while they write/edit.

What It Does

  • LSP diagnostics and navigation across supported languages
  • Impact cascade diagnostics that show which related files were affected and run LSP diagnostics on them
  • Language-specific linters, type-checkers, and scanners on every write/edit
  • Safe formatting/autofix where tools are configured or confidently detected
  • ast-grep and tree-sitter structural rules for correctness/security smells
  • Agent-facing tools for LSP navigation/diagnostics, AST search/replace, diagnostics state, and project intelligence
  • Review-graph intelligence for supported languages via bundled tree-sitter WASMs
  • Read-guard and edit-autopatch support to reduce bad edits
  • Background security/dependency scans for opted-in projects

Install

pi install npm:pi-lens

Or from git:

pi install git:github.com/apmantza/pi-lens

Documentation

Contributing

See CONTRIBUTING.md for the development workflow, runner, LSP, formatter, and rule checklists, and issue/PR conventions.

Security issues should be reported privately; see SECURITY.md. pi-lens is released under the MIT License.

Contributors

Thanks goes to these wonderful people:

wastedC 💻 🤔 🚧 👀 Apostolos Mantzaris 💻 📖 🤔 🚧 👀 Dependabot 🚧 silvanshade 💻 Anh Chu 💻 Ruben Paz 💻 🐛 Tifan Dwi Avianto 💻
Ricardo Raposo 💻 C.Junxiang 💻 🐛 Chenxin Yan 💻 📖 🐛 Chris Patti 💻 🐛 Fractiunate // David Rahäuser 💻 Heitor Ramon Ribeiro 💻 JayceFreeman 💻
Max L. 💻 Roman Galeev 💻 Will Mitchell 💻 Amit 💻 🐛 flowing-abyss 💻 jerryfan 💻 minicx 💻
spyrosbazios 💻 Trevon 💻 Carolina 🐛 LeakedBy 🐛 Matthew Booth 🐛 Wiedzmin89 🤔 Virgile 🐛
Finn 🤔 Wayne E 🐛 RimuruW 🤔 Bjynt 🐛 🤔 Tri Van Pham 🐛 BingWuJ 🐛 tackleberrybey 🐛
Mariann Abshire 🐛 ProbabilityEngineer 🤔 Leonardo Rick 🐛 🤔

Extension points exported contracts — how you extend this code

ResolvedCollectionConfig (Interface)
* Recursively collect all source files in a directory, excluding build artifacts * and likely generated/codegen artifac
clients/source-filter.ts
DeadCodeClient (Interface)
(no doc) [2 implementers]
clients/dead-code-client.ts
ReadonlyFactStore (Interface)
(no doc) [2 implementers]
clients/dispatch/fact-store.ts
CompactResultLike (Interface)
(no doc)
tools/render-compact.ts
TSIssue (Interface)
(no doc)
commands/booboo.ts
GrammarManifest (Interface)
(no doc)
scripts/download-grammars.ts
FixtureManifest (Interface)
(no doc)
tests/real-bug-fixtures.test.ts
MockRunnerConfig (Interface)
(no doc)
tests/mocks/runner-factory.ts

Core symbols most depended-on inside this repo

push
called by 1212
clients/knip-client.ts
get
called by 399
clients/dispatch/types.ts
setupTestEnvironment
called by 324
tests/clients/test-utils.ts
replace
called by 309
clients/ast-grep-client.ts
createTempFile
called by 272
tests/clients/test-utils.ts
log
called by 268
clients/dispatch/types.ts
set
called by 256
clients/cache/rule-cache.ts
dbg
called by 210
index.ts

Shape

Function 2,427
Method 652
Interface 435
Class 115
Struct 2
Enum 1

Languages

TypeScript99%
Python1%
Go1%
Java1%
Rust1%
PHP1%

Modules by API surface

clients/lsp/client.ts120 symbols
clients/lsp/index.ts74 symbols
clients/tool-policy.ts63 symbols
clients/runtime-coordinator.ts61 symbols
clients/review-graph/builder.ts59 symbols
clients/module-report.ts59 symbols
clients/installer/index.ts58 symbols
clients/lsp/server.ts54 symbols
scripts/analyze-pi-lens-logs.mjs53 symbols
clients/widget-state.ts44 symbols
clients/tree-sitter-client.ts44 symbols
clients/read-guard.ts42 symbols

Datastores touched

dbDatabase · 1 repos

For agents

$ claude mcp add pi-lens \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact