Self-Evolving AI Agent SDK - Make any AI agent 20-50% smarter automatically
Project description
Zubbl SDK
Self-Evolving AI Agent SDK — Wrap any AI agent. It learns, recovers from failures, and gets better over time.
Install
pip install zubbl-sdk
Quick Start (3 Lines)
from zubbl import ZubblClient
zubbl = ZubblClient(api_key="zubbl_xxx")
agent = zubbl.wrap(your_agent)
result = agent("Review this PR for security issues")
That's it. Your agent now:
- Auto-recovers from failures — retries with fixes, no crash
- Learns from every run — records trajectories, extracts patterns
- Injects proven strategies — prepends natural-language guidance before each task
- Gets better over time — policies improve as data accumulates
How It Works
wrap(agent) → Agent runs → Trajectory recorded
↓
Patterns extracted by task type
↓
Policy built (confidence grows with data)
↓
Next run: natural-language guidance prepended
↓
Agent performs better — zero code changes
Framework Examples
OpenAI
import openai
from zubbl import ZubblClient
client = openai.OpenAI()
zubbl = ZubblClient(api_key="zubbl_xxx")
def my_agent(task):
return client.chat.completions.create(
model="gpt-4o",
messages=[{"role": "user", "content": task}],
).choices[0].message.content
agent = zubbl.wrap(my_agent)
result = agent("Write unit tests for auth.py")
LangChain
from langchain_openai import ChatOpenAI
from zubbl import ZubblClient
llm = ChatOpenAI(model="gpt-4o")
zubbl = ZubblClient(api_key="zubbl_xxx")
agent = zubbl.wrap(llm.invoke)
result = agent("Explain this error traceback")
Any Callable
zubbl = ZubblClient(api_key="zubbl_xxx")
agent = zubbl.wrap(any_function_that_takes_a_task)
Auto-Recovery
When your agent fails, Zubbl catches the error and retries with a fix:
agent = zubbl.wrap(my_agent) # auto_recover=True by default
# If my_agent crashes internally:
# 1. Zubbl catches the error
# 2. Applies a fix (prompt patch, retry, model swap)
# 3. Returns the correct result
# No crash. No code change.
Custom Policy Hook
Control exactly how learned strategies are injected:
def my_hook(args, policy):
task = args[0]
tips = "\n".join(policy.recommended_actions[:3])
return (f"Tips from past runs:\n{tips}\n\nTask: {task}",) + args[1:]
agent = zubbl.wrap(my_agent, policy_hook=my_hook)
Dashboard
- Agent runs are recorded automatically
- Visit app.zubbl.in to view trajectories and rate runs
- Your feedback improves policies — no code changes needed
Research Foundations
Built on peer-reviewed research:
- Training-Free GRPO (2025) — compact policy injection
- AgentHER (2026) — learn from failures via hindsight relabeling
- ETO (ACL 2024) — contrastive trajectory optimization
- Reflexion (NeurIPS 2023) — verbal self-reflection on failures
Links
License
MIT
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
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
File details
Details for the file zubbl_sdk-0.4.0.tar.gz.
File metadata
- Download URL: zubbl_sdk-0.4.0.tar.gz
- Upload date:
- Size: 34.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6506c39f18d05e16ee205b4b90ab17c3dcf2df93ac0f68a64ce883c03a0edc44
|
|
| MD5 |
945785af30e31e1606b78fdb5758a239
|
|
| BLAKE2b-256 |
1f3e2949d26ff00733f7a43b3699bcbafd207cc9fdb593290b47779e48e84ecc
|
Provenance
The following attestation bundles were made for zubbl_sdk-0.4.0.tar.gz:
Publisher:
publish.yml on anupammaurya6767/zubbl-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
zubbl_sdk-0.4.0.tar.gz -
Subject digest:
6506c39f18d05e16ee205b4b90ab17c3dcf2df93ac0f68a64ce883c03a0edc44 - Sigstore transparency entry: 1361161198
- Sigstore integration time:
-
Permalink:
anupammaurya6767/zubbl-sdk@7f31453ee0ff6be446349956921eeb973c69adae -
Branch / Tag:
refs/heads/main - Owner: https://github.com/anupammaurya6767
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@7f31453ee0ff6be446349956921eeb973c69adae -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file zubbl_sdk-0.4.0-py3-none-any.whl.
File metadata
- Download URL: zubbl_sdk-0.4.0-py3-none-any.whl
- Upload date:
- Size: 37.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4aa07cb95582aaca3fd623160798b2abb9b4c923b96265288693d9bbdb91fb32
|
|
| MD5 |
58752b2d264f058e4f459c679f13d90d
|
|
| BLAKE2b-256 |
807ac7b565b9a3843fbab41d00504f55295ee00a1d7990459bccb75ca5dca8c6
|
Provenance
The following attestation bundles were made for zubbl_sdk-0.4.0-py3-none-any.whl:
Publisher:
publish.yml on anupammaurya6767/zubbl-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
zubbl_sdk-0.4.0-py3-none-any.whl -
Subject digest:
4aa07cb95582aaca3fd623160798b2abb9b4c923b96265288693d9bbdb91fb32 - Sigstore transparency entry: 1361161202
- Sigstore integration time:
-
Permalink:
anupammaurya6767/zubbl-sdk@7f31453ee0ff6be446349956921eeb973c69adae -
Branch / Tag:
refs/heads/main - Owner: https://github.com/anupammaurya6767
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@7f31453ee0ff6be446349956921eeb973c69adae -
Trigger Event:
workflow_dispatch
-
Statement type: