← Back to Articles & Artefacts
artefactswest

Anemoi A2A Research Synthesis

IAIP Research
jg251227-inquiries-sessions-session-management-ea-dm2xrcxsqcehjjjjlwtwig

Anemoi A2A Research Synthesis

Date: 2025-12-30 Source: Perplexity Research (CONTENT.md)


Key Findings

1. Anemoi Architecture

Thread-based communication via MCP server with 5 primitives: ``` list_agents() → Discover available agents create_thread(P_0) → Initialize conversation context send_message(τ, msg) → Broadcast/directed message wait_for_mentions(τ) → Block until mentioned (real-time awareness) close_thread(τ) → Terminate with outcome logging ```

Performance: +9.09% on GAIA benchmark vs centralized approaches (OWL, CAMEL, AutoGen)

2. Scenario-Pattern Mapping

ScenarioBest PatternEffortWhy
A: Fork ContextAgent Continuations1-2 wksJSON state blob transfers full context
B: Multi-SessionAnemoi A2A3-4 wksReal-time wait_for_mentions beats Redis polling
C: Pre-LaunchHybrid2-3 wksContinuations + A2A negotiation
D: Hook ChainAnemoi (optional)1 wkMessage instrumentation on existing hooks

3. Trade-Off Matrix

DimensionFile-Based (Now)ContinuationsAnemoi A2A
Latency50-200ms0ms (memory)5-20ms
Multi-SessionEventualManual pollReal-time
Token OverheadHighVery LowVery Low
CLI SupportNativeNativeNeeds wrapper
Effort01-2 weeks3-4 weeks

Recommendation from Perplexity

Phase 1: Agent Continuations (Immediate)

  • Replace CONTEXT.md with continuation_state.json
  • Fork operations pass state blob, not empty context
  • Solves: Context loss on fork, pre-launch isolation

Phase 2: Anemoi A2A (Parallel if capacity)

  • Deploy Anemoi MCP server
  • Replace Redis pub/sub with thread messaging
  • Solves: Multi-session coordination delay

Phase 3: Semi-Centralized (Defer)

  • Full architecture redesign
  • Wait until Phases 1-2 validated

Decision Required

Question: Which pain point is most urgent?

If...Then...
Fork context loss is blocking workStart Phase 1 immediately
Running 3+ parallel sessions oftenPrioritize Phase 2
Current system "good enough"Document patterns, defer implementation

Self-Inquiry Checklist (From Research)

Before implementing, answer:

  1. Context loss on fork: What % of parent state is needed by child?

    • <20% → File-based sufficient
    • 50%+ → Continuations essential
  2. Token waste: What % goes to redundant context injection?

    • <5% → Redis webhooks acceptable
    • >15% → Anemoi threading worthwhile
  3. Pre-launch clarification: How often does main session need more from pre-launch?

    • Rarely → One-shot acceptable
    • >30% → Bidirectional negotiation valuable
  4. MCP server maturity: Already running iaip/coaia MCPs?

    • Yes → A2A server is low-friction
    • No → Requires SDK setup (2-3 days)
  5. Shell script integration: Must LAUNCH__*.sh stay in loop?

    • Yes → Anemoi needs API wrapper
    • No → Native support available

Implementation Artifacts Needed

For Phase 1 (Continuations)

  • Modify newsessionuuid to generate continuation JSON
  • Update miette_newsession_context.sh to write continuation (not CONTEXT.md)
  • Add --context flag handling to launcher scripts
  • Test fork/resume with state preservation

For Phase 2 (Anemoi A2A)

  • Deploy Anemoi MCP server (or reference implementation)
  • Add to .mcp-config as anemoi-a2a
  • Replace Redis webhook with send_message(τ, ...)
  • Add thread instrumentation to v2_claude_hooks
  • Test multi-session scenarios

References