feat: launch Relayflow agents from personas
Merged
KH
4mo ago+1318+1318+0123456789012345678901234567890123456789-59-59-01234567890123456789
Summary
- let Relayflow agent definitions use
personain place ofcli+role, in YAML and the TypeScript builder - resolve ids and JSON paths through
@agentworkforce/persona-registry, then prepare skills, MCP servers, sidecars, harness settings, model, and isolated autosync mount through persona-kit in process - layer each workflow step task over the persona's standing instructions
- require broker
worker_readyplus authoritative agent inventory before continuing, releasing the worker and disposing its prepared runtime on any failure - keep raw CLI and non-interactive process paths explicit and type-safe
This is the Relayflows part of https://github.com/AgentWorkforce/workforce/issues/306. It does not shell out to agentworkforce.
Verification
- primitive builds — exit 0
- core TypeScript check — exit 0
- persona runtime, builder, and workflow-runner tests — 79 passed
- full core suite — not passing: 805 passed and 8 baseline
run-scripttests failed because this checkout has notsxbinary and theirnpx tsxfallback exited 127 - staged whitespace, secret-pattern, and home-path scans — 0 findings
Stack / blockers
Depends on AgentWorkforce/workforce#307 and the subsequent Workforce 4.1.38+ publication. @agentworkforce/persona-registry and the persona-kit autosync contract are not published yet, so a clean install/lock refresh is intentionally blocked until that upstream release; the local validation used the checked-out Workforce packages.
Summary by cubic
Launch Relayflow agents directly from AgentWorkforce personas to simplify config and run with the persona’s harness, model, and settings. Adds strict schema and template validation, and waits for runtime readiness and broker registration before executing steps.
-
New Features
- Add
personato agent config and builder (agent('name', { persona: 'id' })) as an alternative tocli. Resolve and activate personas via@agentworkforce/persona-registryand@agentworkforce/persona-kit, installing skills and launching in an isolated autosync mount; layer workflow tasks over standing instructions. - Wait for broker
worker_ready, verify registration via inventory, then proceed; dispose the persona runtime and release the worker on failure. - Validation and guardrails across YAML/schema/templates: require exactly one of
cliorpersona; persona agents are interactive-only and cannot setrole,preset, orconstraints.model; template loader rejects malformedcli/personavalues; persona agents are blocked from non-interactive paths (process backend, diagnostics).
- Add
-
Migration
- YAML: use
persona: <id>instead ofcli/role; do not combine withcli,role, orpreset; do not setconstraints.model; personas must be interactive (do not useinteractive: false). - Requires Workforce 4.1.38+ (
@agentworkforce/persona-kit,@agentworkforce/persona-registry).
- YAML: use