Out-of-the-box MCP (Model Context Protocol) integration for OpenClaw. This project provides automated setup of Sequential Thinking and Context7 MCP servers, including an OpenClaw plugin that invokes Sequential Thinking on every conversation turn.
-
Sequential Thinking (adaptive): A plugin that assesses message complexity using 6 universal heuristic signals and routes to one of 5 thinking depth levels (skip, light, standard, deep, intensive). Simple messages like greetings are skipped entirely, saving resources. Complex requests trigger multi-step agent-driven thinking with configurable depth budgets.
-
Context7 (conditional): Configures the Context7 documentation server and provides policy hints so the agent uses it when technical library lookups are needed -- not on every turn.
git clone https://github.com/keoy7am/openclaw-mcp-bootstrap.git
cd openclaw-mcp-bootstrap
chmod +x scripts/*.sh
./scripts/install.shThe installer will:
- Check prerequisites (openclaw, mcporter, node)
- Install MCP server packages globally
- Configure
mcporter.jsonwith both MCP servers - Copy the plugin to your OpenClaw workspace
- Register the plugin in
openclaw.json - Run verification checks
After installation, restart the gateway:
openclaw gateway restart| Dependency | Version | Install |
|---|---|---|
| Node.js | >= 18 | https://nodejs.org/ |
| OpenClaw | >= 2026.2.22 | npm install -g openclaw@latest |
| mcporter | latest | https://github.com/steipete/mcporter |
| jq | any | https://jqlang.github.io/jq/ |
openclaw-mcp-bootstrap/
|-- extensions/
| +-- seq-deep-integration/ Plugin source
| |-- index.ts Hook: before_prompt_build
| +-- openclaw.plugin.json Manifest with configSchema
|-- config/
| +-- mcporter.example.json MCP server configuration template
|-- scripts/
| |-- install.sh Full automated installer
| |-- configure-mcp.sh MCP server configuration only
| +-- verify.sh Post-install verification
|-- docs/
| |-- SETUP-SEQUENTIAL.md Sequential Thinking setup details
| |-- SETUP-CONTEXT7.md Context7 setup details
| |-- COMPLEXITY-ASSESSMENT.md Complexity scoring algorithm reference
| +-- OPENCLAW-JSON-REFERENCE.md Plugin configuration reference
|-- prompts/
| +-- agent-mcp-policy.md Agent prompt templates for MCP usage
|-- README.md This file (English)
|-- README.zh-TW.md Traditional Chinese
|-- README.zh-CN.md Simplified Chinese
+-- LICENSE MIT
The seq-deep-integration plugin registers a before_prompt_build hook:
- Extracts the last user message from the conversation
- Assesses complexity using 6 universal heuristic signals (message length, question marks, multi-part separators, action verbs, analytical patterns)
- Routes to the appropriate depth level (skip / light / standard / deep / intensive) based on a weighted score
- For skip: no injection, no MCP call
- For light: runs a single-thought pre-analysis via MCP (like v1)
- For standard / deep / intensive: injects a
[SEQ-ASSESSMENT]tag with depth guidance for the agent to drive multi-step thinking - Optionally suggests Context7 usage when technical keywords are detected
Assessment results are cached (TTL-based dedup) and logged in JSONL format for observability.
If you prefer to configure manually instead of using the installer:
-
Install MCP server packages:
npm install -g @modelcontextprotocol/server-sequential-thinking npm install -g @upstash/context7-mcp
-
Add servers to your
mcporter.json:./scripts/configure-mcp.sh --workspace /path/to/workspace
-
Copy the extension:
cp -r extensions/seq-deep-integration/ \ <workspace>/.openclaw/extensions/seq-deep-integration/
-
Register in
openclaw.json:{ "plugins": { "allow": ["seq-deep-integration"], "entries": { "seq-deep-integration": { "enabled": true } } } } -
Restart:
openclaw gateway restart
./scripts/verify.shChecks: command availability, extension files, mcporter configuration, openclaw.json entries, and MCP server connectivity.
- Sequential Thinking Setup
- Context7 Setup
- Complexity Assessment
- openclaw.json Reference
- Agent MCP Policy Prompts
Contributions are welcome. Please open an issue or pull request.