Catalog PyPI
Back to packageRELEASE DETAILS

0.4.0

PyPI

agentabi

Unified async Python API for driving coding agent CLIs — Claude Code, Codex, Gemini CLI, and more

agentaiasyncautomationclaude-codeclicodexcoding-agentgemini-clillmmulti-agentopencodeorchestrationstreamingsubprocess
Published8 Sept 2026
Direct dependencies11
Transitive dependenciesNot calculated

README

Version 0.4.0 documentation

agentabi

PyPI version GitHub release CI License: MIT

Unified interface layer for agentic coding CLIs.

One interface. Any coding agent.

What is agentabi?

agentabi provides a stable, unified interface (an "ABI") for interacting with different agentic coding CLIs. Write your integration once, swap agents with a config change.

Supported Agents

AgentProviderStatus
Claude CodeAnthropicImplemented
CodexOpenAIImplemented
Antigravity (agy)GoogleImplemented
OpenCodeCommunityImplemented
PiCommunityImplemented
Gemini CLIGoogleDeprecated (use agy)

Installation

pip install agentabi

Note: You also need at least one agent CLI installed: claude, codex, agy, opencode, or pi.

Optional SDK dependencies

pip install agentabi[claude]    # Claude Agent SDK
pip install agentabi[codex]     # Codex SDK

Quick Start

import asyncio
from agentabi import Session

async def main():
    session = Session(agent="claude_code")
    result = await session.run(prompt="What is 2+2?")
    print(result["result_text"])

asyncio.run(main())

Key Features

Unified TaskConfig

All agents accept the same TaskConfig with fields for:

  • Agent selection: agent, model
  • Reasoning control: thinking_level ("off", "low", "medium", "high", "max")
  • Structured output: output_schema (JSON Schema)
  • Session management: session_id, resume, ephemeral
  • Workspace: working_dir, additional_dirs, files
  • Permissions: permissions, allowed_tools, disallowed_tools
  • System prompts: system_prompt, append_system_prompt

Unified IR Events

All agents emit the same streaming events:

  • session_start / session_end — session lifecycle
  • message_start / message_delta / message_end — text streaming
  • content_block_start / content_block_end — content block boundaries
  • reasoning_delta — thinking/reasoning text (Claude, Pi)
  • tool_use / tool_result — tool calls
  • usage — token counts (including reasoning_tokens)
  • error — error reporting

Documentation

License

MIT

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 14

Native requirements
11 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
typing_extensions
Environment
{
  "extras": "",
  "marker": null,
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
typing_extensions>=4.0.0runtime
claude-agent-sdk
Environment
{
  "extras": "",
  "marker": "extra == \"claude\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
claude-agent-sdk>=0.1.0; extra == "claude"runtime
codex-sdk-python
Environment
{
  "extras": "",
  "marker": "extra == \"codex\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
codex-sdk-python>=0.1.0; extra == "codex"runtime
gemini-cli-sdk
Environment
{
  "extras": "",
  "marker": "extra == \"gemini\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
gemini-cli-sdk>=0.5.0; extra == "gemini"runtime
claude-agent-sdk
Environment
{
  "extras": "",
  "marker": "extra == \"all\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
claude-agent-sdk>=0.1.0; extra == "all"runtime
codex-sdk-python
Environment
{
  "extras": "",
  "marker": "extra == \"all\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
codex-sdk-python>=0.1.0; extra == "all"runtime
gemini-cli-sdk
Environment
{
  "extras": "",
  "marker": "extra == \"all\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
gemini-cli-sdk>=0.5.0; extra == "all"runtime
pytest
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
pytest>=7.0.0; extra == "dev"runtime
pytest-asyncio
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
pytest-asyncio>=0.21.0; extra == "dev"runtime
pytest-cov
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
pytest-cov; extra == "dev"runtime
ruff
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
ruff==0.15.20; extra == "dev"runtime
ty
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
ty==0.0.54; extra == "dev"runtime
build
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
build>=1.2.2.post1; extra == "dev"runtime
twine
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.9",
  "evaluation": "NOT_EVALUATED"
}
twine>=6.1.0; extra == "dev"runtime

Distribution files

2 collected
agentabi-0.4.0-py3-none-any.whl

bdist_wheel · 53.71 KB · Python py3

Source file
agentabi-0.4.0.tar.gz

sdist · 40.36 KB · Python source

Source file

Repository

PENDING
oaklight/agentabi

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 21:26 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:497d70f18d7ba5f8e25aa152b0c2f1c6fcd2d6cc172fd33e2481ff6496b29e95

Other collected versions

View all collected versions →