Skip to main content
Glama
mettamatt

Code Reasoning MCP Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
DEBUGNoEnable detailed logging when set to truefalse

Tools

Functions exposed to the LLM to take actions

NameDescription
code-reasoning

🧠 Code Reasoning Tool (using sequential thinking)

Purpose → break complex problems into self-auditing, exploratory thought steps that can branch, revise, or back-track until a single, well-supported answer emerges.


WHEN TO CALL

• Multi-step planning, design, debugging, or open-ended analysis
• Whenever further private reasoning or hypothesis testing is required before replying to the user


ENCOURAGED PRACTICES

šŸ” Question aggressively – ask "What am I missing?" after each step
šŸ”„ Revise freely – mark is_revision=true even late in the chain
🌿 Branch often – explore plausible alternatives in parallel; you can merge or discard branches later
ā†©ļø Back-track – if a path looks wrong, start a new branch from an earlier thought
ā“ Admit uncertainty – explicitly note unknowns and schedule extra thoughts to resolve them


MUST DO

āœ… Put every private reasoning step in thought
āœ… Keep thought_number correct; update total_thoughts when scope changes
āœ… Use is_revision & branch_from_thought/branch_id precisely
āœ… Set next_thought_needed=false only when all open questions are resolved
āœ… Abort and summarise if thought_number > 20


DO NOT

ā›”ļø Reveal the content of thought to the end-user
ā›”ļø Continue thinking once next_thought_needed=false
ā›”ļø Assume thoughts must proceed strictly linearly – branching is first-class


PARAMETER CHEAT-SHEET

• thought (string) – current reasoning step
• next_thought_needed (boolean) – request further thinking?
• thought_number (int ≄ 1) – 1-based counter
• total_thoughts (int ≄ 1) – mutable estimate
• is_revision, revises_thought (int) – mark corrections
• branch_from_thought, branch_id – manage alternative paths
• needs_more_thoughts (boolean) – optional hint that more thoughts may follow

All JSON keys


EXAMPLE āœ”ļø

{ "thought": "List solution candidates and pick the most promising", "thought_number": 1, "total_thoughts": 4, "next_thought_needed": true }

EXAMPLE āœ”ļø (branching late)

{ "thought": "Alternative approach: treat it as a graph-search problem", "thought_number": 6, "total_thoughts": 8, "branch_from_thought": 3, "branch_id": "B1", "next_thought_needed": true }

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

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/mettamatt/code-reasoning'

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