Skip to main content

A lightweight library for building AI applications

Project description

ailoy-py

Ailoy is a lightweight library for building AI applications — such as agent systems or RAG pipelines — with ease. It is designed to enable AI features effortlessly, one can just import and use.

See our documentation for more details.

Install

pip install ailoy-py

Quickstart

Asynchronous version (recommended)

import asyncio

import ailoy as ai


async def main():
    # Create Qwen3-0.6B local LangModel
    model = await ai.LangModel.new_local("Qwen/Qwen3-0.6B")

    # Create an agent using this model
    agent = ai.Agent(model)

    # Ask a prompt and iterate over agent's responses
    async for resp in agent.run("What is your name?"):
        print(resp)


if __name__ == "__main__":
    asyncio.run(main())

Synchronous version

import ailoy as ai


def main():
    # Create Qwen3-0.6B LocalLanguageModel
    model = ai.LangModel.new_local_sync("Qwen/Qwen3-0.6B")

    # Create an agent using this model
    agent = ai.Agent(model)

    # Ask a prompt and iterate over agent's responses
    for resp in agent.run_sync("What is your name?"):
        print(resp)


if __name__ == "__main__":
    main()

Building from source

Prerequisites

  • Rust >= 1.88
  • Python >= 3.10
  • C/C++ compiler (recommended versions are below)
    • GCC >= 13
    • LLVM Clang >= 17
    • Apple Clang >= 15
    • MSVC >= 19.29
  • CMake >= 3.28.0
  • Git
  • OpenMP (required to build Faiss)
  • BLAS (required to build Faiss)
  • LAPACK (required to build Faiss)
  • Vulkan SDK (on Windows and Linux)

[!WARNING] To build binding, you must change the crate type to cdylib in Cargo.toml.

[lib]
crate-type = ["dylib"] # <- Change this to ["cdylib"]

Setup development environment

pip install maturin

# This generates `_core.cpython-3xx-darwin.so` under `ailoy/`
maturin develop

Generate wheel

maturin build --out ./dist

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

ailoy_py-0.2.2-cp310-abi3-win_amd64.whl (17.9 MB view details)

Uploaded CPython 3.10+Windows x86-64

ailoy_py-0.2.2-cp310-abi3-manylinux_2_28_x86_64.whl (17.0 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.28+ x86-64

ailoy_py-0.2.2-cp310-abi3-macosx_15_0_arm64.whl (12.2 MB view details)

Uploaded CPython 3.10+macOS 15.0+ ARM64

File details

Details for the file ailoy_py-0.2.2-cp310-abi3-win_amd64.whl.

File metadata

  • Download URL: ailoy_py-0.2.2-cp310-abi3-win_amd64.whl
  • Upload date:
  • Size: 17.9 MB
  • Tags: CPython 3.10+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for ailoy_py-0.2.2-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 d9c92d043990a61f4d337f61b679ffaa3e78e140ad643c0c91bf799b6678d68b
MD5 4fdd5871e66861b1814423fd8dd62fc2
BLAKE2b-256 02a82768bde8a10971e5ba8c10460a31efc5a60ee685c24024d0fd9ce63f6647

See more details on using hashes here.

Provenance

The following attestation bundles were made for ailoy_py-0.2.2-cp310-abi3-win_amd64.whl:

Publisher: build_python_windows.yaml on brekkylab/ailoy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ailoy_py-0.2.2-cp310-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for ailoy_py-0.2.2-cp310-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 84d67767d5c20dc6afdd733fdb974dc1d11a8754cbc288716b16ccfb28b70117
MD5 9472dd076bacf860e39ae97c36e46d04
BLAKE2b-256 29bb9c786a6ad9016ae256652f6ab17258404636cff28a06039ae76938da92d0

See more details on using hashes here.

Provenance

The following attestation bundles were made for ailoy_py-0.2.2-cp310-abi3-manylinux_2_28_x86_64.whl:

Publisher: build_python_linux.yaml on brekkylab/ailoy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ailoy_py-0.2.2-cp310-abi3-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for ailoy_py-0.2.2-cp310-abi3-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 0abb501e31c76e561b516058df97fa0aefa0383592447b23493afede9427c672
MD5 af10eee3cfa32b9c1b55d17a66e0be04
BLAKE2b-256 df4968df1b97e94b4c835aa2644e5f4276d05e39b96f671f016e74c78c31e68c

See more details on using hashes here.

Provenance

The following attestation bundles were made for ailoy_py-0.2.2-cp310-abi3-macosx_15_0_arm64.whl:

Publisher: build_python_macos.yaml on brekkylab/ailoy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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