A production-grade, framework-agnostic Python Agent SDK with Bridge and Adapter pattern runtimes.
Project description
Kneo Agent
A production-grade, framework-agnostic Python Agent SDK. Build LLM-powered agents across multiple providers (Google ADK, OpenAI Agents SDK, LangChain) with one consistent API and four execution styles: Bridge, Native, Adapter, and Workflow.
Requirements
- Python 3.12+
- A single mandatory runtime dependency (
PyYAML) - Provider SDKs and OpenTelemetry are optional extras — install only what you need
Installation
pip install kneo-agent # core only
pip install "kneo-agent[openai]" # + OpenAI Agents SDK
pip install "kneo-agent[langchain]" # + LangChain
pip install "kneo-agent[google-adk]" # + Google ADK
pip install "kneo-agent[telemetry]" # + OpenTelemetry middleware
pip install "kneo-agent[all]" # everything above
Verify:
python -c "import kneo_agent; print(kneo_agent.__version__)"
# → 1.1.1
Quick Start
The shortest path is build_sync_agent — no asyncio boilerplate at the
call site:
from kneo_agent import build_sync_agent
agent = build_sync_agent(
"openai",
model="gpt-4o-mini",
system_prompt="You are a helpful assistant.",
)
print(agent.chat("What is 2 + 2?")) # blocks, returns str
If you're already inside an event loop (Jupyter, FastAPI handler, other async code), use the async equivalent:
import asyncio
from kneo_agent import build_agent
async def main():
agent = build_agent("openai", model="gpt-4o-mini")
print(await agent.chat("What is 2 + 2?"))
asyncio.run(main())
Both functions accept the same parameters: provider, model, tools,
system_prompt, middlewares, plus a runtime= escape hatch for any
pre-built AgentRuntime. The explicit AgentBuilder + factory chain
remains available for fine-grained control (custom strategies, multi-step
tool registration, workflow composition).
Optional Features
| Feature | Extra | What it adds |
|---|---|---|
| OpenAI Agents SDK runtime | [openai] |
Native gpt-* runtime via openai-agents |
| LangChain runtime | [langchain] |
Bridge over any BaseChatModel |
| Google ADK runtime | [google-adk] |
Adapter wrapping ADK runners |
| OpenTelemetry tracing | [telemetry] |
First-party OpenTelemetryMiddleware emitting GenAI semantic-convention spans |
Built-in capabilities (no extra needed):
- MCP tool servers — import remote tools over
stdio,http, orsseviaMCPServerConfigandToolRegistry.register_mcp_server(...). - Skills — package prompt fragments, tool bundles, and defaults into
reusable
Skillobjects (Python orSKILL.mdfiles). - Workflows — sequential, concurrent, handoff, group-chat, and graph
orchestrations. Every workflow satisfies
AgentRuntime, so it can be used as a normalAgentor nested inside another workflow. - Human-in-the-loop — first-class workflow step with resolver callback or pause/resume semantics.
- Middleware — composable hooks around runs, streams, model calls, and
tool dispatch (the OpenTelemetry middleware ships under the
[telemetry]extra). - Agent-as-tool — expose any
Agentas a tool that another agent can call (agent.as_tool(...)orToolRegistry.add_agent(...)).
Package Contents
kneo_agent/
├── __init__.py top-level public API exports
├── py.typed PEP 561 typed marker
├── simple.py build_sync_agent / build_agent / SyncAgent
├── core/ Agent, AgentBuilder, RunConfig, types, middleware, skills
├── runtime/ Bridge / Native / Adapter runtime families
├── providers/ OpenAI / LangChain / Google ADK translations
├── workflows/ Sequential / Concurrent / Handoff / GroupChat / Graph
├── patterns/ BridgeAgentFactory, NativeRuntimeFactory, AdapterAgentFactory
├── mcp/ MCP stdio / HTTP / SSE client
├── observability/ OpenTelemetryMiddleware (requires [telemetry])
└── utils/ ToolRegistry, message helpers, logging
For full documentation, examples, the architecture write-up, and the SRS, see the project repository on GitHub.
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
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 kneo_agent-1.1.1.tar.gz.
File metadata
- Download URL: kneo_agent-1.1.1.tar.gz
- Upload date:
- Size: 56.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1abe9cf7a7ffe3d704fd7ccd70fbb6aa79b50462c50a3d0719624c419855e2b9
|
|
| MD5 |
0019967e69558a4767db871981b3e3f3
|
|
| BLAKE2b-256 |
6feeefdbca8b7fbf53bc5ca00022e1db102c75108d5c19dbbe8df05f16a84de4
|
Provenance
The following attestation bundles were made for kneo_agent-1.1.1.tar.gz:
Publisher:
release.yml on kneo-agent/kneo-agent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
kneo_agent-1.1.1.tar.gz -
Subject digest:
1abe9cf7a7ffe3d704fd7ccd70fbb6aa79b50462c50a3d0719624c419855e2b9 - Sigstore transparency entry: 1436384415
- Sigstore integration time:
-
Permalink:
kneo-agent/kneo-agent@bb5684a383f196e837a7615120b615cd80cc77f2 -
Branch / Tag:
refs/tags/v1.1.1 - Owner: https://github.com/kneo-agent
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@bb5684a383f196e837a7615120b615cd80cc77f2 -
Trigger Event:
push
-
Statement type:
File details
Details for the file kneo_agent-1.1.1-py3-none-any.whl.
File metadata
- Download URL: kneo_agent-1.1.1-py3-none-any.whl
- Upload date:
- Size: 73.0 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 |
700f0f4b6a8fc42e06130bb5910c80d1dcc72d5ea9b5b7d5855982d3ef8be3f3
|
|
| MD5 |
9dac0bdad43005e1baa13814864fa95a
|
|
| BLAKE2b-256 |
968b6086b6e14de72503a2eb9cdfca897805a4a4ae1262a7813b61e3d64e83f1
|
Provenance
The following attestation bundles were made for kneo_agent-1.1.1-py3-none-any.whl:
Publisher:
release.yml on kneo-agent/kneo-agent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
kneo_agent-1.1.1-py3-none-any.whl -
Subject digest:
700f0f4b6a8fc42e06130bb5910c80d1dcc72d5ea9b5b7d5855982d3ef8be3f3 - Sigstore transparency entry: 1436384449
- Sigstore integration time:
-
Permalink:
kneo-agent/kneo-agent@bb5684a383f196e837a7615120b615cd80cc77f2 -
Branch / Tag:
refs/tags/v1.1.1 - Owner: https://github.com/kneo-agent
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@bb5684a383f196e837a7615120b615cd80cc77f2 -
Trigger Event:
push
-
Statement type: