Skip to main content

arcanada-model-connector

PyPI Python License: MIT

Typed Python client SDK for the Arcanada Model Connector — a unified API for AI CLI agents (Claude Code, Cursor, Gemini, Codex) and cloud model providers (OpenRouter, Groq, Grok, embedding services).

pip install arcanada-model-connector

Quick start

from arcanada_model_connector import Client

client = Client(api_key="arc_api_...")
response = client.execute({
    "connector": "openrouter",
    "prompt": "Explain BGE-M3 in 30 words.",
    "model": "mistralai/mistral-small-3.2-24b-instruct",
})
print(response.result)

Async

import asyncio
from arcanada_model_connector import AsyncClient

async def main() -> None:
    async with AsyncClient(api_key="arc_api_...") as client:
        response = await client.execute({"connector": "openrouter", "prompt": "ping"})
        print(response.result)

asyncio.run(main())

Structured output with output_format + schema

response = client.execute({
    "connector": "openrouter",
    "prompt": "Return a JSON object with keys 'city' and 'population'.",
    "output_format": "json",
    "schema": {
        "type": "object",
        "properties": {
            "city": {"type": "string"},
            "population": {"type": "integer"},
        },
        "required": ["city", "population"],
    },
})
print(response.repair_report)  # native | guarded | failed
print(response.structured)

repair_report.pass_ is one of:

  • native — provider returned valid output, no repair needed.
  • guarded — output-guard middleware applied repair strategies successfully.
  • failed — output-guard exhausted retries; raised as GuardExhaustedError.

Error handling

from arcanada_model_connector import ConnectorError, GuardExhaustedError, TimeoutError

try:
    response = client.execute({"connector": "openrouter", "prompt": "..."})
except GuardExhaustedError as exc:
    print("guard exhausted:", exc.envelope.message)
except ConnectorError as exc:
    print(f"HTTP {exc.status}: {exc.envelope.type if exc.envelope else 'unknown'}")
    if exc.retry_after:
        print(f"retry after {exc.retry_after}s")
except TimeoutError as exc:
    print("timed out after", exc.timeout, "seconds")

The SDK redacts Authorization headers and Bearer tokens from exc.cause before raising, so safe to log.

Documentation

License

MIT © Arcanada


Жизнь одного человека имеет значение / One human life matters

Metadata

Release files for arcanada-model-connector 0.1.1

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

Source distribution (sdist)

Source distribution for arcanada-model-connector 0.1.1
File Size Uploaded Provenance Actions
arcanada_model_connector-0.1.1.tar.gz 7.7 kB With provenance Details for arcanada_model_connector-0.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for arcanada-model-connector 0.1.1
File Interpreter ABI Platform Actions
arcanada_model_connector-0.1.1-py3-none-any.whl Python 3 none any Details for arcanada_model_connector-0.1.1-py3-none-any.whl

Total release size: 15.8 kB

Release files / arcanada_model_connector-0.1.1.tar.gz

Download URL arcanada_model_connector-0.1.1.tar.gz
Size 7.7 kB
Tags Source
SHA-256 checksum
How to use checksums
30a678638672ce315e46fe333f85585e7ece15ff602db11c81ab3f7b4bfd7956
BLAKE2b-256 checksum
How to use checksums
610c3dc82671f5031e7110fd0f1f2c9bddb5ba546362b2a42aa4d15c6ee87866
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

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 May 13, 2026.

Transparency log

Release files / arcanada_model_connector-0.1.1-py3-none-any.whl

Download URL arcanada_model_connector-0.1.1-py3-none-any.whl
Size 8.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
dffc6a9bc1a1437622c6f81ed674771d1529c7fd6a05b930a073f0e1ece43bb8
BLAKE2b-256 checksum
How to use checksums
5d414b013ce5798ffcac373eb5a620c3aa86ce05ac38962cf6cfc06a55bddba3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

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 May 13, 2026.

Transparency log

Security for arcanada-model-connector 0.1.1

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for arcanada_model_connector-0.1.1.tar.gz

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 May 13, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files Full provenance

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