Skip to main content

Agent runtime with SDK imports, bundled CLI, optional daemon bootstrap, and built-in tools

Project description

yuuagents

A minimal Python agent runtime built around a single runtime core: Flow.

Flow = observable execution + mailbox + cancellation
Agent = LLM loop on top of Flow
Basin = live-flow index
TaskHost = SDK-first host API

Architecture

Flow is the only runtime object that matters.

  • Flow records what happened, owns a mailbox, tracks parent/children, and can be cancelled or waited on.
  • Agent is the LLM executor attached to a root Flow.
  • Deferred is a Flow state, not a separate object type.
  • Basin indexes all live flows, not just roots.
  • TaskHost is the host-facing API for submit, status, history, inspect, wait, cancel, and persistence.
  • Daemon/CLI support is an adapter layer on top of TaskHost, not the core model.

Persistence

SDK-only users should be able to run the runtime without yagents install.

  • In-process persistence should work without any daemon or socket.
  • Durable local persistence should be optional and pluggable.
  • The daemon adapter may use default disk locations and discovery files, but those are deployment conveniences, not runtime requirements.

Core Model

TaskHost
├── Basin
│   ├── flow lookup by id
│   ├── live flow registry
│   └── flow-level inspect / wait / cancel
└── Persistence
    ├── in-memory for SDK use
    └── optional disk-backed storage

Agent
├── root Flow
├── messages / usage / rounds
└── tool execution on child Flows

Flow Semantics

Flow is the execution topology.

  • Each flow has an id, kind, info, stem, mailbox, children, and optional parent link.
  • send(content) accepts str, Item, or list[Item].
  • The meaning of send is flow-specific and follows dependency inversion: different flow kinds interpret the same content differently.
  • A deferred flow continues running and may later notify its parent through the mailbox.

Host API

TaskHost is the main service boundary for both SDK and daemon usage.

host = TaskHost(basin=basin, persistence=persistence, root_factory=root_factory)

task_id = await host.submit(spec)
info = await host.status(task_id)
history = await host.history(task_id)
await host.wait(task_id)
await host.cancel(task_id)

This is the level that should remain stable. CLI and HTTP are projections of this API.

Built-in Tool Families

  • delegate: create a child agent flow through the host/runtime boundary.
  • execute_bash: create an interactive terminal flow when Docker is available.
  • inspect_background, wait_background, cancel_background, input_background, defer_background: host-level operations over live flow ids.
  • web_search, read_file, edit_file, delete_file, sleep, view_image: ordinary tools that do not require host-level control.

Design Notes

  • Root flow id should be the task id.
  • The implementation should prefer one truth source for runtime state, not mirrored host-side caches.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

yuuagents-0.2.0.tar.gz (60.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

yuuagents-0.2.0-py3-none-any.whl (73.9 kB view details)

Uploaded Python 3

File details

Details for the file yuuagents-0.2.0.tar.gz.

File metadata

  • Download URL: yuuagents-0.2.0.tar.gz
  • Upload date:
  • Size: 60.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for yuuagents-0.2.0.tar.gz
Algorithm Hash digest
SHA256 4eb4649b9af12f9b1e529e6a5f990703172f28e7de2323220c3952b429d449ea
MD5 89d03abd83b02d922452fc3a3679a57c
BLAKE2b-256 74c2e693cea021af88beea402aa26fc079d36c4d0ce8f401585787942abd73b3

See more details on using hashes here.

Provenance

The following attestation bundles were made for yuuagents-0.2.0.tar.gz:

Publisher: publish-pypi.yml on yuulabs/yuuagents

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file yuuagents-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: yuuagents-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 73.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for yuuagents-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d59b8732aec0d18f77a452ea1a94f2d338db38c75aaa193e21540cda92a9324a
MD5 701d04a7140bdcf6adbe4407a4c8c091
BLAKE2b-256 f7fb6d87c7464a12b570359e72a5437e7fd7952673ace9514eb5b53818785799

See more details on using hashes here.

Provenance

The following attestation bundles were made for yuuagents-0.2.0-py3-none-any.whl:

Publisher: publish-pypi.yml on yuulabs/yuuagents

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page