MCP.so
Sign In
C

Cotforce Mcp

@islobodan

About Cotforce Mcp

Give brains to your small models. MCP server that enforces step-by-step Chain-of-Thought — turns 4B models into methodical reasoners

Basic information

Category

Other

Transports

stdio

Publisher

islobodan

Submitted by

Slobodan Ivković

Config

Add this server to your MCP-compatible client using the configuration below.

{
  "mcpServers": {
    "cotforce": {
      "command": "npx",
      "args": [
        "-y",
        "@slbdn/cotforce-mcp"
      ],
      "env": {
        "MODE": "direct",
        "API_BASE_URL": "http://localhost:1234/v1",
        "MODEL": "local-model",
        "MAX_RETRIES": "2"
      }
    }
  }
}

Tools

No tools detected

We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.

Overview

What is Cotforce Mcp?

Cotforce Mcp is a Model Context Protocol server that enforces step-by-step Chain-of-Thought (CoT) reasoning on any LLM call. It integrates with MCP clients (Claude Desktop, Cursor) via sampling or with any OpenAI‑compatible API via direct HTTP. It is designed for users who want to improve reasoning in small or large language models without fine‑tuning.

How to use Cotforce Mcp?

Install the npm package @slbdn/cotforce-mcp (requires Node.js ≥18). Configure via environment variables in your MCP client settings. Add a server entry like "cotforce": { "command": "npx", "args": ["-y", "@slbdn/cotforce-mcp"], "env": { "MODEL": "claude-3-5-sonnet" } } to claude_desktop_config.json. Then call the solve_problem tool with a prompt argument.

Key features of Cotforce Mcp

  • Rigid CoT enforcement with valid JSON output
  • Adaptive multi‑layer parser pipeline (5 built‑in parsers)
  • Zod runtime validation for tool arguments and CoT results
  • Automatic retry with increasing temperature (up to 3 attempts)
  • Token budgeting with tiktoken and configurable overhead
  • Model‑specific system prompts for Claude, GPT‑4, Gemini, Grok
  • Structured metrics and comprehensive test suite (151 tests)

Use cases of Cotforce Mcp

  • Solving complex cryptarithmetic puzzles like SEND + MORE = MONEY with small models
  • Improving reasoning on math, logic, and word problems
  • Performing code analysis, regex generation, and SQL queries with structured output
  • Validating results against a user‑supplied schema with automatic retry

FAQ from Cotforce Mcp

What LLMs does Cotforce Mcp work with?

It works with any LLM accessible via MCP sampling or direct HTTP, including Claude, GPT‑4, Gemini, Grok, and local models via LMStudio or Ollama.

What are the runtime requirements?

Cotforce Mcp requires Node.js ≥18. For direct HTTP mode, no additional services are needed if you provide an API key or use a local endpoint.

How do I handle truncated responses mid‑reasoning?

Increase REASONING_OVERHEAD (default 800) or reduce parsers via COT_PARSERS to save token budget for reasoning.

Why does my MCP client time out before getting a result?

Complex CoT reasoning can take 60–90 seconds. Increase Cotforce’s TIMEOUT variable and also check your MCP client’s own timeout setting (e.g., LM Studio, Cursor).

How does Cotforce Mcp enforce structured output?

It uses strict system prompts with few‑shot examples, a priority‑sorted parser pipeline, and Zod schemas to extract and validate {reasoning, result} JSON from any LLM response.

Comments

More Other MCP servers