Skip to main content

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

Agent Provider Status
Claude Code Anthropic Implemented
Codex OpenAI Implemented
Antigravity (agy) Google Implemented
OpenCode Community Implemented
Pi Community Implemented
Gemini CLI Google Deprecated (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

Metadata

Release files for agentabi 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for agentabi 0.4.0
File Size Uploaded
agentabi-0.4.0.tar.gz 41.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for agentabi 0.4.0
File Interpreter ABI Platform
agentabi-0.4.0-py3-none-any.whl Python 3 none any Details

Total release size: 96.3 kB

Release files / agentabi-0.4.0.tar.gz

Download URL agentabi-0.4.0.tar.gz
Size 41.3 kB
Tags Source
SHA-256 checksum
How to use checksums
4b4f9278e4d45ff3412c9be96d39dd514245a016c63f0ace060bd05143ddb338
BLAKE2b-256 checksum
How to use checksums
ec142516a29adde365159a027bf0fbaffabedb22e8c4374ffb694f8c1ce8893b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.

Transparency log

Release files / agentabi-0.4.0-py3-none-any.whl

Download URL agentabi-0.4.0-py3-none-any.whl
Size 55.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
819c62b37686d7f1b499a92e845ad5857c47339fcac1dff339a9a56de19fbe37
BLAKE2b-256 checksum
How to use checksums
dbeb7a141b213c9d867924940167397c4370f46adce0c4f5ac00658daf88c2d3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.4.0 This release

2 release files

0.3.0

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page