Skip to main content

Minimal Python SDK for AnalogAI completion endpoints

Project description

AnalogAI SDK (minimal)

This workspace contains a tiny Python helper for calling AnalogAI completion endpoints.

Setup

  1. Install dependencies with Poetry.
  2. Set environment variables in .env (already created with placeholders):
    • ANALOGAI_API_KEY
    • ANALOGAI_AGENT_ID
    • ANALOGAI_BASE_URL (optional; defaults to https://app.analogai.net:7777)

Install (Poetry)

poetry install

Local install (editable)

poetry run pip install -e .

Global install (Poetry)

poetry build
pip install dist/analogai-0.1.0-py3-none-any.whl

PyPI name

Once published, the package will be available on PyPI as analogai.

Usage

from analogai_sdk import AnalogAIClient

client = AnalogAIClient()
print(client.generate_completion("your text here"))

for chunk in client.generate_streaming_completion("your text here"):
    print(chunk)

Passing agent ID directly

from analogai_sdk import AnalogAIClient

client = AnalogAIClient(agent_id="your-agent-id")
print(client.generate_completion("your text here"))

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

analogai_sdk-0.1.3.tar.gz (2.1 kB view details)

Uploaded Source

Built Distribution

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

analogai_sdk-0.1.3-py3-none-any.whl (2.7 kB view details)

Uploaded Python 3

File details

Details for the file analogai_sdk-0.1.3.tar.gz.

File metadata

  • Download URL: analogai_sdk-0.1.3.tar.gz
  • Upload date:
  • Size: 2.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.12.10 Windows/11

File hashes

Hashes for analogai_sdk-0.1.3.tar.gz
Algorithm Hash digest
SHA256 4e466fdd9f2ecaf23b4d33a3fbb02d7d1b67ebb7698da9d87b1f5bfb236291ba
MD5 257ce3f3e78a0d1ee0552d484411b929
BLAKE2b-256 f9ce374f2cab354849e57e071d4c210f9a8c7de99c869f9dde4d35e61d0b1601

See more details on using hashes here.

File details

Details for the file analogai_sdk-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: analogai_sdk-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 2.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.12.10 Windows/11

File hashes

Hashes for analogai_sdk-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 44f91c36bf1f6136e6355a60765a77d84cb3012ca14fed8e7129e697a853d80c
MD5 f6ba973bc4057351647e37e5f56a28c1
BLAKE2b-256 4fd66c9e4bd0999918519ca8fc7c7ca813cac95d7087cd3adeb2e621f7c10b90

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