Skip to main content

Gemini AI automation client with persistent memory, async support, and provider routing.

Project description

CycloneAI

CycloneAI is a small Python package that keeps the public API simple:

from cycloneai import Client

ai = Client(provider="auto")
print(ai.ask("Hello"))

What is included

  • Client and AsyncClient
  • ask(), stream(), compare(), save(), load()
  • conversation memory
  • provider routing with provider="auto" and fallback
  • provider registration for custom backends

What is not included

This package does not automate guest access to third-party hosted LLM websites. The built-in gemini, gpt, and claude providers are explicit placeholders so the public API and provider architecture are ready without shipping code that attempts to bypass official access controls or service terms.

If you want real responses, register your own compliant provider implementation.

Usage

Basic

from cycloneai import Client

ai = Client(provider="auto")
reply = ai.ask("Python study order")
print(reply)

Memory

chat = Client(memory=True)
chat.register_provider(MyProvider())

chat.ask("My name is Hyunho")
chat.ask("What is my name?")

System prompt

ai = Client(system="You are the best coding mentor.")
ai.register_provider(MyProvider())

Streaming

for chunk in ai.stream("Write a short story"):
    print(chunk, end="")

Async

from cycloneai import AsyncClient

ai = AsyncClient()
ai.register_provider(MyProvider())
print(await ai.ask("What is AI?"))

Top-level helper

import cycloneai as cy

provider = MyProvider()
print(cy.ask("Hi", provider=provider))

Custom provider example

from cycloneai import BaseProvider, Client, Response


class MyProvider(BaseProvider):
    name = "demo"

    def ask(self, prompt, *, system=None, history=None, timeout=30):
        return Response(
            text=f"demo reply: {prompt}",
            provider=self.name,
            time=0.01,
            tokens=None,
        )


ai = Client(provider=MyProvider())
print(ai.ask("Hello"))

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

cycloneai-0.2.2.tar.gz (14.3 kB view details)

Uploaded Source

Built Distribution

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

cycloneai-0.2.2-py3-none-any.whl (16.9 kB view details)

Uploaded Python 3

File details

Details for the file cycloneai-0.2.2.tar.gz.

File metadata

  • Download URL: cycloneai-0.2.2.tar.gz
  • Upload date:
  • Size: 14.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for cycloneai-0.2.2.tar.gz
Algorithm Hash digest
SHA256 343caa8e1be46e6b2ae5c95a3da01e078647372df5f4f95ef1689d826582a619
MD5 ec4c6f2d431550fc87e83986b938fa0d
BLAKE2b-256 0488e42bda5a74be911f07c6db5f98c91a6eba2b7983502f3cace5300c9cff1e

See more details on using hashes here.

File details

Details for the file cycloneai-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: cycloneai-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 16.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for cycloneai-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 986caee80968b5cd190a6f2d03ff60d5b4523b19148bee98d225b7c4f82a60e1
MD5 5cb9c9b3719a49b137d42c51af0ca450
BLAKE2b-256 2a9b50e3ccb42a8257d88003ba754e81d7cb83bbfb437a7bed92aebf42a4e163

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