# 🔧 Video Keyframe Extraction API 配置文件 [server] # 服务器配置 host = "0.0.0.0" port = 8050 workers = 1 reload = false log_level = "info" [api] # API 基础配置 title = "Video Keyframe Extraction API" description = "视频关键帧提取服务" version = "1.0.0" max_file_size = "100MB" # 最大文件大小 [processing] # 视频处理配置 default_threshold = 0.3 default_output_format = "png" max_frames = 10000 temp_dir = "temp" upload_dir = "uploads" output_dir = "outputs" [rust] # Rust 程序配置 executable_name = "video_keyframe_extractor" executable_path = "target/release" # 相对路径,自动检测 [ffmpeg] # FFmpeg 配置 auto_detect = true custom_path = "" # 留空则自动检测 timeout = 300 # 秒 [performance] # 性能优化配置 async_workers = 4 # 异步文件处理工作线程数 upload_chunk_size = 8192 # 上传块大小 (字节) max_concurrent_uploads = 10 # 最大并发上传数 compression_level = 1 # ZIP 压缩级别 (0-9, 1=快速) stream_chunk_size = 8192 # 流式响应块大小 enable_performance_metrics = true # 启用性能监控 [storage] # 存储配置 cleanup_interval = 3600 # 清理间隔(秒) max_storage_size = "10GB" result_retention_days = 7 [monitoring] # 监控配置 enable_metrics = true enable_logging = true log_file = "logs/api.log" max_log_size = "100MB" [security] # 安全配置 allowed_origins = ["*"] max_concurrent_tasks = 10 rate_limit_per_minute = 60 [development] # 开发环境配置 debug = false auto_reload = false cors_enabled = true