Skip to main content

Application framework for building AI agents with Pydantic AI - environment abstractions, session management, and hierarchical agent patterns

Project description

Ya Agent SDK

Yet Another Agent SDK

Release Build status codecov Commit activity License

Yet Another Agent SDK for building AI agents with Pydantic AI.

Key Features

  • Environment-based architecture for file operations, shell access, and resources
  • Fully typed SDK validated with pyright
  • Resumable sessions with state export and restore
  • Hierarchical agents with subagent delegation
  • Tool search for large tool libraries
  • Skills system with hot reload and progressive loading
  • Human-in-the-loop approval workflows
  • Event system and streaming support
  • Message bus for agent coordination and user steering
  • Browser automation with Docker sandbox support

Installation

pip install ya-agent-sdk[all]
uv add ya-agent-sdk[all]

Selective extras:

pip install ya-agent-sdk[docker]
pip install ya-agent-sdk[web]
pip install ya-agent-sdk[document]
pip install ya-agent-sdk[s3]
pip install ya-agent-sdk[tool-search]

Quick Start

For workspace development, copy packages/ya-agent-sdk/.env.example to packages/ya-agent-sdk/.env. For the runnable example scripts, copy examples/.env.example to examples/.env.

from ya_agent_sdk.agents import create_agent, stream_agent

runtime = create_agent("openai:gpt-4o")

async with stream_agent(runtime, "Hello") as streamer:
    async for event in streamer:
        print(event)

Model Preset Tips

For Anthropic models, anthropic now resolves to adaptive thinking by default.

  • Use anthropic for the default adaptive preset.
  • Use anthropic_adaptive_xhigh for Claude Opus 4.7 long-horizon coding and agentic workloads.
  • Use openai_responses_xhigh for GPT-5.5 hard asynchronous agentic tasks and evals.
  • Use anthropic_off when you want thinking disabled.
  • Use anthropic_400k or claude_400k for a 400K context window between claude_200k and claude_1m.

Repository Context

This package lives in the ya-mono workspace.

Examples

Example Description
general.py Production pattern with streaming, HITL approval, and session persistence
deepresearch.py Autonomous research agent with web search and content extraction
browser_use.py Browser automation with Docker-based headless Chrome sandbox

Reference Files

Development

git clone git@github.com:YOUR_NAME/ya-mono.git
cd ya-mono
uv sync --all-packages

Workspace commands live at the repository root. See the contributing guide.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

ya_agent_sdk-0.67.0.tar.gz (490.2 kB view details)

Uploaded Source

Built Distribution

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

ya_agent_sdk-0.67.0-py3-none-any.whl (344.2 kB view details)

Uploaded Python 3

File details

Details for the file ya_agent_sdk-0.67.0.tar.gz.

File metadata

  • Download URL: ya_agent_sdk-0.67.0.tar.gz
  • Upload date:
  • Size: 490.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.2

File hashes

Hashes for ya_agent_sdk-0.67.0.tar.gz
Algorithm Hash digest
SHA256 9dde7a35e7c2b1b2d5b830b3a897474ebe1c63333ac78b3a8cc50b91b3be1bf0
MD5 a98b6789be6a0f2edc2e777583166cf7
BLAKE2b-256 8098e671e85527e97eb31fe822e57892a90999fa35d74b26a2982a32c9cd6df5

See more details on using hashes here.

File details

Details for the file ya_agent_sdk-0.67.0-py3-none-any.whl.

File metadata

File hashes

Hashes for ya_agent_sdk-0.67.0-py3-none-any.whl
Algorithm Hash digest
SHA256 aef80c64e537b48c1eec8a900f866bbdb3014d1ac49d062e2f0933933eb49e55
MD5 7aae8233fe3ac3ca5b3b3e4b52b2e5ca
BLAKE2b-256 47cd6dda58fc40322e027818fbb5779273c1d8b43ff01fd139ac9738ab97a1b4

See more details on using hashes here.

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