Skip to content

feat(mcp): add @modelcontextprotocol/server-sequential-thinking as a builtin MCP#4317

Open
YOMXXX wants to merge 1 commit into
code-yeongyu:devfrom
YOMXXX:feat/builtin-sequential-thinking-mcp
Open

feat(mcp): add @modelcontextprotocol/server-sequential-thinking as a builtin MCP#4317
YOMXXX wants to merge 1 commit into
code-yeongyu:devfrom
YOMXXX:feat/builtin-sequential-thinking-mcp

Conversation

@YOMXXX
Copy link
Copy Markdown
Contributor

@YOMXXX YOMXXX commented May 23, 2026

Summary

Adds @modelcontextprotocol/server-sequential-thinking to the builtin MCP set as sequential_thinking. The server exposes one tool — sequentialthinking — that lets a model externalise a multi-step plan and revise individual steps without burning thinking-budget tokens.

Why

Most useful for the small no-thinking-mode models on omo's fallback chains (gpt-5-nano, minimax-m2.7, kimi-k2.x etc.). Without thinking-mode support, those models have nowhere to stash partial reasoning between tool calls and tend to either skip planning or hallucinate it back from scratch each turn. The official sequential-thinking server gives them an explicit scratchpad that survives tool round-trips.

Follows the same wiring pattern as the existing server-memory PR (#4286).

Changes

  • src/mcp/server-sequential-thinking.ts — thin factory wrapping the stateless server behind npx -y @modelcontextprotocol/server-sequential-thinking. Returns enabled: false when npx is missing so we never schedule a launch that would die on the first request.
  • src/mcp/types.ts — extend McpNameSchema with sequential_thinking so disabled_mcps: [\"sequential_thinking\"] is recognised as a known builtin name (not just a free-form string).
  • src/mcp/index.ts — register it in createBuiltinMcps, behind the same disabled_mcps gate the other builtins use.
  • src/cli/doctor/checks/tools-mcp.ts — include it in BUILTIN_MCP_SERVERS so omo doctor does not flag it as an unknown external MCP.
  • Testsserver-sequential-thinking.test.ts (4 cases: happy path, missing-npx fallback, stateless-environment invariant, default-resolver branch) and an extension of zauc-mocks-mcp-index/index.test.ts to mock the new factory and lock the registration through every createBuiltinMcps scenario.
  • Docsdocs/reference/configuration.md and src/mcp/AGENTS.md list the new builtin alongside the others.

Test plan

  • bun test src/mcp — 40 pass, 0 fail
  • bun test src/mcp src/cli/doctor src/config — 222 pass, 0 fail across 32 files
  • Manual: disabled_mcps: [\"sequential_thinking\"] removes it from createBuiltinMcps output without touching the other builtins.
  • Manual: missing-npx environments produce { enabled: false } rather than a broken launch attempt.

Notes

The server is stateless — no env vars, no on-disk state, no per-project setup. If the package isn't already cached, npx -y warms it up on first request. Users who don't want the auto-launch can opt out with disabled_mcps: [\"sequential_thinking\"].

If both this PR and #4286 (server-memory) land, the builtin MCP roster grows from 5 to 7. No conflict between the two diffs — they touch disjoint files except src/mcp/types.ts and src/mcp/index.ts, both of which are append-only additions.


Summary by cubic

Adds @modelcontextprotocol/server-sequential-thinking as a built-in MCP named sequential_thinking to give models a scratchpad for multi-step plans via the sequentialthinking tool. This helps small no-thinking-mode models persist plans across tool calls.

  • New Features
    • Launches the stateless server via npx -y; auto-disables when npx isn’t available.
    • Registered in createBuiltinMcps; McpNameSchema extended; omo doctor recognizes it; docs updated. Opt out with disabled_mcps: ["sequential_thinking"].
    • Tests cover launch, missing npx, stateless env, and default resolver; registration tests updated.

Written for commit 4217e04. Summary will update on new commits. Review in cubic

…builtin MCP

Wires the official server-sequential-thinking package into the builtin
MCP set with the name "sequential_thinking". The server exposes one
tool (`sequentialthinking`) that lets a model externalise a multi-step
plan and revise individual steps without burning thinking-budget
tokens — most useful for the small no-thinking-mode models on the
fallback chains (gpt-5-nano, minimax, kimi etc.), where the model has
nowhere else to stash partial reasoning between tool calls.

- `src/mcp/server-sequential-thinking.ts`: thin factory wrapping the
  stateless server behind `npx -y`; falls back to `enabled: false`
  when npx is missing so we never schedule a launch that would error
  on the first request.
- `src/mcp/types.ts`: extend `McpNameSchema` with `sequential_thinking`
  so `disabled_mcps: ["sequential_thinking"]` is recognised as a known
  builtin name.
- `src/mcp/index.ts`: register it in `createBuiltinMcps`, behind the
  same disabled_mcps gate the other builtins use.
- `src/cli/doctor/checks/tools-mcp.ts`: include it in
  `BUILTIN_MCP_SERVERS` so `omo doctor` does not flag it as an unknown
  external MCP.
- Tests: new `server-sequential-thinking.test.ts` covers the happy
  path, missing-npx fallback, stateless-environment invariant, and
  the default-resolver branch; `zauc-mocks-mcp-index/index.test.ts`
  is updated to mock the new factory and assert the registration
  through every `createBuiltinMcps` scenario.
- Docs: `docs/reference/configuration.md` and `src/mcp/AGENTS.md` list
  the new builtin alongside the others.
@KennyDizi
Copy link
Copy Markdown

I don't think this is a good idea, the MCP @modelcontextprotocol/server-sequential-thinking is already deprecated.

@YOMXXX
Copy link
Copy Markdown
Contributor Author

YOMXXX commented May 23, 2026

Thanks for raising the concern! I dug into it before opening this PR and the package looks actively maintained rather than deprecated:

  • npm latest: 2025.12.18 (published 2025-12-18, metadata still updated 2026-02-06).
  • Source still lives in the main modelcontextprotocol/servers repo under src/sequentialthinking/ — it was not moved to modelcontextprotocol/servers-archived (the path returns 404 there).
  • Same install pattern (npx -y @modelcontextprotocol/server-sequential-thinking) is still documented in the upstream README for Claude Desktop, VS Code, and Codex CLI.

If you have a link or thread showing it's deprecated (e.g. a maintainer announcement, an issue I missed, or a successor package), I'd happily switch this PR over to the recommended replacement. Otherwise this aligns with how PR #4286 added @modelcontextprotocol/server-memory — same registry, same publisher, same install shape.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants