roboto.ai.agent.resolver
Module Contents
AgentResolutionError
Bases: ValueError
Base class for resolver-raised errors. Routes map subclasses to 4xx.
UnknownAgentVariablesError
Bases: AgentResolutionError
Caller supplied values for variables the agent no longer declares — almost always a stale invoke form. Mapped to 400 so the UI can refetch.
Parameters
names list[str]Attributes
UnknownAgentVariablesError.names
names #UnresolvedAgentVariablesError
Bases: AgentResolutionError
Required variables had no supplied value and no default. Mapped to 400 with the names so the invoke page can highlight the empty inputs.
Parameters
names list[str]Attributes
UnresolvedAgentVariablesError.names
names #resolve_agent()
Substitute values into agent.request_template and return a fully-validated StartAgentThreadRequest.
Walks the body’s JSON form swapping every {{name}} occurrence in a string leaf. Embedded substitution is supported. Dict keys are never touched — placeholder syntax in keys is rejected at save time.
Parameters
values dict[str, str]Raises
values contains keys not declared on the agent (typically a stale invoke form).
a required variable has neither a supplied value nor a default; carries the offending names.
pydantic.ValidationErrorthe substituted body failed StartAgentThreadRequest validation — e.g. a resolved value doesn’t match a field-level regex or enum.