AlexandrAI AGENTS.md
agents-md

LMSSEP Sequential Thinking MCP Server Agent Guide

Project-specific AGENTS.md guidance for the LMSSEP Sequential Thinking MCP server, thought sequencing, revisions, branching, action flags, and session hygiene.

AGENTS.md

Guidance for coding agents working on LMSSEP Sequential Thinking MCP Server. This server provides a single structured-thinking tool for progressive software analysis.

Project overview

The server registers the st tool. It records ordered thoughts, supports revisions, supports branches from earlier thoughts, tracks whether more thinking is needed, and can mark a thought as requiring a concrete action. It is meant for software development, system architecture, API design, database optimization, security analysis, performance analysis, and refactoring strategy.

Setup commands

bashcd <project-root>/genesis/LMSSEP/sequential_thinking
pip install -r requirements.txt
python main.py

Configure runtime behavior through environment variables such as MCP_SERVER_NAME, MCP_SERVER_VERSION, MCP_TRANSPORT, MCP_LOG_LEVEL, and MCP_HTTP_PORT. Use <PORT> in public docs; do not publish local endpoint values.

Tool contract

st takes the current thought, thought_number, total_thoughts, and next_thought_needed. Optional fields include is_revision, revises_thought, branch_from_thought, branch_id, needs_more_thoughts, action_required, action_type, and action_description.

Use revisions when a prior assumption becomes wrong. Use branches when two viable designs need parallel comparison. Use action flags only when the next step is concrete enough to execute.

Code map

  • main.py creates the FastMCP server and registers the tool.
  • configs/config.py holds server configuration and output directory setup.
  • src/tools/sequential_thinking.py owns validation, session state, branch tracking, and result formatting.
  • src/utils/session_persistence.py provides reusable session persistence helpers.

Testing and verification

Verify a straight-line thought sequence, a revision, a named branch, and an action-required thought. Confirm the returned history length, branch list, adjusted total-thought count, and session id behavior.

Safety and output hygiene

Do not let a thinking trace replace verification. Any action suggested by action_description still needs normal tool execution and tests. Keep session output and logs free of secrets, private endpoints, and local machine paths.

Commit and PR rules

Changes to input validation, branch behavior, or action flags need focused examples in the PR. Keep the single-tool interface stable unless there is a migration note for downstream clients.