Skip to content

operative

diapason.agents.operative

OperativeAgent — persistent, scheduled agent for autonomous operation.

Extends ToolUsingAgent with built-in session persistence and state recall. Designed for Operators: autonomous agents that run on a schedule with automatic state management between ticks.

OperativeAgent

Bases: ToolUsingAgent

Persistent autonomous agent with built-in state management.

The Operative agent extends the standard tool-calling loop with:

  1. Session loading — restores conversation history from previous ticks.
  2. State recall — retrieves previous state JSON from memory backend.
  3. System prompt — injects the operator's protocol instructions.
  4. Tool loop — standard function-calling loop (same as Orchestrator).
  5. Session save — persists the tick's prompt and response.
  6. State persistence — auto-persists state if the agent didn't do it explicitly via memory_store tool.

run(input, context=None, **kwargs)

Execute a single operator tick.