New Agent wizard

Four-step creation: Mission → Tools & Knowledge → Behavior → Review.

Route: /app/agents/new. Resume in-progress work with /app/agents/new?draft={uuid}.

Step 1 — Mission

  • Agent display name and mission statement.
  • Derive tasks — POST /v1/ai-agents/{slug}/derive-tasks when mission ≥ 12 characters (LLM or heuristic fallback).
  • Edit derived rows — name, example utterance, needs[], tool bindings, optional SENSITIVE/FALLBACK flag.

Step 2 — Tools & Knowledge

Checkbox grid from GET /v1/workspace-tools. Sensitive tools are flagged. Knowledge sources are typically added after create on the Knowledge tab.

Step 3 — Behavior

  • Persona — title, tone chips, voice, boundaries.
  • Limits — max_tool_calls_per_turn, max_llm_steps_per_conv.
  • Cost — daily_spend_cap_cents (BUDGET guardrail uses running spend).
  • Guardrails — optional rows before create; server also seeds five defaults on create.

Draft autosave

Field changes debounce (~1.5s) to POST/PATCH /v1/ai-agent-drafts. Indicator shows saving / saved / error. Successful POST /v1/ai-agents deletes the draft and redirects to Brain.

Step 4 — Review & create

POST /v1/ai-agents with nested tasks[], tools[], guardrails[], persona, and budget caps. New agents start in draft status until you publish from the Deploy tab.