mcpField
C
codeforces-mcp

codeforces-mcp

Local
github.com/avinash111921Other0Updated today

About codeforces-mcp

codeforces-mcp is an MCP server for competitive programmers and AI coding assistants working with Codeforces. It retrieves problems and user statistics, supports local solution testing, and can use stress tests to isolate failing cases.

Key features

  1. 01Fetch user ratings, ranks, and verdicts
  2. 02Retrieve problem statements and sample tests
  3. 03Compile and run C++ or Python solutions locally
  4. 04Stress-test optimized code against brute force
  5. 05Reduce failing tests to minimal cases
  6. 06Queue and cache API requests

Use cases

  1. 01Review a Codeforces profile and recent results
  2. 02Retrieve a problem and its official samples
  3. 03Test a solution locally before submission
  4. 04Find a minimal failing case with stress testing

MCP support

Exposes Codeforces profile, problem, local execution, and stress-testing capabilities to MCP clients such as AI coding assistants.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"avinash111921-codeforces": {
"command": "uvx",
"args": [
"codeforces-mcp-avinash"
]
}
}
}
Run commanduvx codeforces-mcp-avinash

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
pypicodeforces-mcp-avinash0.1.0

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

Codeforces MCP Server

A Model Context Protocol (MCP) server for Codeforces competitive programming. This server enables AI coding assistants (like Claude, Cursor, and Cline) to autonomously fetch problem statements, analyze your submission history, recommend upsolving targets, and run automated local stress tests.

Features

  • Profile & Stats: Fetch live user ratings, ranks, and recent verdict breakdowns.
  • Problem Scraping: Bypasses Cloudflare to extract full problem descriptions and exact sample test cases.
  • Local Sandbox: Compiles and executes C++ or Python solutions locally against official sample inputs.
  • Automated Stress Testing: Isolates minimal failing test cases by running your optimized code against a brute-force script and a random generator.
  • Rate-Limit Safe: Built-in queuing and caching ensures you never hit the Codeforces API 1-request-per-2-seconds limit.

Installation & Usage

You can run this server seamlessly using uvx without manual installation. Add the following configuration to your preferred AI IDE.

Cursor

Add this to your MCP configuration (Settings > Features > MCP):

{
  "mcpServers": {
    "codeforces-mcp": {
      "command": "uvx",
      "args": ["codeforces-mcp"]
    }
  }
}

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.