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.3.tar.gz
(104.5 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.3-py3-none-any.whl
(41.3 kB
view details)
File details
Details for the file dobby_sdk-0.2.3.tar.gz.
File metadata
- Download URL: dobby_sdk-0.2.3.tar.gz
- Upload date:
- Size: 104.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
873aaa0ddf9029afbb0491aa8e052214169fa587d6da5bd3ae7c3080cd672375
|
|
| MD5 |
f274487c7fa3947a6b0d2c66748b043d
|
|
| BLAKE2b-256 |
1c9697a5e1583809c1582bc33b3429f5c2df2ccf3ac367de480e18c36a9cd864
|
File details
Details for the file dobby_sdk-0.2.3-py3-none-any.whl.
File metadata
- Download URL: dobby_sdk-0.2.3-py3-none-any.whl
- Upload date:
- Size: 41.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
783bef433f78d7958001a029344944b688556a026926e93f441901c26193a847
|
|
| MD5 |
c04f5a6b7d78f9031a3a126e3f09e55e
|
|
| BLAKE2b-256 |
188538621c5f3768b22d6b4c3bce28affb20f3e638de9a760cc14193085d6fa1
|