Lightweight multi-provider LLM SDK with streaming and tools
Project description
Dobby SDK
Lightweight multi-provider LLM SDK with streaming and tool support.
Installation
pip install dobby-sdk
# Or from GitHub
pip install git+https://github.com/TYNYBAY/dobby-sdk.git
# With uv
uv add dobby-sdk
Quick Start
from dobby import AgentExecutor, OpenAIProvider
from dobby.types import UserMessagePart, TextPart, TextDeltaEvent
provider = OpenAIProvider(model="gpt-4o", api_key="sk-...")
executor = AgentExecutor(provider="openai", llm=provider)
messages = [UserMessagePart(parts=[TextPart(text="Hello!")])]
async for event in executor.run_stream(messages):
match event:
case TextDeltaEvent(delta=delta):
print(delta, end="")
Features
- Multi-provider: OpenAI, Azure OpenAI, Anthropic
- Streaming: Real-time token streaming with typed events
- Tools: Dataclass-based tools with auto-generated schemas
- Context injection: Pass runtime context to tools via
Injected[T] - Structured output: Pydantic model validation for agent responses
Documentation
See docs/ for detailed documentation:
License
MIT
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
dobby_sdk-0.2.9.tar.gz
(116.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
dobby_sdk-0.2.9-py3-none-any.whl
(53.2 kB
view details)
File details
Details for the file dobby_sdk-0.2.9.tar.gz.
File metadata
- Download URL: dobby_sdk-0.2.9.tar.gz
- Upload date:
- Size: 116.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c07a3f0193867cc63a0968a208ed0414757f40adf46cd3825de47e95c010a09d
|
|
| MD5 |
6b4144e7f1d5a576932506a55b1c6dff
|
|
| BLAKE2b-256 |
c284f10d87138c84fe96a56af9eb6b14b2f5b79e24df13fb3a3b4c4b9a3c660e
|
File details
Details for the file dobby_sdk-0.2.9-py3-none-any.whl.
File metadata
- Download URL: dobby_sdk-0.2.9-py3-none-any.whl
- Upload date:
- Size: 53.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7032d176de2c40dfd9e230c7b7eed8336a1fedbb4188edda89a1f92150538d80
|
|
| MD5 |
48c7dc3c307e26d9a6ea35eb5fec2b8b
|
|
| BLAKE2b-256 |
412bfafbf5954f7bef437bd162e4c5a50b2dad31fab955f264b93820a3a0f1dd
|