Problem/Motivation
Whenever we're working on Drupal, with drupal/core as dependency, we rely on the models training (or web search) to make sure that our Drupal specific coding questions are answered correctly as your IDE is not able to search within Drupal's code base for answers.
That could mean you're working on a Drupal 11 project, but it still replies with Drupal 10 API documentation the model is trained on, or even Drupal 7 specific documentation.
What we want is to make sure you get the right documentation for the version you're working on.
Proposed resolution
I'd like to create a proof of concept that:
- Works fully locally (No expensive API calls)
- Grabs version specific Drupal documentation
- Connects your IDE with an MCP to that documentation
- And have you query with natural language to get the right documentation
Remaining tasks
TBD.
User interface changes
TBD.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | Screenshot 2025-12-13 at 17.35.18.png | 417 KB | ronaldtebrake |
| #3 | Screenshot 2025-12-16 at 09.23.37.png | 461.57 KB | ronaldtebrake |
| #2 | Screenshot 2025-12-16 at 09.22.08.png | 413.43 KB | ronaldtebrake |
Comments
Comment #2
ronaldtebrake commentedWork in progress here: https://github.com/ronaldtebrake/surge-mcp-dev
The current process:
Ingestion (Maintainers only):
Hydration (End Users):
Runtime (End Users):
Key Components
mcp/sdk): Handles MCP protocol communication between your IDE and the servernikic/php-parser): Parses Drupal's *.api.php files to extract functions, hooks, classes, and documentationThis way we can separate the Hydration & Run time usage to Surge later on.
So we don't need to ship with all the dependencies, but only have to load the versions embeddings in to the Vector Store and set up the MCP to be able to connect to it.
Here you can see how the MCP is giving Drupal 11 specific documentation:

hook_entity_duplicateis only introduce in version 11.2.x https://www.drupal.org/node/3268812For a Drupal 10 Repo:

Comment #3
ronaldtebrake commentedAnd without the MCP on Drupal 10
Comment #4
ronaldtebrake commentedComment #5
ronaldtebrake commentedClosed for now, it's very likely this could be better of being a Skill and only loaded when needed.