Prompyai

io.github.samouh-waleedPublished by GitHub account samouh-waleedv0.1.1Updated Oct 24, 2026

Scores your prompts against your real codebase — context-aware prompt intelligence

VerifiedSTDIODesktop onlyDeveloper ToolsAI & ML

Overview

AI-generated overview

Scores and rewrites prompts in Claude CLI against your local codebase, using file paths, symbols, and git state for context.

What you can do
PrompyAI evaluates each prompt on a 0-100 scale across specificity, context completeness, task clarity, and file and folder anchoring, then suggests improvements and rewrites the prompt with real file paths and verified symbols. It indexes the project locally: file tree, detected tech stack, code symbols via the TypeScript Compiler API, git branch and dirty files, and Claude Code session transcripts. Tools include evaluate_prompt, get_context, and prompyai_toggle to pause or enable auto-evaluation.
When to use it
Useful for developers who write many prompts in Claude CLI and want feedback on prompt quality grounded in the actual repository. Best when prompts often lack file paths or context and you want automatic suggestions without leaving the session.
Requirements
Local process started via npx (npm package prompyai-mcp); requires Node.js 20+. No sign-up or config needed. Optional ANTHROPIC_API_KEY enables direct AI rewrites via Claude Haiku; without it, context is returned to Claude for enhancement. Optional PROMPYAI_TELEMETRY can be set to false.
Before you install
Reads local project files, git state, and Claude Code conversation transcripts for indexing. Optional anonymous telemetry is on unless PROMPYAI_TELEMETRY is set to false. If ANTHROPIC_API_KEY is provided, prompt and codebase context may be sent to Anthropic for rewrites; without it, no external calls are made for enhancement.

Installation

In SourceWeft

  1. Open Prompyai in the dashboard and add it to a workspace.
  2. Enable the server for the chats that should use its tools.

Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.

Other MCP clients

Follow the launch instructions in the repository.

README

prompyai-mcp

Context-aware prompt intelligence MCP server for Claude CLI. Scores your prompts against your real codebase and rewrites them with AI.

Install

bash
claude mcp add prompyai -- npx prompyai-mcp serve

No sign-up. No config. Works immediately. Requires Node.js 20+.

What It Does

Every time you write a prompt in Claude CLI, PrompyAI automatically:

  1. Scores it (0–100) across Specificity, Context Completeness, Task Clarity, and File & Folder Anchoring
  2. Suggests improvements tailored to your project
  3. Rewrites the prompt with real file paths, verified symbols, and codebase context
Prompt Score: 43/100 [D]
  Specificity         3/25  ==..............  Context Completeness 13/25  ========........  Task Clarity        15/25  =========.......  File & Folder Anchoring 10/25  ======..........
Key improvements:  1. Expand your prompt with more context  2. Add file paths using @mentions  3. Specify what format you expect the output in
Try something more like:
  "Build the VS Code extension in packages/vscode-extension/ that integrates   with the PrompyAI MCP server at packages/mcp-server/. It should provide   real-time prompt scoring in the editor sidebar, show score breakdowns   (specificity, context, clarity, anchoring), and offer a 'rewrite prompt'   action. Use the shared types from packages/shared/."

AI Enhancement — Works for Everyone

PrompyAI uses a two-layer architecture:

  • API key users (ANTHROPIC_API_KEY set) → PrompyAI calls Claude Haiku directly for fast AI rewrites
  • Subscription users (no API key) → PrompyAI returns rich codebase context to Claude, which generates the enhanced prompt using your existing session

All users get AI-enhanced output. No separate API key required.

How It Knows Your Codebase

PrompyAI indexes your project locally:

  • File tree — structure, key folders, recently modified files
  • Tech stack — language, framework, ORM, test runner detection
  • Code symbols — functions, classes, interfaces extracted via the TypeScript Compiler API
  • Git state — branch, dirty files, recent changes
  • Session history — reads Claude Code conversation transcripts for multi-turn context

All indexing happens locally. Nothing is sent externally (except optional anonymous telemetry).

MCP Tools

evaluate_prompt

Auto-called on every user message. Scores your prompt against your project.

ParameterRequiredDescription
promptyesThe prompt text to evaluate
workspace_pathyesAbsolute path to your project
active_filenoCurrently open file path
session_idnoClaude Code session ID for multi-turn context

get_context

Returns your project summary: tech stack, recent files, key folders.

ParameterRequiredDescription
workspace_pathyesAbsolute path to your project

prompyai_toggle

Turn auto-evaluation on or off. Say "pause prompyai" or "enable prompyai" in Claude CLI.

Desktop Config

Alternatively, add to ~/.claude/claude_desktop_config.json:

json
{  "mcpServers": {    "prompyai": {      "command": "npx",      "args": ["prompyai-mcp", "serve"]    }  }}

Environment Variables

VariableRequiredDescription
ANTHROPIC_API_KEYNoEnables direct AI suggestions via Claude Haiku (optional)
PROMPYAI_TELEMETRYNoSet to false to opt out of anonymous telemetry

CLI Commands

bash
prompyai serve              # Start the MCP server (default)prompyai doctor             # Run environment diagnostics  --workspace <path>        # Workspace to check (default: cwd)

Programmatic API

typescript
import { WorkspaceIndexer, ScoringEngine } from 'prompyai-mcp';
const indexer = new WorkspaceIndexer();const scorer = new ScoringEngine();
const fingerprint = await indexer.getFingerprint('/path/to/project');const result = await scorer.evaluate('fix the auth', fingerprint);
console.log(result.display); // Pre-formatted score outputconsole.log(result.total);   // 0-100console.log(result.grade);   // A-F

Links

License

MIT

Source: packages/mcp-server/README.md at commit df67118

Tools

0
SourceWeft has not started this package in its sandbox yet, so its tools are not known.

Version history

1
  1. v0.1.1LatestSep 16, 2026

Score

50% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 days25 pts

    Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.

  • Auth declared10 pts

    Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.

  • Tools listed15 pts

    Answer tools/list without a credential, or ship a package that starts in a sandbox without one.

  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts