- Explore MCP Servers
- reprompter-mcp
Reprompter Mcp
What is Reprompter Mcp
Reprompter-mcp is an MCP (Model Context Protocol) server designed to analyze prompts, compare them with relevant data, and utilize OpenRouter (Claude 3.7 Sonnet) to refactor them for improved effectiveness.
Use cases
Use cases for reprompter-mcp include enhancing chatbot interactions, improving AI-generated content quality, optimizing user prompts in applications, and refining communication strategies in automated systems.
How to use
To use reprompter-mcp, clone the repository, install dependencies using ‘npm install’, create a .env file with your OpenRouter API key, and start the server with ‘npm start’. Configure the MCP settings by copying the template configuration file and updating it with your specific paths.
Key features
Key features of reprompter-mcp include prompt analysis to identify strengths and weaknesses, prompt refactoring using AI for effectiveness, context integration for better analysis, and application of specific prompt engineering techniques.
Where to use
Reprompter-mcp can be used in various fields that require prompt optimization, including AI development, customer support automation, content generation, and any application that relies on effective prompt usage.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Overview
What is Reprompter Mcp
Reprompter-mcp is an MCP (Model Context Protocol) server designed to analyze prompts, compare them with relevant data, and utilize OpenRouter (Claude 3.7 Sonnet) to refactor them for improved effectiveness.
Use cases
Use cases for reprompter-mcp include enhancing chatbot interactions, improving AI-generated content quality, optimizing user prompts in applications, and refining communication strategies in automated systems.
How to use
To use reprompter-mcp, clone the repository, install dependencies using ‘npm install’, create a .env file with your OpenRouter API key, and start the server with ‘npm start’. Configure the MCP settings by copying the template configuration file and updating it with your specific paths.
Key features
Key features of reprompter-mcp include prompt analysis to identify strengths and weaknesses, prompt refactoring using AI for effectiveness, context integration for better analysis, and application of specific prompt engineering techniques.
Where to use
Reprompter-mcp can be used in various fields that require prompt optimization, including AI development, customer support automation, content generation, and any application that relies on effective prompt usage.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Content
Reprompter MPC Server
An MCP (Model Context Protocol) server that analyzes prompts, compares them with relevant data, and uses OpenRouter (Claude 3.7 Sonnet) to refactor them.
Features
- Prompt Analysis: Analyze prompts to identify strengths, weaknesses, and suggested improvements
- Prompt Refactoring: Refactor prompts using AI to improve their effectiveness
- Context Integration: Incorporate relevant context and chat history into the analysis and refactoring process
- Technique Application: Apply specific prompt engineering techniques to improve prompts
Installation
- Clone the repository
- Install dependencies:
npm install - Create a
.envfile with your OpenRouter API key:OpenRouter_API_KEY=your-api-key - Build the project:
npm run build
Security
API Key Management
To securely manage your OpenRouter API key:
- Never hard-code API keys in files that might be committed to version control
- Use environment variables to store sensitive credentials
- Add
.envto your.gitignorefile to prevent accidentally committing it - Consider using a secrets manager for production deployments
Environment Variable Setup
# On Windows
setx OPENROUTER_API_KEY "your-api-key"
# On macOS/Linux
export OPENROUTER_API_KEY="your-api-key"
Usage
Starting the Server
npm start
Configuring in MCP Settings
A template configuration file is provided in reprompter-mpc-config.template.json. Copy this file to reprompter-mpc-config.json and update it with your specific paths:
{
"mcpServers": {
"reprompter": {
"command": "node",
"args": [
"build/index.js"
],
"cwd": "PATH_TO_YOUR_REPROMPTER_MPC_DIRECTORY",
"env": {
"OpenRouter_API_KEY": "${OPENROUTER_API_KEY}"
},
"alwaysAllow": [
"analyze_prompt",
"refactor_prompt"
]
}
}
}
Important:
- Replace
PATH_TO_YOUR_REPROMPTER_MPC_DIRECTORYwith the absolute path to your reprompter-mpc directory - Set up your OpenRouter API key using environment variables as described in the security section below
- Add this configuration to your MCP settings file
Available Tools
analyze_prompt
Analyzes a prompt and provides structured feedback on its strengths, weaknesses, and suggested improvements.
Input Schema:
{
"prompt": "The prompt to analyze",
"context": "Optional context relevant to the prompt",
"chatHistory": [
{
"role": "user|assistant|system",
"content": "Content of the message",
"timestamp": "Optional timestamp"
}
]
}
Output:
refactor_prompt
Refactors a prompt using AI to improve its effectiveness based on analysis and suggested techniques.
Input Schema:
Output:
The refactored prompt text.
Example Usage
// Example of using the analyze_prompt tool
const analysis = await use_mcp_tool({
server_name: "reprompter",
tool_name: "analyze_prompt",
arguments: {
prompt: "Tell me about the history of artificial intelligence.",
context: "The user is a beginner in AI concepts."
}
});
// Example of using the refactor_prompt tool
const refactoredPrompt = await use_mcp_tool({
server_name: "reprompter",
tool_name: "refactor_prompt",
arguments: {
prompt: "Tell me about the history of artificial intelligence.",
analysis: analysis, // Result from analyze_prompt
techniques: ["Chain-of-Thought", "Few-Shot Examples"],
context: "The user is a beginner in AI concepts."
}
});
Contributing
Contributions are welcome! Here’s how you can contribute to this project:
- Fork the repository
- Create a new branch (
git checkout -b feature/your-feature-name) - Make your changes
- Commit your changes (
git commit -m 'Add some feature') - Push to the branch (
git push origin feature/your-feature-name) - Open a Pull Request
Please make sure your code follows the existing style and includes appropriate tests.
GitHub Features
Issues
If you encounter any bugs or have feature requests, please open an issue on GitHub. When creating an issue, please provide:
- A clear and descriptive title
- A detailed description of the issue or feature request
- Steps to reproduce the issue (if applicable)
- Any relevant logs or error messages
- Your environment (OS, Node.js version, etc.)
Pull Requests
Pull requests are welcome! Please see the Contributing section for guidelines.
License
ISC - See LICENSE file for details.
Dev Tools Supporting MCP
The following are the main code editors that support the Model Context Protocol. Click the link to visit the official website for more information.










