OpenReview Python MCP Server
Exposes the structure and documentation of the openreview-py library, enabling LLMs to discover classes, functions, and signatures for accurate code generation. It provides tools for searching the API and retrieving detailed metadata without executing code or making external API calls.
README
OpenReview Python MCP Server
A Model Context Protocol (MCP) server built with FastMCP that exposes the structure and documentation of the openreview-py library. This allows LLM clients to discover available classes, functions, and their documentation to generate accurate Python code examples using the OpenReview library.
🎯 Purpose
This MCP server provides read-only access to the openreview-py library's structure - no code execution or API calls are performed. It's designed to help LLMs understand and generate code using the OpenReview Python library by providing:
- Function signatures and documentation
- Class structures and methods
- Search capabilities across the library
- Comprehensive library overview
🚀 Quick Start
Prerequisites
- Python 3.11+
uvpackage manager
Installation
- Clone and navigate to the project:
cd openreview-mcp
- Install dependencies:
uv sync
This will install:
fastmcp- MCP server frameworkopenreview-py- The library we're introspecting (from GitHub)- Development tools (pytest, black, ruff, mypy)
Running the Server
Start the MCP server:
uv run openreview-mcp
Or run directly:
uv run python src/server.py
The server will start and display available tools:
Starting OpenReview Python Library MCP Server...
Available tools:
- list_openreview_functions: List all available functions
- list_openreview_classes: List all available classes
- search_openreview_api: Search functions by keyword
- get_openreview_overview: Get library overview
- get_function_details: Get detailed function information
🛠️ Available MCP Tools
1. list_openreview_functions
Lists all available functions from the openreview-py library.
Parameters:
filter_by_module(optional): Filter by specific module (e.g., "openreview.api")
Returns: Array of functions with name, docstring, module, signature, and type.
2. list_openreview_classes
Lists all available classes from the openreview-py library.
Parameters:
include_methods(default: true): Whether to include class methods
Returns: Array of classes with name, docstring, module, and methods.
3. search_openreview_api
Search for functions by name or keywords in docstrings.
Parameters:
query(required): Search term
Returns: Array of matching functions.
4. get_openreview_overview
Get a comprehensive overview of the entire library.
Returns: Dictionary with functions, classes, modules, and statistics.
5. get_function_details
Get detailed information about a specific function.
Parameters:
function_name(required): Name of the function
Returns: Detailed function information.
📁 Project Structure
openreview-mcp/
├── src/
│ ├── server.py # FastMCP server implementation
│ ├── introspect.py # Library introspection utilities
│ └── __init__.py # (optional) package init
├── pyproject.toml # Project configuration and dependencies
└── README.md # This file
🔧 Development
Current Implementation Status
✅ Implemented:
- Complete FastMCP server setup with 5 tools
- Project structure and configuration
- Stub implementations with realistic example data
🚧 TODO - Future Enhancements:
The current implementation uses stub data. Here's how to expand it:
1. Real Library Introspection (introspect.py)
# TODO: Replace stub implementations with real introspection
import openreview
import inspect
def get_openreview_functions():
# Use inspect module to dynamically discover functions
# Walk through openreview module and submodules
# Extract real docstrings, signatures, parameters
pass
2. Enhanced Search (server.py)
# TODO: Implement advanced search features
- Fuzzy string matching
- Search in parameter names and types
- Regex pattern support
- Result ranking by relevance
3. Caching and Performance
# TODO: Add caching for introspection results
- Cache function/class discoveries
- Lazy loading of module information
- Performance monitoring and optimization
4. Advanced Filtering
# TODO: Add sophisticated filtering options
- Filter by function complexity
- Filter by parameter count
- Include/exclude private methods
- Filter by inheritance hierarchy
Development Commands
# Install development dependencies
uv sync --dev
# Run tests (when implemented)
uv run pytest
# Format code
uv run black .
# Lint code
uv run ruff check .
# Type checking
uv run mypy .
Adding New MCP Tools
To add a new tool to the server:
- Define the tool function in
server.py:
@mcp.tool()
def your_new_tool(param1: str, param2: int = 10) -> Dict[str, Any]:
"""
Description of what your tool does.
Args:
param1: Description of parameter
param2: Optional parameter with default
Returns:
Description of return value
"""
# Implementation here
return {"result": "your data"}
- Add any supporting logic to
introspect.pyif needed:
def supporting_function():
"""Helper function for your new tool."""
pass
- Update the main() function to advertise the new tool:
def main():
print("Available tools:")
print("- your_new_tool: Description")
🔍 Usage Examples
With Claude Desktop
Configure the server in your Claude Desktop MCP settings:
{
"mcpServers": {
"openreview": {
"command": "uv",
"args": ["run", "python", "/path/to/openreview-mcp/src/server.py"],
"host": "localhost",
"port": 4000
}
}
}
With VS Code
You can also configure the MCP server in VS Code using the Model Context Protocol extension (or compatible MCP client):
- Open the command palette and search for "MCP: Add Server" or open the MCP extension settings.
- Make sure the port matches your deployment (default is 4000, or set MCP_PORT env variable).
- Save and connect to the server from the MCP extension sidebar.
Example Tool Usage
Once connected (in Claude Desktop or VS Code), you can ask:
"What functions are available for working with notes in OpenReview?"
The client would use the search_openreview_api tool with query "note" to find relevant functions.
"Show me all the classes in the openreview library"
The client would use list_openreview_classes to get the class information.
🤝 Contributing
Key areas for contribution:
- Implement real introspection in
introspect.pyusing Python'sinspectmodule - Add comprehensive error handling for import failures and edge cases
- Implement caching for better performance
- Add tests for all functionality
- Enhance search capabilities with fuzzy matching and ranking
⚠️ Important Notes
- Read-only: This server only provides metadata - no code execution
- No API calls: No actual OpenReview API interactions
- No authentication: No API keys or credentials required
- Educational: Designed for code generation assistance, not production API usage
📄 License
This project is provided as-is for educational and development purposes.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。