Logo vun Pgr

Pgr

Organisatioun
entireio

PGR is an experimental, stateless MCP code-search server for studying how ranking, latency, and output shaping affect agentic search.

Editeurentireio
Repositorypgr
SproochPython
Forks
4
Stären
62
Disponibel Tools
0
Transporttypstdio
LizenzMIT
Linken
  • Tools mat KI-Workflows verbannen

    Pgr stellt MCP-Funktioune bereit, déi vu kompatibele KI-Clienten a KI-Agente kënne benotzt ginn.

  • 0 disponibel Tools

    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 Ärem bevorzugte MCP-Client ze konfiguréieren.

  • Indicateure fir Open Source

    62 Stären an 4 Forks aus dem verlinkte Repository.

pgr repository cover

pgr

pgr is an experimental, stateless MCP server for code search, built as part of research into how coding agents search repositories.

It is a working prototype and public research artifact, not a polished product.

It wraps local code search with ranking and output shaping designed for agent workflows: surfacing likely implementation files earlier, de-prioritizing tests and low-value matches, and formatting results so a model can decide what to read next with less thrashing.

This repository also includes the public datasets, benchmark packages, and saved results used in the accompanying writeup on agentic code search.

Quick Start

1. Install pgr

Install pgr from this repository:

bash
git clone https://github.com/entireio/pgr.git
cd pgr
cargo install --path .

2. Add it to your MCP client

Then add it to any MCP client that can launch a stdio server:

json
{
  "mcpServers": {
    "pgr": {
      "command": "pgr",
      "cwd": "/absolute/path/to/repo"
    }
  }
}

3. Point it at the repo to search

Set cwd to the repository you want your agent to search. pgr searches the current working directory of the process that launches it.

4. Ask your agent to search

Once configured, ask your agent to search the repo. For example:

text
search for where checkpoint commits are written
text
find the code that handles MCP tool calls

If pgr is not yet on your shell PATH after install, use the binary directly at:

bash
~/.cargo/bin/pgr

What pgr gives agents

pgr is not trying to replace ripgrep. It shells out to local rg for fast content search and file listing, then ranks and shapes the results for coding agents.

That means an agent is more likely to see implementation files before test noise, repeated references, or lower-signal matches.

At a high level it provides tools for:

  • search_code
  • read_code
  • find_files
  • list_dir

The search output profile is controlled with PGR_OUTPUT_PROFILE. If it is unset, the server defaults to the richer planner-oriented output profile used in the public results.

There is no index to build, no background daemon, and no separate storage layer. pgr starts, answers MCP tool calls over stdio, and exits when the client stops it.

Build from source

bash
cargo build --release

The binary will be available at target/release/pgr.

If you want the binary on your PATH, you can also install it locally with:

bash
cargo install --path .

For most first-time users, this is the easiest way to try pgr.

Requirements

  • Rust toolchain for building from source
  • ripgrep installed and available as rg

pgr shells out to local rg for both content search and file listing. If rg is not installed, pgr will not be able to search.

Why we built it

pgr is built around a simple idea: faster search alone is not enough. What matters just as much is whether the search result helps the model choose a better next action.

In the public benchmarks in this repository, the strongest effects did not come from raw scan speed. They showed up in more local agent behavior:

  • better first-query retrieval quality
  • fewer redundant search loops before the first code read
  • getting the agent into reading relevant files sooner

That is the problem pgr is designed to improve.

Usage Documentation

  • docs/usage.md - MCP setup, direct stdio smoke test, tool arguments, and output profiles

Public benchmarks and data

The public artifacts referenced in the writeup live under public_release/.

Key packages:

What is in this repo

  • src/
    • the Rust MCP server
  • tests/
    • integration tests for the MCP surface
  • eval/v2/
    • the minimal evaluation harness and backend adapters used by the public benchmark runners
  • public_release/
    • public datasets, benchmark definitions, summaries, and saved outputs referenced in the blog post

Repository scope

This public repository is intentionally focused on:

  • the Rust MCP search server
  • the minimal benchmark harness needed by the public runners
  • the public data and results packages cited in the writeup

Older internal drafts, duplicate exports, and superseded experimental outputs have been removed so the repo stays small, inspectable, and externally understandable.

Contributing

See CONTRIBUTING.md, SECURITY.md, and LICENSE.

Pgr MCP mat verschiddene KI-Modeller benotzen

TypingMind verbënnt MCP-Tools um Niveau vum Aarbechtsberäich. Soubal Pgr 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 mat „Dësen Apparat“ 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. Pescht de 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

Pgr als Server derbäisetzen

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

  1. Waart, bis de Connector-Status „Prett“ weist.
  2. Klickt op „Serveren änneren“.
  3. Pescht d'MCP-Serverkonfiguratioun vu Pgr an.
  4. Späichert d'Serverlëscht.
  5. Aktualiséiert, 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": {
    "pgr": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

D'Verbindung mat verschiddene Modeller benotzen

Späichert d'Serverlëscht, maacht „Plugins“ op an aktivéiert d'MCP-Tools vu Pgr. 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 vu Pgr.
  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éierte MCP-Tools an engem ausgewielte KI-Modell
Hëlleft Dir mir bei dëser Aufgab mat Pgr?
Pgr
Jo. Ech hunn et gelies.
Dat hunn ech mat Pgr fonnt.

Heefeg gestallte Froen

Fir wat gëtt de MCP-Server Pgr benotzt?

Pgr ass e MCP-Server, deen et kompatibele KI-Clienten erlaabt, sech mat externen Tools a Kontext ze verbannen. An TypingMind kënnt Dir dëse MCP-Server eemol derbäisetzen a seng Tools an Ärem KI-Aarbechtsberäich zur Verfügung stellen.

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

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

Firwat Pgr 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 Pgr verbonnen ass, kënnt Dir seng MCP-Tools mat Äre bevorzugte Modeller benotzen a gläichzäiteg Är Chataarbecht an TypingMind organiséieren.

Wéi verbannen ech Pgr MCP mat TypingMind?

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

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

Pgr stellt MCP-Funktiounen 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-Agenten zouzeweisen.

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

Nee. TypingMind setzt op lokal Veraarbechtung a léisst Iech d'Kontroll iwwer Är Modellubidder, API-Schlësselen, Prompts a MCP-Konfiguratioun. Wann Pgr eng Authentifizéierung verlaangt, setzt déi néideg Headeren, OAuth-Astellungen oder lokal Konfiguratioun fir dee MCP-Server derbäi, wann Dir d'Verbindung erstallt.

Änlech MCP-Serveren

All weisen

Elo Ären eegene KI-Workspace ariichten

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