Skip to main content
Version: 1.0.0

Agent

An agent carries an explicit responsibility and chooses among its declared capabilities. A skill instead describes a reusable composition of steps.

Shape​

source.tb
agent AgentName
takes request as RequestType
gives ResultType
responsibility "Fulfill the declared AgentName responsibility using only authorized capabilities."
uses SomeSkill
callable_by strategy StrategyName

responsibility is mandatory, unique and nonempty. It describes the agent's role; it does not grant execution rights. uses lists available capabilities. callable_by declares authorized callers, which can be strategies or agents.

Typed invocation​

agent_type.tb
module examples.agent_type

type ReviewRequest
summary is Text

type ReviewResult
verdict is Text

tool InspectRequest
description "Inspect one request and return a review result."
takes request as ReviewRequest
gives ReviewResult

agent Reviewer
takes request as ReviewRequest
gives ReviewResult
responsibility "Review the explicit request and return one typed final result."
uses InspectRequest
callable_by strategy RunReview

strategy RunReview
takes request as ReviewRequest
gives ReviewResult
uses Reviewer
do
Reviewer
with request as request
into review
give review

takes and gives declare an optional direct interface, never inferred from uses. Bind every declared input with with; into receives only the final result validated against gives. Intermediate capability observations are not implicitly the final result.

Agents without an explicit interface accept the simple invocation form, without with or into. For imported agents with explicit interfaces, the compiler resolves signatures from the project's source modules. Types retain their module identity and callers still require authorization. See Multi-module imports.

Single capability​

agent_simple.tb
module examples.agent_simple

type DatasetRequest
query is Text

type DatasetBrief
summary is Text

tool SearchDatasets
takes request as DatasetRequest
gives DatasetBrief
requires network

skill BuildDatasetBrief
takes request as DatasetRequest
gives DatasetBrief
uses SearchDatasets
do
SearchDatasets
with request as request
into result
give result

agent Researcher
responsibility "Fulfill the declared Researcher responsibility using only authorized capabilities."
uses BuildDatasetBrief
callable_by strategy RunDatasetResearch

strategy RunDatasetResearch
uses Researcher
do
Researcher

With one declared capability, Touba can select BuildDatasetBrief without a decision provider. Tool bindings and any required runtime inputs must still be supplied explicitly.

Multiple capabilities​

agent_advanced.tb
module examples.agent_advanced

type DatasetRequest
query is Text

type DatasetBrief
summary is Text

tool SearchDatasets
takes request as DatasetRequest
gives DatasetBrief
requires network

skill BuildDatasetBrief
takes request as DatasetRequest
gives DatasetBrief
uses SearchDatasets
do
SearchDatasets
with request as request
into result
give result

skill ReviewBrief
takes brief as DatasetBrief
gives DatasetBrief
do
human.approve
with context as brief
into approved

give brief

agent Researcher
responsibility "Fulfill the declared Researcher responsibility using only authorized capabilities."
uses BuildDatasetBrief
uses ReviewBrief
callable_by strategy RunDatasetResearch

strategy RunDatasetResearch
uses Researcher
do
Researcher

A configured provider proposes a capability and its named arguments. The runtime checks the target, types, caller authority and applicable resource scopes before executing it. See Governed agentic decision.

Authorized capabilities remain reusable across iterations, subject to the same budgets and checks. A capability being present in history does not make it unavailable.

Execution boundary​

  • An agent may select a function, tool, skill, agent or strategy declared in uses.
  • Delegation does not silently union caller and callee resource authority.
  • Memory and secret access require explicit scopes and tool contracts.
  • Structured and native SDK interfaces return proposals; neither executes a provider call as a Touba action without runtime mediation.
  • A strategy can distribute typed inputs across an agent with parallel. Invocations have isolated data and share run budgets.
  • An agent can select an authorized strategy containing a parallel group; its own decision loop remains sequential.
  • Coordination uses typed arguments and results, not free-form handoffs or automatic capability discovery.
  • An authorized capability may be reused while its budgets allow it.

See Bounded autonomy and Caller authority.