Skip to main content

Python API client for ApolaAI server with Gemini 2.5 Flash + 50+ textbooks

Project description

ApolaAI Python Client

🚀 Connect to ApolaAI server powered by Gemini 2.5 Flash + 50+ Sri Lankan textbooks

Installation

pip install apolaai

Quick Start

from apolaai import generatetext, generateaudio, generateimage, set_server_url

# Configure server (if not using default)
set_server_url("https://your-apolaai-server.railway.app")

# Generate educational content with textbook context
result = generatetext(
    "Explain photosynthesis in simple terms",
    textbook="Grade 06 Science",
    user_id="student-1"
)

if result['success']:
    print(result['text'])

Features

  • 🔤 Smart Text Generation - Contextual responses using 50+ textbooks
  • 🔊 Audio Generation - High-quality text-to-speech
  • 🖼️ Educational Images - Curriculum-aligned visual content
  • 📚 Textbook Integration - Grade 6-11 Sri Lankan curriculum
  • 🎯 Simple API - Easy-to-use functions with consistent responses

Functions

from apolaai import (
    generatetext,        # Generate text with textbook context
    generateaudio,       # Convert text to speech
    generateimage,       # Create educational images
    check_server_status, # Check server health
    set_server_url,      # Configure server endpoint
    get_available_voices # List available voices
)

Example Usage

import apolaai

# Check server status
status = apolaai.check_server_status()
print(f"Server: {status['status']}")

# Generate educational content
result = apolaai.generatetext(
    "What is the water cycle?",
    textbook="Grade 07 Geography"
)

if result['success']:
    print(result['text'])

Requirements

  • Python 3.7+
  • Access to ApolaAI server

Links


Made with ❤️ for Sri Lankan education by ApolaAI

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

apolaai-2.0.0.tar.gz (5.0 kB view details)

Uploaded Source

Built Distribution

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

apolaai-2.0.0-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file apolaai-2.0.0.tar.gz.

File metadata

  • Download URL: apolaai-2.0.0.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for apolaai-2.0.0.tar.gz
Algorithm Hash digest
SHA256 b1d6ebe307f21963448aa7a18985c97cd8d4b7fd19d1c3c9c633c4453d7327d9
MD5 a8341281ac5e7e7a9d5ea2ac19b515a2
BLAKE2b-256 83bc4b760c7a4b3c8b9796fda355e4d82c123736583e966cd9536a2d0903187b

See more details on using hashes here.

File details

Details for the file apolaai-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: apolaai-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for apolaai-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e206def53b2d86745bb688a69249e923b71293a3dca24db666888671bc273655
MD5 24ea725811329c00823fd6508428a98d
BLAKE2b-256 43d23d71010fb6ae79f3c97601672c1fb7076c08e156b2f127d8325432cc94fe

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