Skip to main content

Claude Agent SDK provider for Zeno (Anthropic Claude with sub-agents, built-in tools, and SDK hooks).

Project description

zeno-provider-claude

Claude Agent SDK provider for Zeno. Wraps claude-agent-sdk (ClaudeSDKClient) behind Zeno's Provider Protocol so an Agent definition stays portable across providers.

Install

uv add 'zeno-framework[claude]'

The zeno-framework meta-package ships Claude as the default; this extra is the explicit form for environments that pin extras.

Usage

from zeno.agent import Agent
from zeno.app import ZenoApp
from zeno.channels.cli.channel import CliChannel
from zeno.providers.claude_sdk import ClaudeSDKProvider

app = ZenoApp(
    agent=Agent(
        name="root",
        instructions="You are a helpful personal assistant.",
        permission_mode="bypassPermissions",
    ),
    channels=[CliChannel()],
    provider=ClaudeSDKProvider(),
)

ClaudeSDKProvider reads ANTHROPIC_API_KEY from the environment via the underlying SDK. Set it before app.start().

Resuming SDK sessions

Pass a session_lookup callable to resume a prior SDK session keyed by (user_id, channel, thread_key):

async def lookup_session(user_id: str, channel: str, thread_key: str | None) -> str | None:
    return await my_store.get_sdk_session_id(user_id, channel, thread_key)


provider = ClaudeSDKProvider(session_lookup=lookup_session)

When session_lookup returns None (or is omitted), each turn starts a fresh SDK session.

Capabilities

ClaudeSDKProvider is the only Zeno provider that supports:

  • sub_agents — Claude Agent SDK dispatch via AgentDefinition
  • built_in_toolsWebSearch, WebFetch, Bash, etc.
  • permission_modedefault / acceptEdits / bypassPermissions / plan
  • Streaming assistant text via ctx.stream(...)
  • SDK hook bridge (PreToolUse / PostToolUse / UserPromptSubmit and the optional SubagentStart / SubagentStop / PostToolUseFailure hooks when available) translated into Zeno trace events.

See also

Part of the Zeno framework.

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

zeno_provider_claude-1.0.2.tar.gz (18.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

zeno_provider_claude-1.0.2-py3-none-any.whl (12.2 kB view details)

Uploaded Python 3

File details

Details for the file zeno_provider_claude-1.0.2.tar.gz.

File metadata

  • Download URL: zeno_provider_claude-1.0.2.tar.gz
  • Upload date:
  • Size: 18.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for zeno_provider_claude-1.0.2.tar.gz
Algorithm Hash digest
SHA256 629428c603bafe409d01c56ea1e03459c91e3fd25ee529a46fd17b3ebba919d4
MD5 5a2a1f656fe2d5c5ed04315bb8d1bfd2
BLAKE2b-256 044a97d98b70b295af499930e900d8b8e493583d48348d8f23add11c978b22eb

See more details on using hashes here.

Provenance

The following attestation bundles were made for zeno_provider_claude-1.0.2.tar.gz:

Publisher: publish.yml on nkootstra/zeno

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zeno_provider_claude-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for zeno_provider_claude-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 491a3bda08df32c57a6f51186c869c1447db26beb6be8244d0f4302a832a1963
MD5 c820494981204f5bf77a24f8736ae76a
BLAKE2b-256 ad1e3b199e1fd3817b457b8e09f58d53dbcfe662fad9f4bcec49415cd76e4b4b

See more details on using hashes here.

Provenance

The following attestation bundles were made for zeno_provider_claude-1.0.2-py3-none-any.whl:

Publisher: publish.yml on nkootstra/zeno

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page