Cyclium.Strategy.Template.AgenticTask (Cyclium v0.3.4)

Copy Markdown View Source

Strategy template for an autonomous, tool-calling episode — the same interpret → validate → execute → summarize loop as Cyclium.Strategy.Template.Interactive, but with no human in the loop.

Instead of a conversation turn, the run is seeded from an objective and the triggering payload; the LLM then plans, calls tools as it sees fit (bounded by allowed_tool_signatures), and terminates by calling the reserved finish_agentic_task tool with its conclusion. The episode converges to findings and/or outputs.

context_assembly  interpret  validate  [preview]  execute  summarize
                                  __________________________________|
                         (loop until the model calls finish_agentic_task)

Objective (static + payload)

The objective is a template string, interpolated against the trigger payload with {{key}} / {{a.b}} placeholders:

strategy_config: %{
  objective: "Review resource {{resource_id}} for over-allocation and raise a finding if it is over limit.",
  role: "You are an operations analyst.",
  guidelines: ["Use read tools to gather evidence before concluding."],
  allowed_tool_signatures: [ ... ]
}

A trigger payload may also carry its own "objective" string, which takes precedence over the static template (still interpolated against the payload).

Termination

The reserved finish_agentic_task tool is auto-injected into the tool menu (the app does not declare it). Calling it ends the run; its args become the converge result:

{"tool": "finish_agentic_task", "action": "finish_agentic_task", "args": {
  "summary": "...",
  "confidence": 0.9,
  "findings": [{"action": "raise", "class": "over_limit", "summary": "...", ...}],
  "outputs":  [{"type": "slack", "dedupe_key": "...", "payload": {...}}]
}}

If the model instead stops with a plain-text answer (explain_only), that text becomes the summary and the episode converges without findings.

Security

With no human preview by default, allowed_tool_signatures is the entire security boundary — keep it as narrow as the task needs, and prefer read-only signatures unless a write is genuinely required. See the interactive-actors guide's Security section; the same reasoning applies here.