Development Setup
This guide will help you set up a complete development environment for ARKOS, including all dependencies and configurations.System Requirements
Minimum Requirements
- OS: Ubuntu 20.04+, macOS 11+, or Windows 10+ with WSL2
- Python: 3.8 or higher
- RAM: 8GB minimum
- Storage: 20GB free space
- CPU: 4 cores recommended
Recommended Requirements
- RAM: 16GB or more
- GPU: NVIDIA GPU with 8GB+ VRAM (for local models)
- Storage: 50GB+ for model files
- CPU: 8+ cores for better performance
Environment Setup
1. Python Environment
- Using venv
- Using conda
2. Clone Repository
3. Install Dependencies
Dependencies Overview
Current Dependencies (requirements.txt)
Dependency Details
Configuration Files
1. Environment Variables (.env)
Create a.env file in the project root:
.env with your configuration:
2. YAML Configuration
The main configuration file isconfig_module/config.yaml:
Database Setup
PostgreSQL (Required)
ARKOS requires PostgreSQL for conversation context storage.Using Supabase (Recommended)
- Create a Supabase project
- Get your connection string from Settings > Database
- Set
DB_URLin your.envfile
Using Local PostgreSQL
Database Schema
Create the required table:Running SGLANG
Check if Already Running
On shared servers, the LLM server may already be running:Start the LLM Server
Only one instance can run on port 30000 at a time. Coordinate with your team on shared servers.
Running the Application
1. Start the LLM Server
2. Start the API Server
3. Start the CLI Interface (Optional)
Verify Setup
IDE Configuration
VS Code
Create.vscode/settings.json:
PyCharm
- Set Python interpreter to virtual environment
- Enable pytest as test runner
- Configure code style with Black formatter
Testing
Running Tests
Test Configuration
Debugging
Enable Debug Logging
VS Code Launch Configuration
Create.vscode/launch.json:
Common Issues
ImportError: No module named 'module_name'
ImportError: No module named 'module_name'
Add the project root to PYTHONPATH:
Database connection failed
Database connection failed
Verify your
DB_URL in .env:LLM server not responding
LLM server not responding
Check if SGLang is running:If not, start it with
bash model_module/run.shPort already in use
Port already in use
Find and kill the process:
CUDA out of memory
CUDA out of memory
Reduce batch size or use a smaller model:
Environment variable not found
Environment variable not found
Ensure
.env file exists and is in the project root:Project Structure
Next Steps
Testing Guide
Learn about testing strategies
Quick Start
Start using ARKOS
Architecture
Understand the system design
API Reference
Explore the APIs