# =============================================================================
# NARRATIVE AI FRAMEWORK - Requirements
# =============================================================================
# Install with: pip install -r requirements.txt
#
# For GPU support (CUDA), install PyTorch separately first:
#   pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
# =============================================================================

# -----------------------------------------------------------------------------
# CORE DEPENDENCIES (Required)
# -----------------------------------------------------------------------------

# Configuration
PyYAML>=6.0.1
python-dotenv>=1.0.0

# Async Support
aiohttp>=3.9.0
aiofiles>=23.2.1

# HTTP client (used by STT retry logic)
requests>=2.28.0
shortuuid>=1.0.11
scipy>=1.10.0
soundfile>=0.12.1
python-multipart>=0.0.6
pyngrok>=7.0.0
nest-asyncio>=1.5.8
sympy>=1.12

# Web search provider
ddgs>=9.0.0

# Data Processing
numpy>=1.24.0
pydantic>=2.5.0

# Web Framework (API server)
fastapi>=0.109.0
uvicorn[standard]>=0.27.0
python-multipart>=0.0.6
email-validator>=2.1.0

# -----------------------------------------------------------------------------
# AUDIO PROCESSING (Required for STT)
# -----------------------------------------------------------------------------

# Audio file handling
soundfile>=0.12.1
sounddevice>=0.5.0

# Audio processing
scipy>=1.11.0

# Voice Activity Detection (WebRTC VAD)
webrtcvad>=2.0.10

# -----------------------------------------------------------------------------
# STT PROVIDERS
# -----------------------------------------------------------------------------

# Whisper (Local model)
transformers>=4.36.0
accelerate>=0.25.0
torch>=2.1.0

# Faster-Whisper (CTranslate2)
ctranslate2>=4.0.0
faster-whisper>=1.0.0

# -----------------------------------------------------------------------------
# SECURITY LAYER
# -----------------------------------------------------------------------------

# Rate limiting
redis>=5.0.0

# Database ORM & migrations
SQLAlchemy>=2.0.0
asyncpg>=0.29.0
psycopg2-binary>=2.9.0
alembic>=1.13.0

# Encryption
cryptography>=41.0.0

# JWT tokens
PyJWT>=2.8.0

# Password hashing
bcrypt>=4.0.0

# -----------------------------------------------------------------------------
# LLM PROVIDERS (Language Models)
# -----------------------------------------------------------------------------

# Google Gemini
google-generativeai>=0.3.0
google-genai>=0.3.0

# OpenAI (OpenAI, xAI/Grok, DeepSeek)
openai>=1.3.0

# Anthropic Claude
anthropic>=0.18.0

# Token counting
tiktoken>=0.5.0

# -----------------------------------------------------------------------------
# LIVEKIT (Real-time voice mode)
# -----------------------------------------------------------------------------

livekit>=0.11.0
livekit-api>=0.4.0
livekit-agents>=0.7.0
livekit-plugins-silero>=0.6.0
livekit-plugins-elevenlabs>=1.3.0
livekit-plugins-turn-detector>=1.3.0
livekit-plugins-noise-cancellation>=0.2.0

# -----------------------------------------------------------------------------
# RAG / Vector search (from rag_input_proc)
# -----------------------------------------------------------------------------
sentence-transformers>=2.2.2
pgvector>=0.2.5
pillow>=10.0.0
psutil>=5.9.0

# -----------------------------------------------------------------------------
# OCR PROCESSING (Sherif's Model & DocRes Support)
# -----------------------------------------------------------------------------

# Image & Document Parsing
opencv-python>=4.8.0
scikit-image>=0.21.0
pdf2image>=1.16.3
python-docx>=1.1.0
einops>=0.6.1

# OCR Deep Learning (Kaggle Client & Local Inference)
# Note: Using version ranges for better 3.10 compatibility
torch>=2.0.1
torchvision>=0.15.2
transformers>=4.45.0
accelerate>=0.26.0
qwen-vl-utils>=0.0.4

# -----------------------------------------------------------------------------
# OPTIONAL
# -----------------------------------------------------------------------------

# Advanced audio processing (Add librosa here if needed)

# Monitoring (Add prometheus_client here if needed)

# -----------------------------------------------------------------------------
# DEVELOPMENT & TESTING
# -----------------------------------------------------------------------------

pytest>=7.4.0
pytest-asyncio>=0.23.0
pytest-cov>=4.1.0
httpx>=0.25.0
mypy>=1.7.0
ruff>=0.1.0
