v1.4

Configuration

Customize every aspect of FowyldAI through config.yaml or environment variables.

Configuration File

FowyldAI reads configuration from /app/config/config.yaml (Docker) or ./config/config.yaml (binary). Environment variables override file settings.

Server

server:
  host: "0.0.0.0"
  port: 8000
  workers: 4
  log_level: "info"       # debug, info, warning, error
  cors_origins: ["*"]     # Restrict in production
KeyEnv VarDefaultDescription
server.portFOWYLD_PORT8000HTTP listen port
server.workersFOWYLD_WORKERS4Number of worker processes
server.log_levelFOWYLD_LOG_LEVELinfoLogging verbosity

Models

Configure which models to load and their resource allocation.

models:
  default: "fowyld-general"
  auto_route: true          # Route queries to optimal model
  load_on_startup:
    - id: "fowyld-general"
      path: "/app/models/general"
      max_memory_mb: 4096
      quantization: "Q4_K_M"
    - id: "fowyld-embed"
      path: "/app/models/embed"
      max_memory_mb: 512
Model auto-routing When auto_route: true, FowyldAI analyzes query complexity and routes to the most efficient model. Disable for deterministic model selection.

Storage

storage:
  data_dir: "/app/data"
  logs_dir: "/app/logs"
  max_log_size_mb: 100
  retention_days: 30

TLS / HTTPS

tls:
  enabled: true
  cert_path: "/app/certs/cert.pem"
  key_path: "/app/certs/key.pem"
  mtls:
    enabled: false
    ca_path: "/app/certs/ca.pem"

For TLS termination at a reverse proxy, leave TLS disabled and configure your proxy instead.

Security

security:
  api_key_required: false
  api_keys:
    - name: "production-app"
      key: "fai_xxxxxxxxxxxxxxxxxxxx"
      scopes: ["ask", "models", "embeddings"]
    - name: "monitoring"
      key: "fai_yyyyyyyyyyyyyyyyyyyy"
      scopes: ["health"]

rate_limiting:
  enabled: false
  requests_per_minute: 60
  burst: 10

Network Guard

FowyldAI's network guard blocks all outbound connections by default. This is a core sovereignty feature.

network:
  outbound_blocked: true    # Block all external network calls
  allowed_hosts: []         # Whitelist specific hosts if needed
  telemetry: false          # Never send telemetry
Zero egress by default The engine makes no outbound network calls. The network guard is an additional enforcement layer — even if a model attempted an external call, it would be blocked.

Environment Variables

All config keys can be overridden with environment variables using the FOWYLD_ prefix:

VariableMaps ToExample
FOWYLD_PORTserver.port8000
FOWYLD_LOG_LEVELserver.log_leveldebug
FOWYLD_DATA_DIRstorage.data_dir/opt/data
FOWYLD_TLS_CERTtls.cert_path/certs/cert.pem
FOWYLD_TLS_KEYtls.key_path/certs/key.pem
FOWYLD_API_KEYsecurity.api_keys[0].keyfai_xxx

Full Example

# Production config.yaml
server:
  host: "0.0.0.0"
  port: 8000
  workers: 8
  log_level: "warning"
  cors_origins: ["https://app.example.com"]

models:
  default: "fowyld-general"
  auto_route: true
  load_on_startup:
    - id: "fowyld-general"
      path: "/app/models/general"
      max_memory_mb: 8192

tls:
  enabled: true
  cert_path: "/app/certs/cert.pem"
  key_path: "/app/certs/key.pem"

security:
  api_key_required: true
  api_keys:
    - name: "production"
      key: "fai_xxxxxxxxxxxxxxxxxxxx"
      scopes: ["ask", "models", "embeddings", "health"]

network:
  outbound_blocked: true
  telemetry: false

storage:
  data_dir: "/app/data"
  logs_dir: "/app/logs"
  retention_days: 90