Installation - fctr-id/okta-ai-agent GitHub Wiki

Tako AI Agent Installation Guide

Complete setup instructions for cloning and running Tako from source

Version: 2.0-beta

â„šī¸ Note: This guide is for users who want to clone and run Tako from source. For the easiest setup experience, we recommend using our Docker installation instead.

Table of Contents

Installation

Prerequisites

Before you begin installation, ensure you have the following:

  • 🐍 Python 3.12+ - Tako requires Python 3.12 or newer
  • 🔧 Git Client - Required for cloning the repository
  • đŸ“Ļ Node.js 18+ - Required for building the frontend interface
  • đŸĸ Okta tenant with admin access - You'll need superadmin privileges to generate an API token
  • 🤖 Access to an AI provider - You'll need at least one of the following:
    • Google Vertex AI
    • OpenAI
    • Azure OpenAI
    • Anthropic Claude
    • AWS Bedrock
    • Local Ollama
    • OpenAI-compatible providers (Fireworks AI, OpenRouter, etc.)

Option 1: Standard Installation (Clone from Source)

If you prefer to run Tako directly from source code:

📂 Step 1: Clone the Repository

git clone https://github.com/fctr-id/okta-ai-agent
cd okta-ai-agent

🐍 Step 2: Set Up Python Virtual Environment

Windows (PowerShell)

# Create virtual environment
python -m venv venv

# Activate virtual environment
.\venv\Scripts\Activate.ps1

# Install requirements
pip install -r requirements.txt

Linux/macOS

# Create virtual environment
python3 -m venv venv

# Activate virtual environment
source venv/bin/activate

# Install requirements
pip install -r requirements.txt

âš™ī¸ Step 3: Configure Your Environment

cp .env.sample .env

Edit the .env file with your settings:

# 🔐 Okta Configuration
OKTA_CLIENT_ORGURL=https://your-dev-instance.okta.com
OKTA_API_TOKEN=your-okta-api-token

# 🧠 AI Settings
AI_PROVIDER=vertex_ai
USE_PRE_REASONING=True

# 🌐 Vertex AI Configuration (example)
VERTEX_AI_SERVICE_ACCOUNT_FILE=path/to/service-account.json
VERTEX_AI_REASONING_MODEL=gemini-1.5-pro
VERTEX_AI_CODING_MODEL=gemini-1.5-pro

# 🔧 API Rate Limiting (adjust based on your Okta tenant)
OKTA_CONCURRENT_LIMIT=45

đŸ—ī¸ Step 4: Build the Frontend

cd src/frontend
npm install
npm run build
cd ../..

🚀 Running the Agent

After installation and configuration, you can run Tako in different ways:

🌐 Web Interface (Recommended)

The web interface provides Tako's unified multi-agent experience through your browser.

# Navigate to the scripts directory
cd scripts

# Start the web server
python start_server.py

🌐 Access the web interface at: https://localhost:8001

The web interface allows you to:

  • đŸ’Ŧ Submit queries through an intuitive chat interface
  • 📊 View results in formatted tables with intelligent data source indicators
  • 📤 Export data to various formats
  • 🔄 Experience real-time API querying and database hybrid mode
  • đŸŽ¯ See Tako's multi-agent orchestration in action

đŸ’ģ Command-Line Interface (Legacy Mode)

âš ī¸ Note: CLI mode provides basic functionality but doesn't include the advanced multi-agent orchestration available in the web interface.

# First, sync your Okta data (optional - Tako can work in API-only mode)
cd scripts
python fetch_data.py

# Then start the CLI agent
python Okta_Realtime_Agent.py

You'll see a prompt where you can type natural language queries about your Okta environment.

Option 2: Docker Installation

đŸŗ Recommended: For the easiest setup experience, use our Docker installation from the main README.md

If you prefer to run Tako in Docker:

Step 1: Create Required Directories

mkdir -p okta-ai-agent/data okta-ai-agent/logs okta-ai-agent/certs
cd okta-ai-agent

Step 2: Create and Configure .env File

# Download the sample env file
curl -o .env.sample https://raw.githubusercontent.com/fctr-id/okta-ai-agent/main/.env.sample

# Create your own .env file
cp .env.sample .env

Edit the .env file with your settings.

Step 3: Run with Docker

docker run -d \
  --name tako-ai-agent \
  -p 8001:8001 \
  -v $(pwd)/.env:/app/.env \
  -v $(pwd)/data:/app/data \
  -v $(pwd)/logs:/app/logs \
  -v $(pwd)/certs:/app/certs \
  fctr/okta-ai-agent:latest

Step 4: Access the Application

  • Web Interface: https://localhost:8001
  • View Logs: docker logs -f tako-ai-agent
  • Sync Data: docker exec tako-ai-agent python scripts/fetch_data.py

Troubleshooting

Common Issues

🔌 Connection Errors

  • Ensure your Okta API token is valid and has sufficient permissions
  • Check your internet connection
  • Verify the Okta URL is correct and accessible
  • Check the OKTA_CONCURRENT_LIMIT setting if you see rate limit errors

🤖 AI Provider Issues

  • Verify your API keys are correct and not expired
  • Check if you have sufficient quota/credits with your AI provider
  • For Ollama, ensure the service is running and models are properly loaded
  • Test your AI provider configuration with simple queries first

💾 Database Errors

  • Check for file permission issues with the SQLite database in sqlite_db/
  • Ensure you have sufficient disk space
  • Try resetting the database if it becomes corrupted

đŸ—ī¸ Frontend Build Issues

  • Ensure Node.js 18+ is installed
  • Clear npm cache: npm cache clean --force
  • Delete node_modules and run npm install again
  • Check for TypeScript compilation errors

Logs

Check the logs for detailed error information:

  • Log files are stored in the logs/ directory
  • Default log level is INFO
  • You can change log level in your .env file: LOG_LEVEL=DEBUG
  • Web server logs are shown in the terminal when running python start_server.py

Community Examples

Try these example queries to get started with Tako's multi-agent system:

đŸŽ¯ User Management Queries

  • đŸ‘Ĩ "Who are my active users?"
  • đŸŽ¯ "Show me users in the 'Sales' application"
  • 👤 "Find users without MFA"
  • 📊 "Count users by department"
  • 🛑 "List deactivated users in the last 30 days"

🔐 Security & Authentication

  • 📱 "List everyone with PUSH authentication"
  • 🔑 "Show expired API tokens"
  • 🔍 "Find users with access to Salesforce and Workday"
  • âš ī¸ "Show users with privileged access"

📈 Advanced Analytics

  • 📊 "Create a report of application usage by department"
  • 🔄 "Show me group membership overlaps"
  • 📅 "List users who haven't logged in for 90 days"
  • đŸŽ¯ "Find applications with no active users"

💡 Want to contribute your own examples? Visit our Community Query Repository.


🎉 You're All Set! Tako is now ready to help you manage your Okta environment with advanced AI capabilities. Start with simple queries and gradually explore more complex scenarios as you become familiar with Tako's multi-agent orchestration.


🌟 Š 2025 Fctr. All rights reserved. Made with â¤ī¸ for the Okta community.

Not affiliated with Okta, Inc.

âš ī¸ **GitHub.com Fallback** âš ī¸