Logo: GPT Repo MCP

GPT Repo MCP

Communautéit
CAHN91

GPT Repo MCP gives ChatGPT direct context from approved local repos, then lets it write files, update code, prepare plans, review diffs, and carry context into the next chat.

EditeurCAHN91
Repositorygpt-repo-mcp
SproochTypeScript
Forks
23
Stären
99
Disponibel Tools
0
Transporttypstdio
Kategorien
LizenzMIT
Linken
  • Tools mat KI-Workflows verbannen

    GPT Repo MCP bitt MCP-Funktiounen un, déi vu kompatibele KI-Clienten a KI-Agente kënne benotzt ginn.

  • Disponibel Tools: 0

    Kuckt Iech déi opruffbar Aktiounen hei drënner un, mat Nimm a Beschreiwungen, wa se vum Server geliwwert ginn.

  • Konfiguratioun fir ze kopéieren

    Benotzt d'Installatiounsbeispiller, fir dëse Server an deem MCP-Client ze konfiguréieren, deen Dir am léifste benotzt.

  • Interessi vun der Communautéit um Open-Source-Projet

    Zuele vum verlinkte Repository – Stären: 99, Forks: 23.

GPT Repo MCP

Let ChatGPT work from your repo — safely.

CI Node.js >=20 License: MIT Writes opt-in

GPT Repo MCP connects ChatGPT to approved local repositories through a focused, policy-controlled toolset. ChatGPT can understand a codebase, edit multiple files, run approved checks, diagnose failures, review the real Git diff, and prepare a local commit — while you stay in the normal ChatGPT conversation.

Your files remain in the workspace you approved. You choose whether each repository is read-only, writable, or ready for reviewed local commit work.

GPT Repo MCP is a tool-only MCP server. It does not add a custom interface to ChatGPT and is not affiliated with OpenAI, ChatGPT, Anthropic, or the Model Context Protocol maintainers.

What Becomes Possible

Your goalWhat ChatGPT can do
Understand an unfamiliar projectMap the structure, search code, read relevant files, and trace dependencies
Build a feature or applicationPlan and apply cohesive edits across one or many files in an approved repository
Fix a failing implementationRun approved tests, builds, linting, type checks, or smoke checks and use the evidence to correct the code
Review work before it shipsInspect current file bytes and the real Git diff, identify risks, and verify what remains
Finish a local change safelyValidate, review, stage, recover, or create a local commit when the repository policy allows it
Continue in a later conversationPreserve bounded local context, decisions, risks, touched files, and next steps

ChatGPT chooses a workflow that fits your request. GPT Repo MCP independently enforces repository access, path boundaries, write policy, secret checks, validation profiles, stale-state guards, and allowed Git operations.

Explore the capability guide · Review the security model · See the tools and workflows

From Request To Reviewed Result

text
You ask in ChatGPT
        ↓
Understand → Edit → Validate → Review → Local commit
        ↓
Approved local repository

A question may need only search and reading. An implementation can continue through multi-file editing, approved validation, review, and local commit preparation. ChatGPT receives tool descriptions, schemas, safety annotations, and structured results that help it select the next appropriate action.

The model guides the work; the server enforces the boundary. No prompt can turn the server into unrestricted filesystem access, arbitrary shell execution, automatic push, or automatic deployment.

Quickstart

1. Install

bash
git clone https://github.com/CAHN91/gpt-repo-mcp.git
cd gpt-repo-mcp
npm install
npm run build
cp config.example.json config.local.json

The copied starter config is valid and empty.

2. Approve a repository

bash
npm run add -- /path/to/your/repo

In an interactive terminal, choose read, write, or ship. For predictable setup in scripts or CI-like terminals, provide an explicit read, write, or ship mode:

bash
npm run add -- /path/to/your/repo --mode read
npm run add -- /path/to/your/repo --mode write
npm run add -- /path/to/your/repo --mode ship

The general command form is npm run add -- <path> --mode <mode>.

3. Connect ChatGPT

bash
npm run connect

Copy the printed MCP URL into ChatGPT Developer Mode connector settings, start a new chat, select the connector, and ask:

text
Use GPT Repo MCP. Which repositories can you access?

New to ngrok? Follow Install ngrok from zero. For the OpenAI Secure MCP Tunnel, use npm run connect:secure and follow the connection guide.

Permission Modes

ModeBest forAvailable outcome
readExploration, architecture review, and cautious first useSearch, read, understand, and review repository state
writeDaily implementationRead capabilities plus policy-checked single- and multi-file edits
shipReviewed local completionWrite capabilities plus approved validation, recovery, staging, and local commits

No mode enables push, pull, reset, checkout, switch, rebase, merge, stash, force operations, branch deletion, shell execution, or arbitrary commands.

Try It In ChatGPT

text
Give me a project brief for <repo_id>. Explain the architecture and likely entry points.
text
Implement this feature in <repo_id>. Update every affected file, run the approved checks, and review the final diff.
text
Diagnose the failing tests in <repo_id>, fix the underlying issue, and verify the result.
text
Review the current Git changes in <repo_id>. Tell me what is ready, what is risky, and what still needs work.
text
Prepare this completed change for a local commit, but do not push or deploy anything.

More examples and resulting workflows are available in the capability guide.

How ChatGPT Works

You describe the outcome in normal language. ChatGPT then chooses the smallest safe workflow that fits the request:

  1. Understand — inspect the project structure and read relevant files.
  2. Change — edit one file or a coherent set of files when writes are enabled.
  3. Validate — run only checks that the repository has approved.
  4. Review — inspect the real Git diff, validation evidence, and remaining risk.
  5. Finish or recover — prepare a reviewed local commit, or safely reverse the affected paths.

Simple questions can stop after reading. Implementation requests can continue through the whole loop. Specialist tools for transactional patchsets, work continuity, or reviewing externally executed agent work are used only when the task benefits from them.

You normally do not need to select tools by name. The connector describes each tool to ChatGPT, and the server checks every request independently. See Tools and workflows when you want to understand the available tool groups or ask ChatGPT to use a specific capability.

Safety By Design

  • Only explicitly approved repository roots are accessible.
  • Every path is repo-relative and sandboxed against traversal and symlink escapes.
  • Writes are disabled until the repository opts in.
  • File changes are checked against allowed paths, denied paths, size limits, stale-state guards, and secret patterns.
  • Validation uses configured profiles instead of arbitrary commands.
  • Git mutations operate on explicit paths and current reviewed state.
  • Push and deployment remain outside the server.

For the full boundary, threat model, and approval behavior, read Security.

Common Commands

CommandPurpose
npm run add -- <path>Approve a repository and choose a permission mode
npm run add -- <path> --mode <mode>Add a repository with an explicit read, write, or ship mode
npm run listList approved repositories
npm run remove -- <repo_id>Remove an approved repository
npm run doctorCheck configuration, scripts, tunnel state, port use, and Git state
npm run connectStart the server and built-in ngrok connection flow
npm run connect:secureStart the server with the OpenAI Secure MCP Tunnel
npm run check:configValidate local configuration

Documentation

Using GPT Repo MCP

GuideWhen you need...
Capability guideA user-oriented explanation of what ChatGPT can accomplish
SetupInstallation and local configuration
ChatGPT connectionConnector setup inside ChatGPT
Connection optionsngrok, Cloudflare, secure tunnel, and manual alternatives
Write workflowsEditing, validation, review, recovery, and local commits
Tools and workflowsWhat each tool group enables and when ChatGPT uses it
Security modelWhat is protected, what leaves your machine, and what remains your responsibility
Error referenceStable error codes and what they mean
External-agent protocolAdvanced review workflow when you separately operate an implementation agent
Migration guideMoving from 0.1.x to 0.2.0

Contributing And Extending

See Product principles, Architecture, Contributing, Quality, the technical terminology, and the release checklist.

Requirements

  • Node.js 20 or newer
  • npm
  • Git
  • An HTTPS tunnel such as ngrok, or the supported secure tunnel flow
  • ChatGPT with Developer Mode access

Troubleshooting

  • Unknown repository: run npm run list and confirm the repo_id.
  • Write blocked: ask ChatGPT to use repo_policy_explain for the repository and path.
  • Connector URL changed: restart the connection and update ChatGPT with the new URL.
  • Tunnel returns 502: confirm the local server is running, check /health, and restart the tunnel.
  • Tool schema looks stale: refresh the connector and start a new ChatGPT conversation.

For detailed diagnostics, see Setup and Approval troubleshooting.

License

MIT. See LICENSE.

Installatioun

TypingMind
{
  "mcpServers": {
    "gpt-repo-mcp": {
      "command": "npm",
      "args": [
        "run",
        "mcp"
      ],
      "env": {
        "GPT_REPO_CONFIG": "<GPT_REPO_CONFIG>",
        "PORT": "<PORT>"
      }
    }
  }
}

GPT Repo MCP MCP mat verschiddene KI-Modeller benotzen

TypingMind verbënnt MCP-Tools um Niveau vum Aarbechtsberäich. Soubal GPT Repo MCP verbonnen ass, kënnt Dir et mat verschiddene KI-Modeller an TypingMind benotzen, amplaz et fir all Modell separat anzeriichten. Dës MCP-Integratioun leeft lokal iwwer den TypingMind-MCP-Connector op Ärem Apparat.

Ariichtungsuleedung, fir de lokale Connector ze benotzen

Benotzt dës Optioun, wann den MCP-Server Zougrëff op lokal Fichieren, Appen oder privat Ressourcen op Ärem Computer brauch.

1

D'MCP-Astellungen opmaachen

Gitt an TypingMind op „Astellungen“, „Erweidert Astellungen“, dann op „Model Context Protocol“ a wielt „Connector ariichten“.

  1. Maacht TypingMind an Ärem Browser op.
  2. Klickt op d'Astellungssymbol.
  3. Gitt op „Erweidert Astellungen“.
  4. Maacht d'Sektioun „Model Context Protocol“ op.
  5. Klickt op „Connector ariichten“ a wielt „Dësen Apparat“.
Ariichtungsbildschierm vum TypingMind-MCP-Connector: D'Optioun „Dësen Apparat“ ass ausgewielt
2

De Connector-Befeel ausféieren

Wielt „Dësen Apparat“, kopéiert de Befeel aus TypingMind a féiert en am Terminal aus. Loosst de Prozess lafen, wärend Dir MCP benotzt.

  1. Kopéiert den Ariichtungsbefeel, deen TypingMind uweist.
  2. Maacht Terminal op macOS oder Windows Terminal op Windows op.
  3. Setzt de kopéierte Befeel an a féiert en aus.
  4. Bestätegt d'Installatioun vum Package, wann den Terminal Iech freet, ob Dir weiderfuere wëllt.
  5. Loosst den Terminal an de Prozess doranner lafen, wärend Dir MCP-Tools benotzt.
3

GPT Repo MCP als Server derbäisetzen

Wann de Connector-Status „Prett“ ass, klickt op „Serveren änneren“ a setzt d'MCP-Serverkonfiguratioun an.

  1. Waart, bis de Connector-Status „Prett“ weist.
  2. Klickt op „Serveren änneren“.
  3. Setzt d'MCP-Serverkonfiguratioun fir GPT Repo MCP an.
  4. Späichert d'Serverlëscht.
  5. Aktualiséiert d'Säit, wann Dir kontrolléiere wëllt, ob de Connector nach ëmmer prett ass.
MCP-Astellunge vun TypingMind mat aktivem Server an dem Knäppchen „Serveren änneren“
{
  "mcpServers": {
    "gpt-repo-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "gpt-repo-mcp"
      ]
    }
  }
}
4

D'Verbindung mat verschiddene Modeller benotzen

Späichert d'Serverlëscht, maacht „Plugins“ op an aktivéiert d'MCP-Tools vun der Integratioun GPT Repo MCP. Wielt dann e belibegen ënnerstëtzte KI-Modell an TypingMind a benotzt d'Tools am Chat oder weist se engem KI-Agent zou.

  1. Maacht d'Säit „Plugins“ an TypingMind op.
  2. Aktivéiert d'MCP-Tools vun der Integratioun GPT Repo MCP.
  3. Start e Chat a wielt de KI-Modell, deen Dir benotze wëllt.
  4. Benotzt d'MCP-Tools am Chat oder weist se engem KI-Agent zou.
  5. Wiesselt bei Bedarf op en anere KI-Modell, ouni MCP nei ze verbannen.
TypingMind-Chat mat aktivéierten MCP-Tools an engem ausgewielte KI-Modell
Kënnt Dir mir mat GPT Repo MCP bei dëser Aufgab hëllefen?
GPT Repo MCP
Jo. Ech hunn et gelies.
Dat hunn ech mat GPT Repo MCP fonnt.

Heefeg gestallte Froen

Fir wat gëtt den MCP-Server GPT Repo MCP benotzt?

GPT Repo MCP ass en MCP-Server, deen et kompatibele KI-Clienten erlaabt, op extern Tools a Kontextinformatioune zouzegräifen. An TypingMind kënnt Dir dësen MCP-Server eemol derbäisetzen a seng Tools an Ärem KI-Aarbechtsberäich zur Verfügung stellen.

Kann ech GPT Repo MCP MCP mat méi KI-Modeller an TypingMind benotzen?

Jo. TypingMind verbënnt MCP-Tools um Niveau vum Aarbechtsberäich. Sou kënnt Dir GPT Repo MCP mat verschiddene KI-Modeller wéi Claude, ChatGPT, Gemini oder anere Modeller benotzen, déi Dir an TypingMind konfiguréiert hutt, ouni den MCP-Server fir all Modell separat anzeriichten.

Firwat GPT Repo MCP MCP mat TypingMind benotzen?

TypingMind ass eng vun de beschte Benotzeruewerfläche fir LLM-Chat, well et méi KI-Modeller, Prompts, Plugins, KI-Agenten, API-Schlësselen a MCP-Tools an engem Aarbechtsberäich zesummebréngt. Wann GPT Repo MCP verbonnen ass, kënnt Dir seng MCP-Tools mat Äre bevorzugte Modeller benotzen a gläichzäiteg Ären Aarbechtsoflaf beim Chatten an TypingMind organiséieren.

Wéi verbannen ech GPT Repo MCP MCP mat TypingMind?

GPT Repo MCP leeft iwwer de lokale MCP-Connector vun TypingMind. Dat eegent sech am beschten, wann den MCP-Server Zougrëff op lokal Fichieren, Desktop-Apps, Kommandozeilen-Tools oder privat Ressourcen op Ärem Computer brauch.

Wéi eng Tools stellt GPT Repo MCP MCP an TypingMind zur Verfügung?

GPT Repo MCP stellt MCP-Funktioune zur Verfügung, déi Dir op der Plugins-Säit vun TypingMind aktivéiere kënnt, fir se am Chat ze benotzen oder KI-Agente zouzeweisen.

Muss ech meng API-Schlëssele mat TypingMind deelen, fir GPT Repo MCP MCP ze benotzen?

Nee. TypingMind ass nom Local-first-Prinzip opgebaut a léisst Iech d'Kontroll iwwer Är Modellubidder, API-Schlësselen, Prompts a MCP-Konfiguratioun. Wann GPT Repo MCP eng Authentifizéierung verlaangt, setzt déi néideg Headeren, OAuth-Astellungen oder lokal Konfiguratioun fir deen MCP-Server derbäi, wann Dir d'Verbindung erstallt.

Änlech MCP-Serveren

Alleguer weisen

Elo Ären eegene KI-Aarbechtsberäich ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇