Discover Assess Decide Communicate Act Measure Protect
Rewards Capabilities Entities Events Organizations Individuals Trust Risks Negotiate Accept Complain Remedy Request Respond Notify Train Tasks Workflows Skills Tools Impacts Campaigns Costs Compliance Consumers Employees Stakeholders Data
 

 

 

All I did was
ASK a QUESTION...

...getting answers can be a challenge.

Every request that goes unanswered costs money.
“How much do I owe you?”

Every unanswered inquiry incurs storage costs in one or more systems -- for every participant in an exchange.
As precious time goes by with no progress, information is lost and participants disengage:
“How did you find out about us?”
“I don't remember, I've been a customer for 20 years”

Streaming chatbots serving as front-end interfaces for Retrieval-augmented generation (RAG) systems DO answer questions, BUT:

  • Only SOME OF THEM.
    (They don't know who I am, and if they did, they shouldn't retrieve my customer information unless they can identify me as the authorized consumer.)
  • Setting a meaningful context for more nuanced questions can be problematic.
    (Long explanations about the actual question often introduce tangents that increase processing costs.)
  • When a question is a request, as in, “I want you to do something for me.”
    (The question is actually a Request in a Request-Response pair, correlated with a Message-Id, AND
    a Task, correlated with a Task-Id. )
  • When a request is "long-running", or asynchronous, responses could be orphaned and information is lost.
    (A Task-Id associated with a Request using this Message-Id that has no Response is a Task with NO STATUS.)
  • Yo-AI correlates Request-Response pairs for Messages and Tasks to insure that information is never lost.
    (Orphaned messages go into the Dead-Letter-Queue)

 

 

 

WHO Is
ASKING?

 

In Yo-AI, before a Request (Message or Task) is routed, the most important context is WHO THE SENDER IS.

Another agent, the Door-Keeper, intercepts the Request and promotes the Sender's identifying information to YoAiContext, which sets the Actor properties:

class YoAiContext(TypedDict, total=False):
    """
    The single unified interchange context for the YoAi platform.

    Constructed once per request-response interchange and passed as a call
    parameter into every capability handler. Never stored on agent instances.

    Two temporal faces
    ──────────────────
    REQUEST face   Populated at construction from the incoming envelope.
                   Answers: who is asking, on whose behalf, for what, how.

    RESPONSE face  Written by the capability as it produces its result.
                   Answers: what changed, what should travel forward.

    ┌─ Correlation ──────────────────────────────────────────────────────┐
    │ correlation_id   JSON-RPC id. Primary request-response handle.     │
    │                  Set by A2ATransport at the protocol boundary.     │
    │ task_id          A2A task identifier.                              │
    │                  Defaults to correlation_id if absent.            │
    └────────────────────────────────────────────────────────────────────┘

    ┌─ Actor (REQUEST) ──────────────────────────────────────────────────┐
    │ actor_kind       What kind of entity invoked this operation.       │
    │ actor            Identity dict of the invoking entity.            │
    └────────────────────────────────────────────────────────────────────┘

    ┌─ Invocation mechanics (REQUEST) ───────────────────────────────────┐
    │ startup_mode     How the request entered the platform.             │
    │ instance_id      Runtime identity of the handling agent instance.  │
    │                  None for PlatformAgents.                         │
    │ caller           Registered caller identity for trust-gated access.│
    └────────────────────────────────────────────────────────────────────┘

    ┌─ Subject (REQUEST) ────────────────────────────────────────────────┐
    │ profile          ProfileWrapper — lightweight profile snippet.     │
    │                  Shape: {type, name?, payload}                    │
    │ subject_ref      Lightweight pointer to the request subject.      │
    └────────────────────────────────────────────────────────────────────┘

    ┌─ Capability identity (REQUEST) ────────────────────────────────────┐
    │ capability_id    The capability being invoked, e.g. "Trust.Assign"│
    │                  None at pipeline level; bound via                │
    │                  ctx_for_capability().                            │
    └────────────────────────────────────────────────────────────────────┘

    ┌─ Execution knobs (REQUEST) ────────────────────────────────────────┐
    │ slim             Skip expensive init (fingerprints, knowledge,    │
    │                  tools).                                          │
    │ tools            Selective tool loading.                          │
    │                  None=all, []=none, ["vault"]=named subset.       │
    │ dry_run          Validate without executing side effects.         │
    │ trace            Activate OTel Layer 4 explainability tracing.    │
    └────────────────────────────────────────────────────────────────────┘

    ┌─ Workflow state (REQUEST, updated per step) ───────────────────────┐
    │ step             Current workflow step index.                      │
    │ prior_outputs    Outputs from previous steps.                     │
    │ state            Arbitrary workflow state bag.                    │
    └────────────────────────────────────────────────────────────────────┘

    ┌─ RESPONSE face — written by the capability, travels forward ───────┐
    │ profile_patch    Fields discovered during execution not present in │
    │                  the original profile. Forwarded to Data-Steward. │
    │                  Shape: {type, payload}                           │
    │ governance_labels  Sticky notes attached by the capability.       │
    │                  NOT present in request envelopes — prevents      │
    │                  information spills between capabilities.         │
    │                  Shape: list[str]                                 │
    └────────────────────────────────────────────────────────────────────┘
    """

    # ── Correlation ────────────────────────────────────────────────────
    correlation_id:    str | None
    task_id:           str | None

    # ── Actor ──────────────────────────────────────────────────────────
    actor_kind:        ActorKind | None
    actor:             dict[str, Any] | None

    # ── Invocation mechanics ───────────────────────────────────────────
    startup_mode:      StartupMode | None
    instance_id:       str | None
    caller:            dict[str, Any] | None

    # ── Subject ────────────────────────────────────────────────────────
    profile:           dict[str, Any] | None   # ProfileWrapper
    subject_ref:       dict[str, Any] | None

    # ── Capability identity ────────────────────────────────────────────
    capability_id:     str | None

    # ── Execution knobs ────────────────────────────────────────────────
    slim:              bool
    tools:             list[str] | None
    dry_run:           bool
    trace:             bool

    # ── Workflow state ─────────────────────────────────────────────────
    step:              int | None
    prior_outputs:     dict[str, Any]
    state:             dict[str, Any]

    # ── RESPONSE face ──────────────────────────────────────────────────
    profile_patch:     dict[str, Any] | None   # ProfilePatch
    governance_labels: list[str]

YoAiContext provides metadata to support custom processing operations, setting tags in the governanceLabels of the payload envelope for use in downstream processes for persistence.

 

GET
Yo-AI

Discover what YOU ARE MISSING.