# TURBO-CDI v5.3.1 Dependencies

# Core Scientific
numpy>=1.24.0
scipy>=1.10.0
pandas>=2.0.0  # required (not optional): imported by src/causal, src/data

# Graph Database
networkx>=3.0
dowhy>=0.8.0 # optional

# Type Safety & Data Validation
pydantic>=2.0.0

# Configuration
pyyaml>=6.0.0

# CLI & UI
typer[all]>=0.9.0
rich>=13.0.0
prompt-toolkit>=3.0.0
textual>=0.40.0  # TUI widgets (src/tui) — pulled in by the REPL (src/repl); top-level import

# Retry Logic
tenacity>=8.0.0

# Async runtime / caching (direct top-level imports; also in pyproject)
anyio>=4.0.0        # src/cache/tier4_upstream.py (also transitive via fastapi/httpx)
cachetools>=5.0.0   # src/analogy/operations.py LRUCache

# Formal Verification
z3-solver>=4.16.0.0  # src/verification/hoare_verifier.py (top-level) + lazy in provers/mcp

# WASM Plugin Runtime
wasmtime>=14.0.0          # WASM sandbox execution (optional — stub mode works without)
scikit-learn>=1.3.0       # TfidfVectorizer for N-version voting gates
python-dotenv>=1.0.0      # .env loading

# LLM Integration
openai>=1.0.0
httpx>=0.27.0  # Async HTTP client

# Research APIs
feedparser>=6.0.0
biopython>=1.81
beautifulsoup4>=4.10.0  # HTML scraping — src/social/researchgate_client.py (top-level, live via auto_poster)

# Embeddings & ML (Analogy Engine)
sentence-transformers>=2.2.0
gensim>=4.3.0
scikit-learn>=1.3.0

# ═══════════════════════════════════════════════════════════════
# API SERVER DEPENDENCIES (Required for production)
# ═══════════════════════════════════════════════════════════════
fastapi>=0.104.0
uvicorn[standard]>=0.24.0
python-multipart>=0.0.31  # Form data handling
starlette>=0.27.0

# Database
asyncpg>=0.29.0  # Async PostgreSQL
psycopg2-binary>=2.9.0  # PostgreSQL driver for Alembic
sqlalchemy>=2.0.0  # ORM
alembic>=1.12.0  # Database migrations

# Cache
redis>=5.0.0  # Redis client

# Authentication
pyjwt>=2.13.0
bcrypt>=4.1.0

# ═══════════════════════════════════════════════════════════════
# Optional: Experiment Tracking (Phase 3)
# ═══════════════════════════════════════════════════════════════
# mlflow>=2.0.0

# ═══════════════════════════════════════════════════════════════
# OBSERVABILITY & LOGGING
# ═══════════════════════════════════════════════════════════════
structlog>=23.0.0          # Structured JSON logging
prometheus-client>=0.25.0  # /metrics endpoint (src/api/routers/metrics.py, top-level import)
opentelemetry-api>=1.20.0   # OpenTelemetry tracing (optional)
opentelemetry-sdk>=1.20.0   # OpenTelemetry SDK (optional)
sentry-sdk>=1.40.0         # Error tracking (optional)

# ═══════════════════════════════════════════════════════════════
# DEVELOPMENT DEPENDENCIES
# ═══════════════════════════════════════════════════════════════
pytest>=7.4.0
pytest-asyncio>=0.21.0
pytest-cov>=4.1.0
pytest-timeout>=2.1.0
# black>=23.0.0
# flake8>=6.0.0
mypy>=1.5.0

# Security
cryptography>=48.0.1

# Simulations (optional)
numba>=0.56.0 # optional
matplotlib>=3.5.0 # optional
newton-physics>=0.1.0  # optional (GPU-accelerated physics, Apache 2.0)

# Bayesian (optional)
pymc>=5.0.0 # optional
arviz>=0.14.0 # optional

# LLM
anthropic>=0.7.0
pydantic-ai>=0.0.30
