--title=Actor model: Integration with agentd

t-363.5·WorkTask·
·
·
Parent:t-363·Created1 month ago·Updated1 month ago

Dependencies

Description

Edit

Integrate actor model with existing agentd infrastructure.

Overview

This is Phase 5 of the actor-native agent orchestration system. Connect the actor primitives to existing agentd components: workflows, events, watch, and CLI.

Requirements

Workflow YAML Compatibility

Existing workflow YAML continues to work. It becomes sugar for actor operations:

steps:
  - name: research
    run: research.md
  - name: implement
    run: implement.md

Equivalent to a root actor that: 1. Creates child for research, waits for result 2. Creates child for implement with research context, waits for result 3. Sends final result to customer

CLI Changes

# Run a single task (spawns root actor)
agentd run task.md

# Run a workflow (spawns root actor that follows workflow)
agentd run workflow.yaml

# Watch now shows actor graph
agentd watch

# Watch specific actor and descendants
agentd watch actor-id

Event Integration

New event types for actor operations:

  • actor_create - actor spawned child (parent_id, child_id, capabilities)
  • actor_send - actor sent message (from, to, customer, payload summary)
  • actor_receive - actor received message (actor_id, message_id)
  • actor_become - actor changed behavior (actor_id, new_behavior summary)
  • actor_complete - actor finished (actor_id, result summary)

Events go to existing _/events/{run_id}.jsonl system.

Watch Integration

  • Show actor tree, not just flat runs
  • Display message flow between actors
  • Show capability budgets (cost remaining, children remaining)
  • Termination: watch exits when actor graph fully drained

System Prompt

Every actor receives actor-aware system prompt additions:

  • Your actor_id
  • Your parent_id (if not root)
  • Your customer_id
  • Your capabilities summary
  • Instructions for using send, create, become

Entry Point

  • Human runs agentd with a task
  • System creates root actor with full capabilities
  • Root receives initial message with task
  • Computation proceeds via message passing
  • System terminates when root completes and graph drains

Implementation Notes

Files to modify

  • Omni/Agentd.hs - CLI, workflow->actor translation, root actor creation
  • Omni/Agent/Events.hs - New event types
  • Omni/Agent/Watch.hs - Actor graph display
  • Omni/Agent/Prompts/ - Actor system prompt additions

Testing

  • Test workflow YAML still works
  • Test single task.md works
  • Test events capture actor operations
  • Test watch shows actor graph
  • Test termination detection

Dependencies

  • Task: Actor model: Message passing infrastructure
  • Task: Actor model: CREATE primitive
  • Task: Actor model: BECOME primitive
  • Task: Actor model: Capability enforcement

References

  • Spec: _/llm/actors.md (Integration section, Compatibility section)
  • Current workflow: Omni/Agentd.hs
  • Events: Omni/Agent/Events.hs

Timeline (2)

🔄[human]Open → InProgress1 month ago
🔄[human]InProgress → Done1 month ago