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
| Key | Env Var | Default | Description |
|---|---|---|---|
server.port | FOWYLD_PORT | 8000 | HTTP listen port |
server.workers | FOWYLD_WORKERS | 4 | Number of worker processes |
server.log_level | FOWYLD_LOG_LEVEL | info | Logging 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:
| Variable | Maps To | Example |
|---|---|---|
FOWYLD_PORT | server.port | 8000 |
FOWYLD_LOG_LEVEL | server.log_level | debug |
FOWYLD_DATA_DIR | storage.data_dir | /opt/data |
FOWYLD_TLS_CERT | tls.cert_path | /certs/cert.pem |
FOWYLD_TLS_KEY | tls.key_path | /certs/key.pem |
FOWYLD_API_KEY | security.api_keys[0].key | fai_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