Skip to main content
Glama
SAMI-CODEAI

Competitive Programming Mentor MCP Server

by SAMI-CODEAI

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
LOG_LEVELNoLog levelINFO
LLM_PROVIDERNoLLM provider: 'openai' or 'ollama'openai
OLLAMA_MODELNoOllama modelllama3.1:8b
OPENAI_MODELNoOpenAI model namegpt-4o-mini
CACHE_ENABLEDNoEnable cachetrue
CACHE_DISK_DIRNoCache disk directory.cache
OPENAI_API_KEYNoOpenAI API key
OLLAMA_BASE_URLNoOllama base URLhttp://localhost:11434
CACHE_TTL_SECONDSNoCache TTL in seconds3600
OPENAI_MAX_TOKENSNoMax tokens for OpenAI4096
OPENAI_TEMPERATURENoTemperature for OpenAI0.2

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
extensions
{
  "io.modelcontextprotocol/ui": {}
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
detect_patternsC

Analyze problem text to detect patterns, difficulty, and complexity hints.

extract_constraintsB

Extract variable constraints and time/memory limits.

estimate_difficultyB

Estimate target audience and difficulty rating for the problem.

identify_topicsA

Identify topics, tags, and prerequisites for the problem.

suggest_algorithmsB

Suggest multiple viable candidate algorithms or structures for the problem.

compare_algorithmsB

Compare multiple candidate algorithms in a detailed pros/cons comparison.

choose_best_algorithmB

Select the single absolute best algorithm to implement for a problem.

estimate_runtimeC

Estimate runtime safety by validating loops/nodes against constraints.

generate_solutionB

Generate an optimal solution for the problem in the requested language.

generate_pseudocodeB

Generate language-agnostic pseudocode for the problem.

generate_multi_languageA

Generate code solutions in C++, Java, and Rust.

dry_runC

Perform a step-by-step trace execution of the code against test cases.

prove_correctnessB

Verify correctness of an approach using loop invariants or mathematical proofs.

analyze_complexityB

Rigorously calculate time and space complexity of code.

generate_testcasesC

Generate sample test cases (input/output/explanation) for the problem.

generate_edge_casesC

Identify critical edge case configurations and remedies.

stress_testingB

Generate stress testing script, random generator, and brute-force checker.

review_solutionB

Review user code for correctness, time complexity, bugs, TLE risk, etc.

find_bugB

Search for logical errors, boundary flaws, or runtime bugs in the code.

optimize_solutionC

Refactor solutions to reduce runtime complexity and improve performance.

get_hintC

Provide progressive hints for the problem.

explain_algorithmC

Explain the mechanics of a specific algorithm / data structure.

recommend_next_problemB

Recommend next problems that build upon this problem.

Prompts

Interactive templates invoked by user choice

NameDescription
hints_onlyCompetitive programming coach persona that only gives progressive hints. No code.
contest_modeContest mode persona: fast, clean, terse, and hyper-optimized code output.
interview_modeMock interviewer persona: explains trade-offs, edge cases, and design choices.

Resources

Contextual data attached and managed by the client

NameDescription
dijkstra_resourceDijkstra's shortest path algorithm reference.
segment_tree_resourceSegment Tree data structure reference.
sliding_window_resourceSliding Window pattern reference.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/SAMI-CODEAI/MCP-Server-For-Competitive-Programming'

If you have feedback or need assistance with the MCP directory API, please join our Discord server