phpgraph
What it does
PHP code graph for AI agents: impact of a change, feature outlines, handlers, routes, layer rules
- Connects Se ejecuta en tu computadora
- Account or key No key needed
- Category Búsqueda y memoria de IA
Instalación
Elige la app de IA que usas y copia la configuración.
Pasó 3/3 revisiones · Funciona en tu computadora · ✓ Comandos revisados el 14 nov 2026
Primero: ¿qué IA usas?
Elige tu app y los pasos aparecen abajo.
Funciona con Claude, pero hay que preparar algo antes
Instala Docker en tu computadora primero (una sola vez) · Solo en la app de Claude para computadora (Windows o Mac), no en la web ni en el móvil
Instala Docker
Una sola vez; sirve para todos los servidores que necesitan Docker
Abre el archivo de configuración de la app de Claude de escritorio
SettingsDeveloperEdit Config
Pega esta configuración y guarda el archivo
{ "mcpServers": { "phpgraph": { "command": "docker", "args": [ "run", "-i", "--rm", "ghcr.io/hbenabdallah/phpgraph:2.1.0" ] } } }Cierra Claude y vuelve a abrirlo
Pruébalo
Usa phpgraph y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si Claude dice que está usando phpgraph o muestra una herramienta de phpgraph en la respuesta, ya está conectado
Nombres de menú comprobados con la ayuda de Anthropic el 11 nov 2026 · tu pantalla puede variar un poco según la versión
ChatGPT todavía no puede conectar phpgraph
phpgraph se instala en tu computadora, pero ChatGPT solo conecta servidores que funcionan en la web
Lo que puedes hacer en su lugar
A · Usa una app que pueda conectar phpgraph
- Instala Docker en tu computadora primero (una sola vez) · Solo en la app de Claude para computadora (Windows o Mac), no en la web ni en el móvil
- Instala Docker en tu computadora primero (una sola vez)
- Instala Docker en tu computadora primero (una sola vez)
- Instala Docker en tu computadora primero (una sola vez)
Funciona con Claude Code, pero hay que preparar algo antes
Instala Docker en tu computadora primero (una sola vez)
Instala Docker
Una sola vez; sirve para todos los servidores que necesitan Docker
Abre la Terminal
Mac: pulsa Command+Espacio y escribe Terminal · Windows: abre PowerShell
Pega este comando y pulsa Enter
claude mcp add --scope user phpgraph -- docker run -i --rm ghcr.io/hbenabdallah/phpgraph:2.1.0Escribe /mcp en Claude Code
Deberías ver phpgraph en la lista como conectado
Pruébalo
Usa phpgraph y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si Claude Code dice que está usando phpgraph o muestra una herramienta de phpgraph en la respuesta, ya está conectado
Nombres de menú comprobados con la ayuda de Anthropic el 11 nov 2026 · tu pantalla puede variar un poco según la versión
Funciona con Cursor, pero hay que preparar algo antes
Instala Docker en tu computadora primero (una sola vez)
Instala Docker
Una sola vez; sirve para todos los servidores que necesitan Docker
Abre el chat de IA de Cursor en modo Agent
Pruébalo
Usa phpgraph y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si Cursor dice que está usando phpgraph o muestra una herramienta de phpgraph en la respuesta, ya está conectado
Nombres de menú comprobados con la ayuda de Cursor el 11 nov 2026 · tu pantalla puede variar un poco según la versión
Funciona con VS Code, pero hay que preparar algo antes
Instala Docker en tu computadora primero (una sola vez)
Instala Docker
Una sola vez; sirve para todos los servidores que necesitan Docker
Abre el chat de IA de VS Code en modo Agent
Pruébalo
Usa phpgraph y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si VS Code dice que está usando phpgraph o muestra una herramienta de phpgraph en la respuesta, ya está conectado
Nombres de menú comprobados con la ayuda de VS Code el 11 nov 2026 · tu pantalla puede variar un poco según la versión
Otras apps que usan MCP, como Windsurf, Zed o Gemini CLI, añaden servidores de forma distinta. Míralo en la lista de apps
Ver todas las apps que usan MCP →
La configuración JSON está en “Para desarrolladores”, abajo
Para desarrolladores: comandos de Terminal y configuración JSON
Instalado en tu computadora
Claude Code
claude mcp add --scope user phpgraph -- docker run -i --rm ghcr.io/hbenabdallah/phpgraph:2.1.0Claude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"phpgraph": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/hbenabdallah/phpgraph:2.1.0"
]
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"phpgraph": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/hbenabdallah/phpgraph:2.1.0"
]
}
}
}VS Code (mcp.json)
{
"servers": {
"phpgraph": {
"type": "stdio",
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/hbenabdallah/phpgraph:2.1.0"
]
}
}
}Esta configuración se genera a partir de la ficha del creador en el registro. Si el README dice otra cosa, sigue el README.
De un vistazo
- Descargas por semanai
- No está en npm/PyPI
- Conexión
- Se ejecuta en tu computadora
- Última versióni
- 2.1.0
- Categoríai
- Búsqueda y memoria de IA
- Publicado en el registroi
- 14 nov 2026
- Último cambio de códigoi
- 14 nov 2026
- Creador
- hbenabdallah
- Paquetes
oci: ghcr.io/hbenabdallah/phpgraph:2.1.0- Estado en el registro
- Activo
Qué apps pueden usarlo
Según cómo se conecta este servidor y la documentación de cada app, comprobado el 10 nov 2026.
Se ejecutan en tu computadora en
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
Qué puede hacer
Se ejecuta en tu computadora; la lista de herramientas aparece en tu app de IA después de instalarlo.
Revisiones básicasi
Revisamos información que cualquiera puede ver; no hemos leído el código. Las revisiones que no aplican no se cuentan. · Revisado el 14 nov 2026
- ✓ Superada
El creador coincide con el repo
El nombre en el registro se verificó con la cuenta de GitHub hbenabdallah, dueña del repo
- ✓ Superada
Sigue en mantenimiento
Último cambio de código: hoy
- ✓ Superada
Tiene licencia
Usa MIT
- – No aplica
El endpoint responde
Este se ejecuta en tu computadora; no hay endpoint en internet
- – No aplica
Inicio de sesión con OAuth
Se ejecuta en tu computadora y usa ajustes locales en su lugar
- … Aún sin revisar
Sin instrucciones ocultas en las descripciones de herramientas
Se ejecuta en tu computadora; solo podemos leer listas de herramientas de endpoints en internet
Conversación
Pregunta, comparte un consejo o avisa de que no funciona. Ordenado por lo que la gente marcó como útil.
Aún no hay publicaciones. Sé la primera persona en preguntar o compartir.
Lo publicado aquí lo escriben usuarios, no el equipo de PopNx.
Reseñas de usuarios
Aún no hay reseñas
Comparado con otros en Búsqueda y memoria de IAi
- Más estrellas que el 85% de los otros 6109 servidores de esta categoría
- Publicado en el registro más recientemente que el 98% de los otros 6109 servidores de esta categoría
- Revisiones básicas iguales o mejores que el 100% de los otros 6109 servidores de esta categoría
Comparado con todos los servidores activos de esta categoría en el registro. Las estrellas solo cuentan cuando quien lo publica es dueño del repo.
Preguntas frecuentes
¿Es seguro phpgraph?
Superó 3 de 3 revisiones básicas aplicables. No hemos leído el código. Antes de agregar una clave o un token, revisa qué acceso pide el servidor y usa una clave que tenga solo los permisos que necesitas.
¿Qué claves o códigos necesita?
El registro no indica ninguna clave obligatoria, aunque algunos servidores te piden iniciar sesión la primera vez que los usas.
¿Se ejecuta en mi computadora o en la nube?
Se ejecuta en tu computadora. Tu app de IA lo inicia cuando hace falta, y los datos no pasan por los servidores del creador (a menos que el propio servidor llame a un servicio en línea).
¿Sigue en mantenimiento?
El repo de GitHub cambió por última vez hoy, y la última versión (2.1.0) llegó al registro hoy.
¿Qué apps pueden usarlo?
Las apps compatibles con MCP, como Claude Desktop, Claude Code, Cursor y VS Code. También necesitas Docker en tu computadora.
¿Qué puedo usar en su lugar?
En la misma categoría: Context7, Codebase Memory, OpenSEO
Otros de la misma categoría
Servidores de la misma categoría hechos por otros creadores, ordenados por estrellas.
Cómo leer una tarjeta:↓ Descargas por semanai★ Estrellas de GitHubiTres pilares: reseñas · revisiones · usoiActualizado = fecha en que se publicó la última versión en el registroi
Codebase Memory
Codebase knowledge graph for AI agents — 162 languages, sub-ms queries, 99% fewer tokens.
OpenSEO
Keyword research, site audits, rank tracking and AI visibility for your AI agent.
README del creador
Abrir el README
Copiado tal cual del repo del creador. PopNx MCP no lo ha revisado ni lo respalda. Se quitaron HTML, imágenes y scripts. Los enlaces llevan fuera de este sitio.
A knowledge graph of your PHP codebase, for AI coding agents.
Static analysis served over MCP to Sherpa , Claude Code, Codex, Cursor and any MCP client.
No LLM, no network, no embeddings: deterministic facts, each with a confidence level.
English · Français
What it answers
An agent in a PHP project it does not know greps names and reads files. That works until the answer goes through something a search of names does not show: an interface, the container configuration, a bus, a route, another service. phpgraph parses the whole project once (with nikic/php-parser, docblocks with phpstan/phpdoc-parser) and answers from a graph, in one call:
- What breaks if I change this method?
impact_oflists every dependent, nearest first, callers through the interface it implements included, the routes reaching it and the tests to run. Sylius, the 17 callers ofOrderItemQuantityModifierInterface::modify(): phpgraph finds 17, codebase-memory-mcp 11 (2 false), graphify 0. - How does this feature work?
outlinegives the classes, the routes running into them, the behaviour read in their bodies, the wiring and the tests in one answer, so the agent reads only the files with non-obvious logic. Claude Code on 6 explain tasks: −12 % tokens, −26 % time, −42 % tool calls. - Which handler receives this message, which controller serves this route? Senders, messages and handlers are linked for Symfony Messenger, Laravel, Ecotone, PrestaShop CQRS, WordPress hooks and your own buses; routes to their controllers, HTTP calls to the routes they reach. Sylius: 206 Messenger handlers linked to their message; Kimai: 266 routes and 26 events with their subscribers; graphify links none. Claude Code wrote the exact class name in 18 of 18 runs with phpgraph, 15 of 18 without (the 3 misses: namespaces guessed from the path).
- Does the code respect its layers?
phpgraph checkfails the CI on a new dependency that breaks the layer rules (domain, application, infrastructure) or the project's own rules inphpgraph.yaml, with a baseline for today's violations. - What crosses the service boundaries? Shared message classes, routing keys, HTTP routes, OpenAPI and protobuf schemas link services together: all 45 operations of StayHub's OpenAPI document and all 14 rpcs of ticket-booking are linked to their implementation; in art-gallery, phpgraph found a
POSTsent to aGET-only route. - Who calls this, in a large or old codebase? Receivers are typed from return types, docblocks, generics, branches and the signatures of
vendor/, and PHP 4 and 5 syntax is parsed: 92.9 to 99.1 % of method calls typed on the 7 main projects of the corpus. On Kimai, phpgraph finds the callers in 2,407 of the 2,408 files a grep finds for methods whose name is declared once, graphify in 902.
How it answers:
- Deterministic facts, not guesses. Every relation is
EXTRACTED(read in the code),INFERRED(resolved from declared types) orAMBIGUOUS(a guess, labelled as such). - It says what it does not know. Unresolved calls, missing
vendor/, messages without handlers: the gaps are reported, so the agent knows when to read the code itself. - Built for DDD and hexagonal architecture, then microservices, then PHP in general: Symfony, Laravel, Ecotone, PrestaShop, WordPress, or plain PHP.
- Private by design. Your code never leaves your machine, and phpgraph never executes it: it only parses it.
What it costs
The same agent with and without phpgraph, scored against answers derived from the code (method and every run):
| Question | Agent and projects | With phpgraph |
|---|---|---|
| Impact of a change | Sherpa, a private 4,800-file Symfony/DDD project, 3 runs | −42 % tokens, −50 % time, −59 % tool calls |
| Impact of a change | Claude Code, 6 tasks on 5 public projects, 3 runs | −1.9 % tokens in total (+18 % with 2.0); Akeneo −51 % |
| Explain a feature | Sherpa, the same private project, 3 runs | −25 % tokens, −34 % time, −49 % tool calls |
| Explain a feature | Claude Code, 6 tasks on 5 public projects, 3 runs | −12 % tokens, −26 % time, −42 % tool calls |
| Find a handler, a controller | Claude Code, 6 tasks on 5 public projects, 3 runs | −7 % tokens, −14 % time, −27 % tool calls |
| Fix a seeded bug | Claude Code, 6 tasks on 4 public projects, 3 runs | not called; +10 % tokens for carrying the server with 2.0, whose tool list is now 4.8 KB instead of 11.2 KB (not measured again) |
On the Sherpa project, the ranges of the runs with and without phpgraph do not overlap; on the public tasks, the run-to-run variance is about 11 %, so a few percent on one task is noise.
Questions whose answer goes through an indirection (a custom command bus, the container configuration, an HTTP path in another service), 4 tasks run once per arm: Claude Code reached the full answer without phpgraph too, every time. The difference showed on the largest project, in the way there: the controllers of Akeneo reaching GetCategoryInterface::byCode() through its command bus cost 182 k tokens and 19 s with phpgraph, 382 k and 33 s without. One run each is a direction, not a measure; on the other three tasks, phpgraph cost more tokens.
Quick start
1. Install. A single executable, no PHP needed (Linux and macOS on x86_64 and ARM, Windows on x86_64):
curl -fsSL https://raw.githubusercontent.com/hbenabdallah/phpgraph/main/install.sh | sh # latest release
curl -fsSL https://raw.githubusercontent.com/hbenabdallah/phpgraph/main/install.sh | sh -s -- 0.2.0 # a given release curl -fsSL https://raw.githubusercontent.com/hbenabdallah/phpgraph/main/install.sh | sh -s -- dev-main # the main branch
irm https://raw.githubusercontent.com/hbenabdallah/phpgraph/main/install.ps1 | iex # Windows
$env:PHPGRAPH_VERSION = "dev-main"; irm https://raw.githubusercontent.com/hbenabdallah/phpgraph/main/install.ps1 | iex
The script downloads the binary, checks its SHA-256 and puts it in ~/.local/bin (Windows: %LOCALAPPDATA%\Programs\phpgraph, added to the PATH); PHPGRAPH_INSTALL_DIR changes the directory. Run it again to update. dev-main is rebuilt on every push to main (the edge pre-release). The binary is a static PHP runtime with phpgraph inside, built with static-php-cli.
With PHP 8.5+ installed, or with Docker:
composer require --dev hbenabdallah/phpgraph # or: composer global require hbenabdallah/phpgraph
curl -LO https://github.com/hbenabdallah/phpgraph/releases/latest/download/phpgraph.phar docker pull ghcr.io/hbenabdallah/phpgraph # nothing else to install
2. Connect your agent. mcp-config prints a ready-to-paste configuration with the paths filled in (vendor/bin/phpgraph when installed with Composer):
phpgraph mcp-config sherpa # Sherpa: a `sherpa mcp add` command, one declaration for every project
phpgraph mcp-config claude # Claude Code: a claude mcp add command, or .mcp.json phpgraph mcp-config codex # Codex: ~/.codex/config.toml phpgraph mcp-config cursor # Cursor: .cursor/mcp.json, shareable with the team phpgraph mcp-config json # any other MCP client over stdio
Agents reach for grep first, even with phpgraph connected. mcp-config also prints a line for the instructions file of the project (CLAUDE.md, AGENTS.md) telling the agent to call phpgraph before grep or reading files; the MCP instructions of the server say it too.
With Sherpa, a terminal coding agent, one declaration serves every project: Sherpa starts its MCP servers from the project it runs in.
sherpa mcp add phpgraph -- ~/.local/bin/phpgraph serve
In a Sherpa session, /mcp add does the same, and the tools are there at once. Both write ~/.config/sherpa/mcp.json.
With Claude Code (absolute paths, as mcp-config prints them):
claude mcp add phpgraph -- /home/you/.local/bin/phpgraph serve /path/to/project
3. Ask your agent something like *"Give me an overview of this project"*, *"How does an order get placed?"* or *"What breaks if I change OrderRepository::save?"*. The graph is built on the first call, then kept up to date.
MCP tools
| Tool | Use it to |
|---|---|
overview | Start here: Composer stack, namespace tree with layers, bounded contexts, layer-rule violations, messages, HTTP routes (each with method, path, controller and file up to 30, else grouped by path prefix), services, and what the graph cannot see. |
query_graph | Find the code about a topic when you do not know the class names, by the words of their names (validated finds Validator), with the classes of the feature around the ones it names. A question about routes (*"mooc courses routes"*, *"GET /courses"*) returns the matching routes and their controllers. The families of classes around the answer are counted by folder (*ContextRuleInterface: 34 in …*), injected lists once (*ContextValidator receives 34 ContextRuleInterface*). |
outline | Before explaining a feature: its structural outline, enough to read only the few files with non-obvious logic. The classes it is made of, by namespace and layer, with the first sentence of their docblock, their public signatures, constants and enum cases; the interfaces and base classes around it with their implementations by module (0 stated); the routes running into it, chain by chain, through the closures it runs; behaviour read in the bodies (guarded throws, early returns, branches on constants, loop caps, state compared before and after); the container wiring with service ids; its users, tests counted by module, what no test touches and what nothing uses. About 15 KB; a list cut short names the section that has it all (section behaviour, 1 to 9 KB), and a core full at 45 classes names those it left out. A class used by many (the User model) brings nothing in with it: it shows the methods the feature calls and its attributes naming the feature's classes ($log: Log). A method (OrderService::place) gives what it runs instead: the methods it calls, 3 calls deep, each class with those methods only; hubs (called by 20 classes or more, a singleton's getInstance()) counted, not followed; its behaviour nearest first. |
| get_node | Read one class, method, route or chann