Command Line Options
Basic Syntax
Required Arguments
string
required
HuggingFace model ID or local path to model.Examples:
Server Options
string
default:"0.0.0.0"
Host address to bind the server to.
0.0.0.0- Listen on all interfaces (accessible externally)127.0.0.1- Localhost only (more secure for development)- Specific IP - Bind to a specific network interface
int
default:8000
Port to bind the server to.Examples:
Make sure the port is not already in use. Check with:
lsof -i :8000Model Configuration
string
default:"float16"
Data type for model weights.Options:
float16/fp16- Half precision (recommended for most GPUs)bfloat16/bf16- Brain float 16 (better for FLUX, requires Ampere+ GPUs)float32/fp32- Full precision (highest quality, most VRAM)
string
default:"cuda"
Device to run the model on.Options:
cuda- NVIDIA GPU (recommended)cpu- CPU only (very slow)mps- Apple Silicon GPU (experimental)cuda:0,cuda:1, etc. - Specific GPU
string
default:null
Path to LoRA weights to load at startup.Examples:
The server will load the LoRA weights from the specified directory. The directory should contain
adapter_config.json and adapter_model.safetensors.Authentication
string
default:null
API key for authentication. If set, all requests must include this key.Examples:Client usage:
Queue Configuration
int
default:100
Maximum number of requests that can be queued.When the queue is full, new requests return HTTP 503 (Service Unavailable).Examples:
int
default:1
Maximum number of requests to process in a single batch.Future usage:
Batch processing is not fully implemented yet. This parameter is reserved for Phase 2.
Development Options
boolean
default:false
Enable auto-reload on code changes (development only).Example:
Configuration Examples
Local Development
- No authentication
- Localhost only
- Default settings
Production Deployment
- External access
- Secure API key
- Optimized settings
High-Quality FLUX Server
- BFloat16 for best quality
- Authentication enabled
- Moderate queue size
Multi-Model Setup
Run multiple servers on different ports:With LoRA
Behind Reverse Proxy
Environment Variables
While HyperGen doesn’t use environment variables for configuration, you can use them in your commands:systemd Service
For production deployments on Linux:Docker Deployment
Example Dockerfile:Best Practices
Security
- Always use API keys in production
- Run behind HTTPS (nginx/caddy)
- Use firewall rules
- Don’t expose directly to internet
Performance
- Use float16 for most models
- Use bfloat16 for FLUX
- Tune queue size based on traffic
- Monitor GPU memory usage
Reliability
- Use systemd for auto-restart
- Set up health check monitoring
- Log to files for debugging
- Set up alerts for errors
Scalability
- Use reverse proxy for load balancing
- Run multiple servers for different models
- Cache frequently used models
- Monitor queue sizes
Next Steps
Quick Start
Start your first server
Overview
Understand the architecture
Supported Models
See compatible models
Examples
Client code examples