πŸ“¦ InstallationΒΆ

Complete installation guide for Ryoma AI with all database connectors and optional features.

πŸ“‹ PrerequisitesΒΆ

  • Python 3.9+ - Ryoma requires Python 3.9 or higher

  • API Key - OpenAI, Anthropic, or other supported LLM provider

  • Database Drivers - For your specific database (optional)

πŸš€ Quick InstallationΒΆ

Basic InstallationΒΆ

pip install ryoma_ai

This installs the core Ryoma package with basic functionality.

With Database SupportΒΆ

# PostgreSQL support
pip install ryoma_ai[postgres]

# MySQL support
pip install ryoma_ai[mysql]

# Snowflake support
pip install ryoma_ai[snowflake]

# BigQuery support
pip install ryoma_ai[bigquery]

# All database connectors
pip install ryoma_ai[all]

πŸ—„οΈ Database-Specific SetupΒΆ

PostgreSQLΒΆ

pip install ryoma_ai[postgres]
from ryoma_ai.datasource.postgres import PostgresDataSource

datasource = PostgresDataSource(
    connection_string="postgresql://user:password@localhost:5432/database"
)

SnowflakeΒΆ

pip install ryoma_ai[snowflake]
from ryoma_ai.datasource.snowflake import SnowflakeDataSource

datasource = SnowflakeDataSource(
    account="your-account",
    user="your-user",
    password="your-password",
    database="your-database",
    warehouse="your-warehouse"
)

BigQueryΒΆ

pip install ryoma_ai[bigquery]
from ryoma_ai.datasource.bigquery import BigQueryDataSource

datasource = BigQueryDataSource(
    project_id="your-project-id",
    credentials_path="/path/to/service-account.json"
)

🧠 LLM Provider Setup¢

OpenAIΒΆ

export OPENAI_API_KEY="your-openai-api-key"
from ryoma_ai.agent.sql import SqlAgent

agent = SqlAgent(model="gpt-4", mode="enhanced")

Anthropic ClaudeΒΆ

pip install anthropic
export ANTHROPIC_API_KEY="your-anthropic-api-key"
agent = SqlAgent(model="claude-3-sonnet-20240229", mode="enhanced")

Local Models (Ollama)ΒΆ

# Install Ollama
curl -fsSL https://ollama.ai/install.sh | sh
ollama pull codellama:13b

pip install ollama
from ryoma_ai.models.ollama import OllamaModel

model = OllamaModel("codellama:13b")
agent = SqlAgent(model=model, mode="enhanced")

βœ… Verify InstallationΒΆ

import ryoma_ai
print(f"Ryoma AI version: {ryoma_ai.__version__}")

# Test basic functionality
from ryoma_ai.agent.sql import SqlAgent
from ryoma_ai.datasource.sqlite import SqliteDataSource

datasource = SqliteDataSource(":memory:")
agent = SqlAgent("gpt-3.5-turbo", mode="enhanced")
agent.add_datasource(datasource)

print("βœ… Ryoma AI installation successful!")

🎯 Next Steps¢