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.2.tar.gz
(99.3 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.2-py3-none-any.whl
(41.0 kB
view details)
File details
Details for the file dobby_sdk-0.2.2.tar.gz.
File metadata
- Download URL: dobby_sdk-0.2.2.tar.gz
- Upload date:
- Size: 99.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
54ce54f21a4833b9097ac8dde41419a7f994e8c54fe0c00fbf953bffe358793b
|
|
| MD5 |
2cd67073d341cb2d4ded2cc9dbe814bc
|
|
| BLAKE2b-256 |
87eba4f23e0001570efb1eae5aae1980b4272f044c547d601dcd9349f445a722
|
File details
Details for the file dobby_sdk-0.2.2-py3-none-any.whl.
File metadata
- Download URL: dobby_sdk-0.2.2-py3-none-any.whl
- Upload date:
- Size: 41.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
af1b505e9a01d943f7e80bb6a07f0435134f6d26a6f6c004b9e217b69c66a482
|
|
| MD5 |
30cbc5f37039a68a7fa60d7e2cd08c62
|
|
| BLAKE2b-256 |
b3e69dedc5a99fb13dd4aa2e436578888c4ab1d8a36f272beed37e280fefbf84
|