fsm_transition
Advance a named finite state machine to a new state and record the transition with optional metadata, enabling state management in multi-agent workflows.
Instructions
Advance a named FSM (Finite State Machine) to a new state and record the transition on the blackboard. Transitions are irreversible via this tool — new_state is written directly without validating against a predefined state graph, so the caller must ensure the transition is valid. Returns {ok:true, fsmId, transition:{from, to}, blackboardWritten:true} on success. Returns {ok:false, error:"..."} if fsm_id, new_state, or agent_id is missing, or if metadata_json is not valid JSON. Avoid concurrent transitions to the same FSM from multiple agents; call orchestrator_info first to read the current FSM state before transitioning.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"fsm_id": "<fsm_id>",
"new_state": "<new_state>",
"agent_id": "<agent_id>"
},
"name": "fsm_transition"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fsm_id | Yes | FSM identifier (e.g. "order_pipeline", "code_review_workflow") | |
| agent_id | Yes | Agent performing the transition (for audit) | |
| new_state | Yes | The state to transition to | |
| metadata_json | No | Optional JSON metadata to attach to the transition |