Comprehensive Troubleshooting Guide
Version: 2.0.0
Status: ✅ Production Ready
Overview
This guide provides comprehensive troubleshooting for the Gollek Inference Engine, integrated with the standardized error code system for quick diagnosis and resolution.
Error Code System
Gollek uses a standardized error code system for consistent error handling and troubleshooting.
Error Code Format
CATEGORY_NNN
- CATEGORY: Error category (MODEL, DEVICE, RUNTIME, etc.)
- NNN: Three-digit error number
Error Categories
| Category | Code Prefix | HTTP Status | Description |
|---|---|---|---|
| MODEL | MODEL_XXX | 404, 400 | Model-related errors |
| DEVICE | DEVICE_XXX | 503, 500 | Hardware/device errors |
| RUNTIME | RUNTIME_XXX | 500, 504 | Runtime execution errors |
| PLUGIN | PLUGIN_XXX | 500, 504 | Plugin lifecycle errors |
| PROVIDER | PROVIDER_XXX | 400-504 | Provider integration errors |
| CONFIG | CONFIG_XXX | 400, 500 | Configuration errors |
| NETWORK | NETWORK_XXX | 502-504 | Network errors |
| QUOTA | QUOTA_XXX | 429 | Resource quota errors |
| AUTH | AUTH_XXX | 401, 403 | Authentication errors |
| INIT | INIT_XXX | 500 | Initialization errors |
Error Payload Structure
All errors follow a standardized payload structure:
{
"type": "RUNTIME_INFERENCE_FAILED",
"message": "Inference execution failed",
"details": {
"errorCode": "RUNTIME_001",
"category": "RUNTIME",
"retryable": true
},
"retryable": true,
"originNode": "node-1",
"originRunId": "run-123",
"attempt": 1,
"maxAttempts": 3,
"timestamp": "2026-03-25T10:00:00Z",
"suggestedAction": "retry",
"provenanceRef": "ref-456"
}
Error Payload Fields
| Field | Type | Description |
|---|---|---|
type |
String | Error type/code |
message |
String | Human-readable message |
details |
Map | Additional error details |
retryable |
Boolean | Whether error is retryable |
originNode |
String | Node where error occurred |
originRunId |
String | Run ID for tracing |
attempt |
Integer | Current attempt number |
maxAttempts |
Integer | Maximum retry attempts |
timestamp |
Instant | Error timestamp |
suggestedAction |
String | Suggested resolution action |
provenanceRef |
String | Reference for tracing |
Common Errors and Solutions
Plugin Errors
PLUGIN_001: Plugin Initialization Failed
HTTP Status: 500
Retryable: No
Symptoms:
Error: Plugin initialization failed
Plugin: cuda-kernel
Details: CUDA not available
Solutions:
- Check if plugin JAR is present:
ls ~/.gollek/plugins/*.jar - Verify plugin manifest:
jar xf plugin.jar META-INF/MANIFEST.MF cat META-INF/MANIFEST.MF - Check plugin dependencies:
gollek plugin check <plugin-id> - Verify hardware availability:
# For CUDA nvidia-smi # For Metal system_profiler SPDisplaysDataType
PLUGIN_002: Plugin Execution Failed
HTTP Status: 500
Retryable: Yes
Symptoms:
Error: Plugin execution failed
Plugin: gguf-runner
Operation: infer
Solutions:
- Check plugin health:
gollek plugin health <plugin-id> - Verify model compatibility:
gollek model check <model-id> - Check resource availability:
gollek system resources - Retry with fallback:
gollek run --enable-cpu --model <model> --prompt <prompt>
PLUGIN_003: Plugin Configuration Invalid
HTTP Status: 500
Retryable: No
Symptoms:
Error: Plugin configuration invalid
Plugin: cuda-kernel
Invalid field: device_id
Solutions:
- Check configuration file:
cat ~/.gollek/config.yaml - Validate plugin configuration:
gollek plugin config <plugin-id> --validate - Reset to defaults:
gollek plugin config <plugin-id> --reset
Device Errors
DEVICE_001: Device Not Available
HTTP Status: 503
Retryable: Yes
Symptoms:
Error: Requested device not available
Device: cuda
Solutions:
- Check device availability:
gollek device list - Verify drivers installed:
# CUDA nvcc --version # ROCm rocminfo # Metal system_profiler SPDisplaysDataType - Use CPU fallback:
gollek run --use-cpu --model <model> --prompt <prompt> - Enable CPU fallback for production:
gollek run --enable-cpu --model <model> --prompt <prompt>
DEVICE_002: Device Out of Memory
HTTP Status: 503
Retryable: Yes
Symptoms:
Error: Device out of memory
Device: cuda
Available: 2GB
Required: 8GB
Solutions:
- Reduce model size:
gollek run --model <smaller-model> --prompt <prompt> - Enable memory optimization:
gollek run --optimize-memory --model <model> --prompt <prompt> - Use CPU for large models:
gollek run --use-cpu --model <large-model> --prompt <prompt> - Close other GPU applications:
nvidia-smi # Check GPU usage
DEVICE_005: GPU Not Found
HTTP Status: 503
Retryable: No
Symptoms:
Error: GPU not found
Platform: cuda
Solutions:
- Check GPU detection:
gollek device detect - Verify GPU hardware:
# Linux lspci | grep -i vga # macOS system_profiler SPDisplaysDataType # Windows dxdiag - Install/Update drivers:
# NVIDIA sudo apt install nvidia-driver-535 # AMD sudo apt install rocm-dkms - Use CPU until GPU available:
gollek run --use-cpu --model <model> --prompt <prompt>
Runtime Errors
RUNTIME_001: Inference Execution Failed
HTTP Status: 500
Retryable: Yes
Symptoms:
Error: Inference execution failed
Model: llama-3-8b
Runner: gguf-runner
Solutions:
- Check model integrity:
gollek model verify <model-id> - Verify runner compatibility:
gollek runner check <runner-id> --model <model-id> - Reduce batch size:
gollek run --batch-size 1 --model <model> --prompt <prompt> - Enable fallback:
gollek run --enable-cpu --model <model> --prompt <prompt>
RUNTIME_002: Inference Request Timeout
HTTP Status: 504
Retryable: Yes
Symptoms:
Error: Inference request timeout
Timeout: 60s
Model: llama-3-70b
Solutions:
- Increase timeout:
gollek run --timeout 120 --model <model> --prompt <prompt> - Use smaller model:
gollek run --model <smaller-model> --prompt <prompt> - Reduce max tokens:
gollek run --max-tokens 256 --model <model> --prompt <prompt> - Use GPU acceleration:
gollek run --platform cuda --model <model> --prompt <prompt>
RUNTIME_003: Out of Memory During Inference
HTTP Status: 500
Retryable: Yes
Symptoms:
Error: Out of memory during inference
Available: 4GB
Required: 16GB
Solutions:
- Enable memory optimization:
gollek run --optimize-memory --model <model> --prompt <prompt> - Use quantized model:
gollek run --model <model>-q4 --prompt <prompt> - Reduce context size:
gollek run --context-size 2048 --model <model> --prompt <prompt> - Use CPU with swap:
gollek run --use-cpu --model <model> --prompt <prompt>
Provider Errors
PROVIDER_001: Provider Not Initialized
HTTP Status: 503
Retryable: Yes
Symptoms:
Error: Provider not initialized
Provider: openai
Solutions:
- Check provider configuration:
gollek provider config openai --validate - Verify API key:
echo $OPENAI_API_KEY - Initialize provider:
gollek provider init openai - Check network connectivity:
curl https://api.openai.com/v1/models
PROVIDER_003: Provider Timeout
HTTP Status: 504
Retryable: Yes
Symptoms:
Error: Provider timeout
Provider: openai
Timeout: 30s
Solutions:
- Increase timeout:
export OPENAI_TIMEOUT=60 - Check network latency:
curl -w "@curl-format.txt" https://api.openai.com/v1/models - Use fallback provider:
gollek run --provider gemini --model <model> --prompt <prompt> - Enable retry:
gollek run --retry 3 --model <model> --prompt <prompt>
PROVIDER_005: Provider Rate Limit Exceeded
HTTP Status: 429
Retryable: Yes
Symptoms:
Error: Provider rate limit exceeded
Provider: openai
Limit: 100/min
Solutions:
- Wait and retry:
sleep 60 gollek run --model <model> --prompt <prompt> - Use different provider:
gollek run --provider gemini --model <model> --prompt <prompt> - Enable rate limiting:
gollek config set rate_limit 50 - Upgrade API plan:
Visit provider website to upgrade plan
Configuration Errors
CONFIG_001: Required Configuration Missing
HTTP Status: 500
Retryable: No
Symptoms:
Error: Required configuration missing
Field: api_key
Provider: openai
Solutions:
- Check configuration file:
cat ~/.gollek/config.yaml - Set missing configuration:
gollek config set openai.api_key sk-... - Use environment variable:
export OPENAI_API_KEY=sk-... - Validate configuration:
gollek config validate
CONFIG_002: Invalid Configuration Value
HTTP Status: 500
Retryable: No
Symptoms:
Error: Invalid configuration value
Field: timeout
Value: -1
Expected: positive integer
Solutions:
- Check configuration syntax:
gollek config get <field> - Fix invalid value:
gollek config set <field> <valid-value> - Reset to default:
gollek config reset <field> - Validate all configuration:
gollek config validate
Network Errors
NETWORK_001: Network Timeout
HTTP Status: 504
Retryable: Yes
Symptoms:
Error: Network timeout
Operation: model download
Timeout: 300s
Solutions:
- Check network connectivity:
ping huggingface.co - Increase timeout:
gollek config set network.timeout 600 - Use different mirror:
gollek config set huggingface.mirror https://hf-mirror.com - Check proxy settings:
echo $HTTP_PROXY echo $HTTPS_PROXY
NETWORK_002: Network Unreachable
HTTP Status: 503
Retryable: Yes
Symptoms:
Error: Network unreachable
Host: huggingface.co
Solutions:
- Check internet connection:
ping 8.8.8.8 - Check DNS resolution:
nslookup huggingface.co - Check firewall rules:
sudo ufw status - Use offline mode:
gollek run --offline --model <local-model> --prompt <prompt>
Diagnostic Commands
System Diagnostics
# Check system status
gollek system status
# Check available devices
gollek device list
# Check plugin status
gollek plugin status
# Check model status
gollek model list
# Check configuration
gollek config validate
Plugin Diagnostics
# Check plugin health
gollek plugin health <plugin-id>
# Check plugin configuration
gollek plugin config <plugin-id> --validate
# List plugin capabilities
gollek plugin capabilities <plugin-id>
# Test plugin execution
gollek plugin test <plugin-id>
Model Diagnostics
# Verify model integrity
gollek model verify <model-id>
# Check model compatibility
gollek model check <model-id>
# Get model information
gollek model info <model-id>
# Test model inference
gollek model test <model-id>
Network Diagnostics
# Test network connectivity
gollek network test
# Check provider connectivity
gollek provider test <provider-id>
# Check download speed
gollek network speed-test
# Check DNS resolution
gollek network dns-test
Error Recovery Strategies
Automatic Retry
For retryable errors, Gollek automatically retries with exponential backoff:
retry:
enabled: true
max_attempts: 3
initial_delay: 1s
max_delay: 30s
multiplier: 2.0
Fallback Execution
Configure fallback for non-retryable errors:
fallback:
enabled: true
strategy: cpu # Use CPU if GPU fails
# or
strategy: provider # Use cloud provider if local fails
Circuit Breaker
Enable circuit breaker for repeated failures:
circuit_breaker:
enabled: true
failure_threshold: 5
success_threshold: 3
timeout: 60s
Getting Help
Logs
# View recent logs
gollek logs --recent
# View error logs
gollek logs --level ERROR
# Follow live logs
gollek logs --follow
# Export logs
gollek logs --export > logs.txt
Support Channels
- Documentation: https://gollek.ai/docs
- GitHub Issues: https://github.com/gollek-ai/gollek/issues
- Discord: https://discord.gg/gollek
- Email: support@gollek.ai
Error Reporting
When reporting errors, include:
- Error code and message
- Steps to reproduce
- System information:
gollek system info - Logs:
gollek logs --recent 100 - Configuration (sanitized):
gollek config export --sanitize
Resources
- Error Codes Reference - Complete error code list
- Plugin System v2.0 - Plugin documentation
- Kernel Auto-Detection - Platform detection
- Configuration Guide - Configuration options