Repo Therapist
Repo Therapist 🛋️
Deine Codebasis erklärt sich selbst unter Druck
Dieser MCP-Server wurde vollständig mit Cursor erstellt
Repo Therapist ist ein MCP-Server (Model Context Protocol), der jedes Repository in abfragbares, erklärbares Wissen verwandelt. Stelle Fragen zu deiner Codebasis über Cursor und erhalte strukturierte, aufschlussreiche Antworten.
Was er tut
Du fragst Cursor Dinge wie:
"Warum ist dieser Dienst so strukturiert?"
"Was geht kaputt, wenn ich das entferne?"
"Welche Teile dieses Repos machen dir Sorgen?"
Hinter den Kulissen:
Liest Repo-Therapist deine Repo-Struktur und Dateien
Analysiert die Git-Historie und Commit-Muster
Korreliert Code mit der Änderungshäufigkeit
Identifiziert Komplexitäts-Hotspots und Risiken
Related MCP server: Code Understanding MCP Server
Verfügbare Tools
Tool | Beschreibung |
| Analysiert ein Repository - führe dies zuerst aus |
| Ruft den statischen Snapshot (Ground Truth) des Repos ab |
| Ruft die Analyse der Git-Historie ab (die Zeitdimension) |
| Erklärt, warum eine bestimmte Datei so ist, wie sie ist |
| Stellt eine beliebige Frage zum analysierten Repo |
| Erhält einen Überblick auf hoher Ebene |
| Generiert einen Risikobewertungsbericht |
Ground Truth: Der Snapshot
Wenn du analyze_repo ausführst, erstellt Repo Therapist einen statischen Snapshot - die maßgebliche Quelle der Wahrheit über dein Repository. Dieser Snapshot enthält:
{
"files": [...], // Every file with path, language, line count
"languages": {...}, // Language breakdown with percentages
"entryPoints": [...], // Detected entry points with confidence levels
"configs": {...}, // Parsed package.json, tsconfig, Dockerfile, CI configs
"directories": [...] // Directory structure with inferred purposes
}Warum das wichtig ist: LLMs müssen diese Snapshot-Daten zitieren, nicht raten. Wenn du fragst "Welche Sprachen verwendet dieses Repo?", kommt die Antwort aus dem Snapshot - nicht dadurch, dass das LLM Annahmen trifft.
Verwende get_snapshot, um bestimmte Abschnitte abzurufen:
get_snapshot(section: "files")- Alle Dateien mit Metadatenget_snapshot(section: "languages")- Sprachstatistikenget_snapshot(section: "entryPoints")- Erkannte Einstiegspunkteget_snapshot(section: "configs")- Geparste Konfigurationsdateienget_snapshot(section: "directories")- Verzeichnisstrukturget_snapshot()- Zusammenfassung von allem
Git Historian: Die Zeitdimension
Der Git Historian analysiert die Commit-Historie, um zu erklären, WARUM Code so ist, wie er ist. Hier hört es auf, nur Spielerei zu sein.
{
"fileChurn": { "auth.ts": { "totalCommits": 47, "churnScore": 85 } },
"authors": { "auth.ts": ["alice", "bob", "charlie"] },
"fragileFiles": [{ "path": "auth.ts", "reasons": ["high-churn", "many-authors"] }],
"hotPaths": [...],
"stableCore": [...]
}Dies ermöglicht es dir, Folgendes zu beantworten:
"Warum ist das seltsam?" → "Weil es in 6 Monaten 12 Mal umgeschrieben wurde."
"Wem gehört diese Datei?" → "Umstritten - 4 Personen haben sie geändert, keine mit >30%."
"Worauf sollte ich achten?" → "Diese 5 Dateien sind fragil und fehleranfällig."
Verwende get_history, um bestimmte Aspekte abzurufen:
get_history(section: "churn")- Änderungshäufigkeit und Volatilität von Dateienget_history(section: "authors")- Statistiken zu Mitwirkendenget_history(section: "fragile")- Dateien, die wahrscheinlich Probleme verursachenget_history(section: "hotPaths")- Häufig genutzte Pfade vs. stabiler Kernget_history(section: "timeline")- Wichtige Ereignisse und Commit-Musterget_history(section: "ownership")- Wer besitzt wasget_history()- Zusammenfassung von allem
Verwende why_is_this_weird für eine spezifische Dateianalyse:
Use why_is_this_weird on "src/auth/login.ts"Liefert eine detaillierte Erklärung mit Zitaten:
# Why is "src/auth/login.ts" the way it is?
## Change History
- Total commits: 47
- Authors: 5 (alice, bob, charlie, dave, eve)
- Churn score: 85 ⚠️ HIGH
## 🔍 Why It's Unusual
**Heavily modified:** This file has been changed 47 times...
**Many hands:** 5 different people have modified this file...Einrichtung
1. Abhängigkeiten installieren
cd repo-therapist
npm install2. Das Projekt bauen
npm run build3. Zu Cursor hinzufügen
Öffne Cursor-Einstellungen → MCP → Neuen MCP-Server hinzufügen:
{
"mcpServers": {
"repo-therapist": {
"command": "node",
"args": ["/FULL/PATH/TO/repo-therapist/dist/index.js"]
}
}
}Wichtig: Ersetze /FULL/PATH/TO/ durch den tatsächlichen absoluten Pfad zu deinem repo-therapist-Ordner.
Beispiel:
{
"mcpServers": {
"repo-therapist": {
"command": "node",
"args": ["/Users/saar/Projects/private/repo-therapist/dist/index.js"]
}
}
}4. Cursor neu starten
Starte nach dem Hinzufügen der MCP-Konfiguration Cursor neu, damit die Änderungen wirksam werden.
FAQ
Muss ich repo-therapist separat ausführen?
Nein. Cursor startet und verwaltet den MCP-Server automatisch für dich. Wenn du die Konfiguration zu Cursors MCP-Einstellungen hinzufügst, wird Cursor:
Den
node dist/index.jsProzess bei Bedarf startenIhn im Hintergrund laufen lassen
Über stdio (Standard-Ein-/Ausgabe) mit ihm kommunizieren
Du musst nur einmal bauen (npm run build), die Konfiguration hinzufügen und Cursor neu starten. Das ist alles.
Wo stelle ich Fragen?
Im normalen Cursor-Chat (Cmd+L oder das Chat-Panel). Der Unterschied liegt darin, wie du fragst:
Ohne MCP: "Was macht dieses Repo?" → Cursor verwendet seine eingebauten Tools
Mit Repo Therapist: "Verwende
analyze_repoauf/path/to/repo" → Cursor ruft das MCP-Tool auf
Du weist Cursor explizit an, die Repo-Therapist-Tools zu verwenden. Cursor sieht sie als zusätzliche Fähigkeiten, die es nutzen kann.
Was ist der Unterschied zum normalen Cursor-Chat?
Normaler Cursor-Chat | Mit Repo Therapist |
Liest Dateien bei Bedarf | Analysiert vorab die gesamte Repo-Struktur |
Kein Bewusstsein für Git-Historie | Analysiert Commit-Muster & Churn |
Antworten basierend auf Gelesenem | Antworten basierend auf strukturierter Analyse |
Keine Risikoerkennung | Identifiziert Komplexitäts-Hotspots |
Generelles Code-Verständnis | Domänenspezifische Einblicke ("was macht dir Sorgen?") |
Der Hauptunterschied: Repo Therapist führt vorab eine strukturierte Analyse durch und speichert diese, sodass Fragen wie "Welche Dateien ändern sich am häufigsten?" oder "Was sind die Risiken?" aus vorab berechneten Daten beantwortet werden können, anstatt dass Cursor es jedes Mal selbst herausfinden muss.
Stell es dir so vor: Cursor ist intelligent, aber reaktiv. Repo Therapist gibt ihm ein "Briefing-Dokument" über deine Codebasis, auf das es sich beziehen kann.
Verwendung
Sobald konfiguriert, kannst du Repo Therapist im Cursor-Chat verwenden:
Schritt 1: Ein Repo analysieren
Analysiere zuerst das Repository, das du erkunden möchtest:
Use analyze_repo to analyze /path/to/some/repoSchritt 2: Fragen stellen
Jetzt kannst du Fragen stellen:
Use ask_repo to answer: "What does this repo do?"Use ask_repo to answer: "Which parts of this repo scare you?"Use ask_repo to answer: "What will break if I remove the auth module?"Schritt 3: Berichte erhalten
Erhalte eine Zusammenfassung:
Use repo_summary to show me an overviewErhalte eine Risikobewertung:
Use risk_report to identify potential issuesBeispiel-Fragen
"Was macht dieses Repo?"
"Wie ist der Code strukturiert?"
"Welcher Tech-Stack wird verwendet?"
"Zeig mir die Abhängigkeiten"
"Welche Dateien sind am größten?"
"Welche Dateien ändern sich am häufigsten?"
"Wer sind die Mitwirkenden?"
"Was sind die letzten Commits?"
"Welche Teile machen dir Sorgen?"
"Was geht kaputt, wenn ich X ändere?"
Entwicklung
Im Entwicklungsmodus ausführen
npm run devFür die Produktion bauen
npm run buildTests ausführen
npm test # Run all tests
npm run test:watch # Run tests in watch mode
npm run test:coverage # Run tests with coverage reportTest-Richtlinien
Hinweis: Füge bei der Implementierung neuer Funktionen immer Unit-Tests hinzu.
Tests befinden sich in tests/ und verwenden Vitest. Die Teststruktur spiegelt die Quelle wider:
tests/
├── fixtures/ # Test utilities and mock repos
│ └── setup.ts # Helper functions for creating test repos
├── scanner/ # Scanner module tests
├── historian/ # Historian module tests
├── tools/ # Tool tests
└── cache.test.ts # Cache testsBeim Hinzufügen einer neuen Funktion:
Erstelle Tests im entsprechenden
tests/-UnterverzeichnisVerwende
createTestRepo()ausfixtures/setup.tsfür Git-bezogene TestsBereinige Test-Repos mit
cleanupTestRepo()inafterAllFühre
npm testaus, um zu überprüfen, ob alle Tests bestehen, bevor du committest
Projektstruktur
repo-therapist/
├── src/
│ ├── index.ts # MCP server entry point
│ ├── cache.ts # In-memory repo cache
│ ├── types.ts # TypeScript interfaces
│ ├── scanner/ # Static snapshot engine (Step 2)
│ │ ├── index.ts # Scanner exports
│ │ ├── types.ts # Snapshot type definitions
│ │ └── scan-repo.ts # Repository scanner
│ ├── historian/ # Git history analyzer (Step 3)
│ │ ├── index.ts # Historian exports
│ │ ├── types.ts # History type definitions
│ │ └── analyze-history.ts # Git history analysis
│ └── tools/
│ ├── analyze-repo.ts # Repository analyzer (orchestrates all)
│ ├── get-snapshot.ts # Snapshot retrieval (ground truth)
│ ├── get-history.ts # History retrieval (time dimension)
│ ├── ask-repo.ts # Question answering
│ ├── repo-summary.ts # Summary generator
│ └── risk-report.ts # Risk assessment
├── tests/ # Unit tests
│ ├── fixtures/ # Test utilities
│ ├── scanner/ # Scanner tests
│ ├── historian/ # Historian tests
│ └── tools/ # Tool tests
├── package.json
├── tsconfig.json
├── vitest.config.ts # Test configuration
└── README.mdTech-Stack
TypeScript - Typsichere Codebasis
@modelcontextprotocol/sdk - MCP-Server-Implementierung
simple-git - Analyse der Git-Historie
ts-morph - TypeScript/JavaScript AST-Parsing (geplant)
glob - Dateimuster-Abgleich
Roadmap
[ ] AST-basierte Code-Analyse mit ts-morph
[ ] Analyse in JSON/SQLite persistieren
[ ] Visualisierung des Abhängigkeitsgraphen
[ ] Erkennung von Sicherheitslücken
[ ] Analyse der Testabdeckung
[ ] Benutzerdefinierte Frage-Handler
Lizenz
MIT
Available Tools
7 toolsanalyze_repoA
Analyze a repository to understand its structure, dependencies, and git history. Run this first before asking questions.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Absolute path to the repository to analyze |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries full burden. It describes what the tool does (analyze structure, dependencies, git history) but does not disclose side effects, permissions, or output format. Adequate but lacks depth on behavioral traits like mutability or performance impact.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences: first states purpose, second provides usage guidance. Extremely concise, front-loaded with essential information, no wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no output schema and no annotations, the description lacks details on what the analysis returns (e.g., report structure, how to use results). It hints at follow-up use ('before asking questions') but does not fully equip an agent to handle output.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The only parameter, 'path', is described in the schema as 'Absolute path to the repository to analyze'. The description does not add extra meaning beyond what the schema already provides. With 100% schema coverage, baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool analyzes a repository for structure, dependencies, and git history, and provides a usage directive ('Run this first before asking questions'), which distinctively positions it among siblings like ask_repo and get_history.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives explicit usage guidance: run this before asking questions. It implies when to use but does not explicitly list alternatives or when not to use, though the sibling context partially compensates.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
ask_repoC
Ask a question about an analyzed repository. Questions can be about structure, purpose, dependencies, patterns, or concerns.
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Optional: path to repo if different from last analyzed | |
| question | Yes | The question to ask about the repository (e.g., 'What does this repo do?', 'Why is the auth service structured this way?') |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden of behavioral disclosure. It does not state that the tool is read-only, whether it requires prior analysis, or any side effects. The description lacks behavioral details beyond the basic action.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence that is concise and to the point. No unnecessary words or repetition.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no output schema, the description should explain what the agent can expect as a response (e.g., an answer text). It also does not mention that the repository must be analyzed first, though sibling tools imply context. The description is incomplete for effective use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, and the schema already contains examples for the 'question' parameter. The description adds marginal value by listing question types, but those are similar to schema examples. Baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'ask' and the resource 'repository', and provides examples of question categories (structure, purpose, etc.). However, it does not explicitly distinguish from sibling tools like 'repo_summary' or 'why_is_this_weird', which may also answer questions.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives, nor does it mention prerequisites (e.g., that the repository must have been analyzed first). It only states what the tool does.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_historyB
Get git history analysis - the time dimension. Reveals WHY code is the way it is: file churn, ownership, fragile files, hot paths vs stable core.
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Optional: path to repo if different from last analyzed | |
| section | No | Which aspect of history to retrieve: 'churn' (file change frequency), 'authors' (contributor stats), 'fragile' (problem files), 'hotPaths' (volatile vs stable), 'timeline' (events), 'ownership' (who owns what), 'all' (summary). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided; description carries full burden. It mentions what the tool reveals (churn, authorship, etc.) but omits behavioral details: whether it modifies state, requires authentication, or handles large repos. As a likely read-only analysis, this gap limits agent understanding.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Single, front-loaded sentence with purpose and examples. Efficient but could briefly list alternative uses or output format.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Lacks usage guidelines, output schema, and behavioral details. With six sibling tools, agent needs more context to choose correctly. Missing information on return format or prerequisites.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema has 100% coverage with clear descriptions for both parameters (path, section with enums). Description adds no further semantic value beyond what the schema provides; baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states the tool's verb ('Get'), resource ('git history analysis'), and specific insights ('file churn, ownership, fragile files, hot paths vs stable core'). It emphasizes the 'time dimension', distinguishing it from sibling tools like get_snapshot or repo_summary.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance on when to use this tool vs alternatives (e.g., analyze_repo, risk_report). The description hints at 'time dimension' but lacks exclusions or context for tool selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_snapshotA
Get the static snapshot (ground truth) of the repository. This is the authoritative source - LLMs must cite this data, not guess. Use section parameter to get specific data.
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Optional: path to repo if different from last analyzed | |
| section | No | Which section of the snapshot to retrieve. 'all' returns a summary view. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. It describes a read operation but does not disclose error handling, caching behavior, or response scope beyond inferring from section parameter.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, front-loaded with purpose and authoritative emphasis. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no output schema, the description conveys the tool's role as a source of truth. Could elaborate on return format, but sufficient for a simple retrieval tool with well-defined params.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema covers 100% of parameters, baseline 3. The description adds 'Use section parameter' but does not provide additional meaning beyond the schema's enum or path description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool retrieves a static snapshot as the authoritative ground truth, distinguishing it from sibling tools that involve analysis or generation. It emphasizes this data should be cited, not guessed.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides clear guidance on when to use (for ground truth) and suggests using the section parameter. However, no explicit when-not-to-use or alternatives, though siblings like analyze_repo imply different use cases.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
repo_summaryB
Get a high-level summary of the analyzed repository including tech stack, structure, and key components.
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Optional: path to repo if different from last analyzed |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description must fully disclose behavioral traits, but it only states the action. It does not mention that the tool requires a repository to have been analyzed, that it is read-only, or any constraints like 'last analyzed' implication.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence with no unnecessary words. It efficiently conveys the tool's purpose.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has one optional parameter and no output schema, the description is minimally complete. However, it omits details about the output format and prerequisites (e.g., requiring prior analysis), which would be helpful for an agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, and the description does not add meaning beyond what is already in the schema for the 'path' parameter. The baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states it gets a high-level summary including tech stack, structure, and key components, which is specific and informative. However, it does not explicitly differentiate from sibling tools like ask_repo or analyze_repo, but the distinct purpose is inferable.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus alternatives, nor any context about prerequisites (e.g., requiring a prior analysis). The description is purely declarative.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
risk_reportC
Generate a risk assessment report identifying code smells, complexity hotspots, and areas that might cause problems.
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Optional: path to repo if different from last analyzed |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, and the description does not disclose whether the tool is read-only, requires permissions, or has side effects. It only states it generates a report, leaving behavioral traits unclear.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, concise sentence that directly states the tool's purpose without extraneous information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity of a risk assessment report, the description lacks details on the report's structure, output format, or behavior. It does not compensate for the absence of an output schema.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The single optional parameter 'path' is already fully described in the input schema. The tool description adds no additional meaning beyond the schema, achieving baseline for high coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool generates a risk assessment report focusing on code smells and complexity hotspots. However, it does not differentiate from sibling tools like analyze_repo or repo_summary, which may have overlapping purposes.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool vs alternatives such as analyze_repo, repo_summary, or why_is_this_weird. The description lacks context on appropriate use cases.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
why_is_this_weirdA
Explain why a specific file is the way it is, based on git history. Answers questions like 'Why is this file so complex?' with data: 'Because it's been rewritten 12 times by 5 different people.'
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Optional: path to repo if different from last analyzed | |
| file_path | Yes | The relative path to the file to analyze (e.g., 'src/auth/login.ts') |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description indicates the tool uses git history to answer questions, but with no annotations, it does not disclose whether the tool modifies data, requires special permissions, or the exact nature of its operations. It is adequate but lacks full transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise, consisting of two sentences and an example. It is front-loaded with the primary purpose and efficiently conveys value without unnecessary words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no output schema and a moderate number of parameters, the description explains the tool's behavior well, including an example output. However, it does not address edge cases like files with no history or error conditions, leaving some gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 100% description coverage for both parameters, so the schema itself provides parameter meaning. The description adds context about the analysis type (git history, complexity) but does not extend parameter semantics significantly beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Explain why a specific file is the way it is, based on git history.' It provides a concrete example question and answer, distinguishing it from sibling tools like get_history or analyze_repo.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for understanding file complexity via git history, but it does not explicitly state when to use this tool versus alternatives (e.g., get_history for raw history), nor does it provide any 'when not to use' guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
7 tool updates
v1.0.0- First observed
analyze_repo - First observed
ask_repo - First observed
get_history - First observed
get_snapshot - First observed
repo_summary - First observed
risk_report - First observed
why_is_this_weird
TDQS
Scored across 7 tools
Each tool has a clearly distinct purpose: analyze_repo is for initial analysis, ask_repo for questions, get_history for git history, get_snapshot for authoritative data, repo_summary for high-level summary, risk_report for risk assessment, and why_is_this_weird for explaining file history. No overlap.
Most tools follow a verb_noun pattern (analyze_repo, ask_repo, get_history, get_snapshot), but repo_summary and risk_report are noun_noun, and why_is_this_weird is a full sentence, creating inconsistency.
Seven tools is well-scoped for a repository analysis server, providing essential functionality without being overwhelming or insufficient.
The tool set covers key aspects: analysis, Q&A, history, snapshot, summary, and risk assessment. Minor gaps like direct file search or comparison are missing but can be partially addressed by ask_repo.
Maintenance
Related MCP Connectors
Repository knowledge graph MCP server for codebase understanding and debugging.
A MCP server built for developers enabling Git based project management with project and personal…
The Cortex MCP server provides read-only access to real-time engineering context from the Cortex developer portal, allowing AI coding assistants to answer natural language questions about your organization's catalog (microservices, libraries, domains, teams, infrastructure), scorecards (engineering standards and best practices), initiatives (goals and deadlines), and Engineering Intelligence metrics. It includes tools for querying documentation, tracking personal entities, and accessing AI-assisted insights across the entire Cortex ecosystem.
An MCP server that gives your AI access to the source code and docs of all public github repos
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceAn MCP server that transforms codebases into intelligent, queryable knowledge bases, enabling AI assistants to perform semantic search, explore architecture, and analyze code relationships.166-
- AlicenseCqualityDmaintenanceAn MCP server that analyzes local or remote GitHub repositories, providing intelligent code context and structure to AI coding assistants.1013MIT
- AlicenseAqualityCmaintenanceAn MCP server that extracts complete knowledge from any codebase — architecture, patterns, dependencies, API surface. Combines static analysis with AI-powered deep interpretation.8MIT
- AlicenseNot gradedqualityDmaintenanceA production-grade MCP server for local git repositories that provides tools for code search, git history analysis, complexity metrics, test discovery, and dependency management.MIT