home / mcp / mcp dual-cycle reasoner mcp server
A MCP server implementing the Dual-Cycle Metacognitive Reasoning Framework for autonomous agents. A loop prevention and experience recall mechanism.
Configuration
View docs{
"mcpServers": {
"cyqlelabs-mcp-dual-cycle-reasoner": {
"command": "npx",
"args": [
"@cyqlelabs/mcp-dual-cycle-reasoner"
]
}
}
}You use the MCP Dual-Cycle Reasoner to give autonomous agents metacognitive capabilities. It monitors cognitive processes, detects loops or stagnation, and learns from past experiences to improve decision making. This server enables self-awareness, reliability, and smarter adaptation through sentinel-style anomaly detection and adjudicator-driven case management.
To use this MCP server with your client, install the server locally or run it via a compatible MCP client. Start monitoring an agent’s goal, feed it cognitive traces, and let the system detect loops or anomalies. When a loop is detected, the system returns an intervention plan and details to guide your recovery actions. You can store successful experiences and retrieve similar cases to inform future decisions. Use the provided tools to monitor, detect loops, configure detection, and manage experiences.
Prerequisites: Ensure you have Node.js installed (version 14+ is recommended) and npm available in your environment.
1. Clone the project folder to your local machine.
2. Install dependencies.
git clone https://github.com/cyqlelabs/mcp-dual-cycle-reasoner.git
cd mcp-dual-cycle-reasoner3. Build the project.
npm install
npm run build4. Run the server in HTTP stream mode (default). The server will listen on port 8080.
npm start5. If you prefer stdio transport, run the server with the stdio option.
npm start -- --stdioTo connect a client, configure your MCP client with the runtime command for the dual-cycle reasoner. The example below demonstrates a standard MCP client setup that uses a local stdio command.
{
"mcpServers": {
"dual_cycle_reasoner": {
"command": "npx",
"args": ["@cyqlelabs/mcp-dual-cycle-reasoner"]
}
}
}Once the server is running, you can initialize monitoring for an agent, send cognitive trace updates, and store or retrieve experiences to guide behavior.
- The system supports flag options to switch between detection methods (statistical, pattern, hybrid) and to adjust thresholds for progress indicators and repetitions.
- Use the experience management tools to curate a library of past problems and solutions, enabling faster recovery from similar situations in the future.
Initialize metacognitive monitoring of an agent's cognitive process.
Process cognitive trace updates from the agent to assess progress and detect loops.
Stop monitoring and obtain a session summary.
Detect if the agent is stuck in a loop using statistical, pattern, or hybrid strategies.
Configure detection parameters and domain-specific progress indicators.
Store a case for future case-based reasoning with enhanced metadata and quality scoring.
Retrieve similar cases using semantic matching and filtering.
Get the current monitoring status and statistics.
Reset the dual-cycle engine state.