Skip to content

Design discussion: graph-scoped agent signals and general inter-agent communication #2595

Closed as not planned

Description

@ARE404

Problem

Maka's Agent Graph already provides durable scheduling, operator Sessions, runtime-event-backed records, downstream handoff, reconciliation, and supervisor wakes. That gives the graph a clear control plane for dependency-driven work.

The boundary is less clear for interactions that are not naturally modeled as a final upstream result or a predefined dependency edge, for example:

  • an operator emits a partial or typed notification that may affect the next scheduling decision;
  • an operator needs to report an exception or changed assumption before completing;
  • a long-lived operator wants to notify another logical operator asynchronously;
  • a workflow needs interruption or coordination without turning every interaction into polling.

Today these cases can potentially be represented with output records, graph edges, and supervisor reconciliation. Maka does not appear to expose a general agent-addressed inbox or send-message primitive. It would be useful to clarify whether this is an intentional architectural boundary or an area planned for expansion.

A central design question is whether communication should remain graph-scoped and supervisor-controlled, or whether Maka intends to support general bidirectional inter-agent communication. Arbitrary directed messages—especially when they can wake the recipient—would effectively introduce a second scheduling/control plane similar to an actor mailbox.

Desired outcome

Discuss and document Maka's intended direction, and consider a narrowly scoped Agent Graph extension if it fits the architecture.

One possible graph-scoped capability would be a durable signal/event that:

  • is emitted by an operator and persisted in the existing runtime/event ledger;
  • addresses only the root supervisor, a declared graph operator, or a declared graph edge;
  • carries bounded inline data plus artifact/event references;
  • remains visible to graph audit, replay, and recovery;
  • does not silently bypass graph admission or scheduling policy;
  • has explicit semantics for whether it merely wakes the supervisor or may directly activate a target operator.

Questions for the maintainers:

  1. Is general bidirectional agent-to-agent communication part of Maka's roadmap or intended model?
  2. Should Agent Graph remain the sole scheduling authority, with signals only informing the root supervisor?
  3. Would a graph-scoped signal be useful beyond the existing record/handoff and supervisor-wake mechanisms?
  4. If direct recipient wake is allowed, should Maka treat that explicitly as a durable mailbox/actor subsystem?
  5. What guarantees would be expected around identity, ordering, deduplication, delivery, backpressure, cancellation, permissions, and restart recovery?
  6. Should communication be restricted to one graph/root execution, or eventually work across independent Runtime Hosts?

The desired result does not need to be a specific API immediately. A documented architectural decision and explicit non-goals would already make future Graph extensions easier to evaluate.

Alternatives or workarounds

  • Model every interaction as an Agent Graph record and explicit dependency edge.
  • Wake the root supervisor at useful checkpoints, then let it inspect records and revise the schedule.
  • Poll shared artifacts or runtime state from downstream operators.
  • Add a general agent_notify(targetSessionId, ...) or mailbox API. This is flexible, but arbitrary bidirectional notification plus direct wake would need to be designed as a full communication and scheduling subsystem rather than a small helper.

Related exploration: https://github.com/nicobailon/pi-intercom

Activity

  1. somewan820 commented on Aug 14, 2026

    @somewan820
    Contributor

    Thanks for laying out the design question clearly. Since I'm coordinating #2290 (Task Ledger) and #2560 (Work Board), here is my recommended position. Everything below is a proposal, not a settled contract.

    Current-code context

    • Agent Graph already has durable scheduling, supervisor wakes, operator/edge identity, and RuntimeEvent-backed records; I did not find a general agent-addressed signal or mailbox in main.
    • claim / settle on the Task Ledger is an ownership protocol (packages/storage/src/task-ledger-store.ts:386,468), not a notification mechanism. A signal is not the same abstraction.

    Recommendation

    1. Agent Graph remains the sole scheduling authority. General bidirectional agent-to-agent messaging with direct wake is effectively a mailbox/actor subsystem and should be a non-goal for now.
    2. A narrowly scoped, graph-scoped signal is worth considering. It would be:
      • durable and persisted in the existing RuntimeEvent ledger;
      • emitted by an operator;
      • addressable only to the root supervisor or declared Graph operators/edges;
      • bounded in payload, with artifact/event references rather than arbitrary content;
      • visible to Graph audit, replay, and recovery;
      • unable to bypass Graph admission or scheduling policy.
    3. In v1, signals inform the root supervisor only. They may wake the supervisor and let it revise the schedule; they do not directly activate a target operator. Direct recipient wake should be deferred until we explicitly decide to build a mailbox subsystem.
    4. A signal is not a replacement for claim / settle as an ownership protocol. Ownership, lease, retry, stale-claim handling, and settlement belong to Agent Graph. A signal could replace the coordination role Task Ledger's claim / settle played, but only because Graph owns the actual semantics; the signal itself is just the communication channel.
    5. waiting_for_user should be representable as a Graph/session continuation fact, not as a general message type.

    Answers to the listed questions (proposed v1 semantics; delivery guarantees still need a contract)

    • General bidirectional communication in the roadmap? Not now.
    • Graph sole scheduling authority? Yes.
    • Graph-scoped signal useful beyond existing mechanisms? Yes, for partial notifications, changed assumptions, and exceptions before completion.
    • Direct recipient wake? Only as an explicit mailbox subsystem later; not in the first cut.
    • Guarantees? Identity from Graph declarations; ordering / dedup / backpressure / cancellation / replay-recovery are proposed semantics to be specified, not commitments today.
    • Cross-Host? v1 stays graph-scoped; cross-Host communication is a separate design.

    If maintainers agree with this shape, I can draft the signal contract and explicit non-goals here. If not, the first question to settle is whether Graph should remain the sole scheduling authority.

    简体中文

    感谢把这个设计问题讲清楚。我正在统筹 #2290(Task Ledger)和 #2560(Work Board),以下是我建议的立场。所有内容都是 proposal,不是已定契约。

    当前代码上下文

    • Agent Graph 已有持久调度、supervisor wake、operator/edge 身份和 RuntimeEvent-backed records;我在 main 中没有找到通用 agent 定向 signal 或 mailbox。
    • Task Ledger 的 claim / settle 是 ownership 协议(task-ledger-store.ts:386,468),不是通知机制;signal 不是同一种抽象。

    建议

    1. Agent Graph 继续保持唯一调度权威。 支持直接唤醒的通用双向 agent 间通信,本质上是 mailbox/actor 子系统,现阶段应作为 non-goal。
    2. 范围克制的 graph-scoped signal 值得考虑。 它应该:
      • 持久化在现有 RuntimeEvent ledger 中;
      • 由 operator 发出;
      • 只能发给 root supervisor 或声明的 Graph operator/edge;
      • payload 有界,用 artifact/event 引用而不是任意内容;
      • 对 Graph audit、replay、recovery 可见;
      • 不能绕过 Graph admission 或调度策略。
    3. v1 中信号只通知 root supervisor。 可以唤醒 supervisor 并让它修订调度,但不能直接激活目标 operator。直接唤醒目标应推迟到我们明确决定构建 mailbox 子系统时。
    4. Signal 不是 claim / settle 的等价替代品。 ownership、lease、retry、stale claim 处理和 settlement 属于 Agent Graph。Signal 可以取代 Task Ledger 的 claim/settle 曾经承担的协调角色,但前提是真正语义仍由 Graph 持有;Signal 本身只是通信通道。
    5. waiting_for_user 应表示为 Graph/session continuation 事实,而不是通用消息类型。

    对所列问题的回答(提议的 v1 语义;投递保证仍需契约确认)

    • 通用双向通信进入 roadmap?现在不。
    • Graph 是唯一调度权威?是。
    • Graph-scoped signal 是否超出现有机制的价值?有,用于部分通知、假设变更和完成前的异常。
    • 直接唤醒目标?只作为未来的显式 mailbox 子系统,不在第一版。
    • 保证?身份来自 Graph 声明;ordering / dedup / backpressure / cancellation / replay-recovery 是需要定义的提议语义,不是今天的承诺。
    • 跨 Host?v1 保持 graph-scoped;跨 Host 通信是独立设计。

    如果 maintainer 认可这个形状,我可以在这里起草信号契约和明确的 non-goals。如果不认可,首先要定的问题是:Graph 是否应继续保持唯一调度权威。

  2. added
    enhancement
    on Aug 20, 2026
  3. github-actions commented on Sep 14, 2026

    @github-actions

    This issue has had no human activity for 30 days and has been marked stale. It will be closed in 30 days unless someone comments.

    If the issue is still current, please confirm it against the latest main and add any information that would help move it forward. Assigned issues and issues labelled pinned are exempt from this policy.

  4. added
    stale
    on Sep 14, 2026
  5. Astro-Han commented on Sep 17, 2026

    @Astro-Han
    Contributor

    The direction question has an answer in this thread: Agent Graph stays the sole scheduling authority, and a general agent-addressed mailbox that can wake a recipient directly is a non-goal for now.

    What remains is an open design conversation rather than a proposed change, so please continue it at https://github.com/apache/maka/discussions. An issue is welcome once a narrow graph-scoped signal has a concrete use that the existing record, handoff and supervisor-wake paths cannot cover.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementstale

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions