Skip to main content

Official Python SDK for ABOV3 AI - Genesis CodeForger Edition

Project description

ABOV3 Python SDK - Genesis CodeForger Edition

PyPI version Python versions Documentation

The official Python SDK for ABOV3 AI - Genesis CodeForger Edition.

Official Website: https://www.abov3.ai ABOV3 Team: https://www.abov3.com

Installation

pip install abov3-ai

Quick Start

from abov3 import Abov3Client

# Initialize the client
client = Abov3Client(
    api_key="your-api-key",
    base_url="https://api.abov3.ai"  # Optional, defaults to production
)

# Create a session
session = await client.sessions.create(
    model="claude-3-opus",
    system_prompt="You are a helpful coding assistant"
)

# Send a message
response = await client.messages.create(
    session_id=session.id,
    content="Write a Python function to calculate fibonacci numbers"
)

print(response.content)

What's New in v0.1.4

TUI Configuration Management

The TUI now includes comprehensive configuration management commands:

  • Interactive configuration dialogs with form inputs
  • Provider management (add, edit, enable/disable, remove)
  • MCP server configuration
  • System health checks and validation
  • Scrollable configuration viewer

Features Update

  • Real-time configuration updates
  • Form-based input for adding providers and MCP servers
  • Health diagnostics with config doctor command
  • Configuration validation with detailed error reporting

Features

  • 🚀 Full API Coverage - Complete access to all ABOV3 AI capabilities
  • 🔒 Type Safety - Full type hints and runtime validation with Pydantic
  • Async Support - Built on httpx for high-performance async operations
  • 🔄 Auto Retry - Automatic retry with exponential backoff
  • 📊 Streaming - Support for streaming responses
  • 🔧 Configuration API - Manage ABOV3 configurations programmatically (v0.1.1+)
  • 🧪 Well Tested - Comprehensive test coverage

Streaming Responses

async with client.messages.stream(
    session_id=session.id,
    content="Generate a long story"
) as stream:
    async for chunk in stream:
        print(chunk.content, end="")

Error Handling

from abov3.exceptions import Abov3Error, RateLimitError

try:
    response = await client.messages.create(...)
except RateLimitError as e:
    print(f"Rate limited: {e}")
    # Wait and retry
except Abov3Error as e:
    print(f"API error: {e}")

Configuration

Environment Variables

export ABOV3_API_KEY="your-api-key"
export ABOV3_BASE_URL="https://api.abov3.ai"  # Optional

Code Configuration

client = Abov3Client(
    api_key="your-api-key",
    timeout=30.0,  # Request timeout in seconds
    max_retries=3,  # Maximum retry attempts
    proxy="http://proxy.example.com:8080"  # Optional proxy
)

Available Models

  • claude-3-opus - Most capable model for complex tasks
  • claude-3-sonnet - Balanced performance and speed
  • gpt-4-turbo - OpenAI's most capable model
  • gpt-3.5-turbo - Fast and cost-effective

API Reference

Sessions

# Create a session
session = await client.sessions.create(model="claude-3-opus")

# Get session
session = await client.sessions.get(session_id)

# List sessions
sessions = await client.sessions.list(limit=10)

# Delete session
await client.sessions.delete(session_id)

Messages

# Send message
message = await client.messages.create(
    session_id=session_id,
    content="Your message here"
)

# Stream message
async with client.messages.stream(...) as stream:
    async for chunk in stream:
        process(chunk)

Files

# Upload file
file = await client.files.upload(
    file_path="./document.pdf",
    purpose="analysis"
)

# List files
files = await client.files.list()

# Delete file
await client.files.delete(file_id)

Development

Setup Development Environment

# Clone the repository
git clone https://github.com/ABOV3AI/abov3-sdk-python.git
cd abov3-sdk-python

# Install development dependencies
pip install -e ".[dev]"

# Run tests
pytest

# Format code
black src tests
ruff check src tests

# Type checking
mypy src

Support

License

MIT License - see LICENSE file for details.

About ABOV3

ABOV3 AI is an advanced code generation framework that revolutionizes how developers interact with AI. Visit abov3.ai to learn more.

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

abov3_ai-0.1.6.tar.gz (7.7 kB view details)

Uploaded Source

Built Distribution

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

abov3_ai-0.1.6-py3-none-any.whl (8.7 kB view details)

Uploaded Python 3

File details

Details for the file abov3_ai-0.1.6.tar.gz.

File metadata

  • Download URL: abov3_ai-0.1.6.tar.gz
  • Upload date:
  • Size: 7.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for abov3_ai-0.1.6.tar.gz
Algorithm Hash digest
SHA256 ad46ec692c912af57d69e7072ed8e33f046d82edb5080276a0f28915984af9f3
MD5 9464d19e4db16e50d1738999b4e6c818
BLAKE2b-256 dd0b109d5c278b86e5e39d4f6e50fbb63189c5505cbe2576d185247dbcae7019

See more details on using hashes here.

File details

Details for the file abov3_ai-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: abov3_ai-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 8.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for abov3_ai-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 057716e7251e9c852012b3f55ba89ec1e46fcc29bdceefb18e4fae5ffe0a5dcc
MD5 cebdbda4a1852665a419e1c0912fbf8a
BLAKE2b-256 3b3388d34f9ca9b837dd4e252f9865cbc3e549e4bf1cea237387331278bcbe23

See more details on using hashes here.

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