{
    "models": [
        {
            "name": "ocr-det",
            "primary": "ACCEL",
            "fallback": [],
            "exclusive": true,
            "queue_capacity": 16,
            "worker_kind": "ort_ep",
            "model_path": "/root/models/spacemit-ai/vision/ppocr/PP-OCRv5_mobile_det.onnx",
            "preferred_threads": 4,
            "resource_key": "ACCEL-BATCH",
            "resource_domain": "ACCEL.aux",
            "resource_lease_type": "counting",
            "resource_lease_amount": 1,
            "dram_gb": 0.3,
            "service_class": "background_index",
            "priority": 55,
            "estimated_runtime_ms": 5000,
            "deadline_ms": 0,
            "ocr_pipeline": {
                "mode": "detect",
                "max_side": 960,
                "max_lines": 256
            },
            "providers": [
                "spacemit"
            ],
            "backend_profile": {
                "ocr_ingest": {
                    "schema_version": "ocr_ingest_contract.v1",
                    "recommended_timeout_ms": 90000,
                    "recommended_poll_timeout_ms": 180000,
                    "recommended_document_timeout_ms": 180000,
                    "adaptive_render_dpi": [
                        200,
                        160,
                        120
                    ],
                    "degradation_policy": "poll_scheduler_job_to_terminal_before_metadata_only"
                }
            },
            "latency_ms": {
                "ACCEL": 1000
            }
        },
        {
            "name": "ocr-rec",
            "primary": "ACCEL",
            "fallback": [],
            "exclusive": true,
            "replicas": 1,
            "queue_capacity": 16,
            "worker_kind": "ort_ep",
            "model_path": "/root/models/spacemit-ai/vision/ppocr/PP-OCRv5_mobile_rec.onnx",
            "preferred_threads": 4,
            "resource_key": "ACCEL-BATCH",
            "resource_domain": "ACCEL.aux",
            "resource_lease_type": "counting",
            "resource_lease_amount": 1,
            "dram_gb": 0.6,
            "service_class": "background_index",
            "priority": 55,
            "estimated_runtime_ms": 15000,
            "deadline_ms": 0,
            "ocr_pipeline": {
                "mode": "recognize",
                "det_model_path": "/root/models/spacemit-ai/vision/ppocr/PP-OCRv5_mobile_det.onnx",
                "dictionary_path": "/root/models/spacemit-ai/vision/ppocr/ppocrv5_dict.txt",
                "max_side": 960,
                "max_lines": 256
            },
            "providers": [
                "spacemit"
            ],
            "backend_profile": {
                "ocr_ingest": {
                    "schema_version": "ocr_ingest_contract.v1",
                    "recommended_timeout_ms": 120000,
                    "recommended_poll_timeout_ms": 180000,
                    "recommended_document_timeout_ms": 180000,
                    "adaptive_render_dpi": [
                        200,
                        100,
                        80
                    ],
                    "degradation_policy": "poll_scheduler_job_to_terminal_before_metadata_only"
                }
            },
            "latency_ms": {
                "ACCEL": 5000
            }
        },
        {
            "name": "asr-whisper",
            "primary": "CPU",
            "fallback": [],
            "exclusive": true,
            "queue_capacity": 24,
            "worker_kind": "openai_http",
            "model_path": "sherpa-onnx-streaming-zipformer",
            "preferred_threads": 4,
            "dram_gb": 0.4,
            "service_class": "realtime_cpu",
            "priority": 88,
            "estimated_runtime_ms": 500,
            "deadline_ms": 10000,
            "async_required_above_ms": 10000,
            "openai_base_url": "http://127.0.0.1:18190",
            "openai_endpoint": "/v1/audio/transcriptions",
            "openai_health_path": "/health",
            "openai_model": "sherpa-onnx-streaming-zipformer",
            "backend_profile": {
                "adapter": "openai_http",
                "runtime": "rv-sherpa-onnx-runtime",
                "model_family": "sherpa-onnx-streaming-zipformer-bilingual-zh-en",
                "stage": "native_audio_transcription",
                "api": "/v1/audio/transcriptions",
                "artifact_source": "image_preinstalled",
                "model_dir": "/opt/rv-sherpa-onnx/models/candidates/current/asr-streaming-zipformer",
                "legacy_frontend_probe": "/root/models/spacemit-ai/vlm/qwen3-asr-0.6B/Qwen3-ASR-0.6B-encoder-frontend.dynq.onnx",
                "accepts": [
                    "audio_base64",
                    "chunk_mel"
                ]
            },
            "latency_ms": {
                "CPU": 500
            }
        },
        {
            "name": "tts-default",
            "primary": "CPU",
            "fallback": [],
            "exclusive": true,
            "queue_capacity": 4,
            "worker_kind": "openai_http",
            "model_path": "sherpa-onnx-matcha-tts",
            "preferred_threads": 2,
            "dram_gb": 0.5,
            "service_class": "realtime_cpu",
            "priority": 88,
            "estimated_runtime_ms": 800,
            "cold_start_eta_ms": 7000,
            "deadline_ms": 120000,
            "sync_allowed": false,
            "openai_base_url": "http://127.0.0.1:18190",
            "openai_endpoint": "/v1/audio/speech",
            "openai_health_path": "/health",
            "openai_model": "sherpa-onnx-matcha-tts",
            "backend_profile": {
                "adapter": "openai_http",
                "runtime": "rv-sherpa-onnx-runtime",
                "model_family": "sherpa-onnx-matcha-tts",
                "artifact_source": "image_preinstalled",
                "api": "/v1/audio/speech",
                "required_model_dir": "/opt/rv-sherpa-onnx/models/candidates/current/tts-matcha",
                "legacy_contract_model": "/root/models/spacemit-ai/tts/synthetic-token-ids-v1.onnx",
                "not_ready_code": "native_tts_model_unavailable",
                "quality_scope": "native product TTS PCM16 WAV generation"
            },
            "latency_ms": {
                "CPU": 800
            }
        },
        {
            "name": "embedding-int8",
            "primary": "ACCEL",
            "fallback": [],
            "exclusive": false,
            "replicas": 4,
            "resource_domain": "ACCEL.retrieval",
            "resource_lease_type": "counting",
            "resource_lease_amount": 1,
            "resource_key": "ACCEL-RETRIEVAL",
            "queue_capacity": 32,
            "worker_kind": "llama_http",
            "model_path": "/root/models/spacemit-ai/embed/Bge-Small-Zh-V1.5-Q4_K_M.gguf",
            "preferred_threads": 8,
            "dram_gb": 0.7,
            "context": 2048,
            "service_class": "realtime_retrieval",
            "priority": 94,
            "estimated_runtime_ms": 25,
            "cold_start_eta_ms": 8000,
            "deadline_ms": 2000,
            "llama_bin": "/usr/bin/llama-server",
            "llama_endpoint": "/v1/embeddings",
            "use_ime2": true,
            "llama_server_args": [
                "--embedding",
                "--pooling",
                "mean"
            ],
            "backend_profile": {
                "runtime": "llama.cpp-tools-spacemit",
                "runtime_binary": "/usr/bin/llama-server",
                "artifact_source": "spacemit_model_zoo",
                "api": "/v1/embeddings",
                "accelerator_path": "ime2",
                "pooling": "mean",
                "embedding_dim": 1024,
                "quantization": "Q4_K_M"
            },
            "latency_ms": {
                "ACCEL": 25
            }
        },
        {
            "name": "reranker-int8",
            "primary": "ACCEL",
            "fallback": [],
            "exclusive": false,
            "resource_domain": "ACCEL.aux",
            "resource_lease_type": "counting",
            "resource_lease_amount": 1,
            "resource_key": "ACCEL-BATCH",
            "queue_capacity": 16,
            "worker_kind": "llama_http",
            "model_path": "/root/models/spacemit-ai/rerank/Bge-Reranker-V2-M3-Q4_0.gguf",
            "preferred_threads": 8,
            "dram_gb": 0.8,
            "context": 2048,
            "service_class": "realtime_retrieval",
            "priority": 94,
            "estimated_runtime_ms": 145,
            "cold_start_eta_ms": 8000,
            "deadline_ms": 2000,
            "llama_bin": "/usr/bin/llama-server",
            "llama_endpoint": "/v1/rerank",
            "use_ime2": true,
            "llama_server_args": [
                "--reranking",
                "--pooling",
                "rank"
            ],
            "backend_profile": {
                "runtime": "llama.cpp-tools-spacemit",
                "runtime_binary": "/usr/bin/llama-server",
                "artifact_source": "spacemit_model_zoo",
                "api": "/v1/rerank",
                "accelerator_path": "ime2",
                "pooling": "rank",
                "embedding_dim": 1024,
                "quantization": "Q4_0"
            },
            "latency_ms": {
                "ACCEL": 145
            }
        },
        {
            "name": "llm-summary",
            "primary": "ACCEL",
            "fallback": [],
            "exclusive": true,
            "queue_capacity": 8,
            "worker_kind": "llama_http",
            "resource_domain": "ACCEL.aux.session",
            "resource_lease_type": "exclusive_session",
            "resource_lease_amount": 1,
            "model_path": "/root/models/spacemit-ai/llm/Qwen3-30B-A3B-Q4_0.gguf",
            "preferred_threads": 8,
            "dram_gb": 18.0,
            "context": 4096,
            "service_class": "realtime_answer",
            "priority": 96,
            "estimated_runtime_ms": 15000,
            "cold_start_eta_ms": 70000,
            "deadline_ms": 20000,
            "max_context_tokens_sync": 4096,
            "max_context_tokens_async": 8192,
            "max_output_tokens_sync": 256,
            "max_output_tokens_async": 1024,
            "kv_cache_per_1k_tokens_gb": 0.75,
            "llama_bin": "/usr/bin/llama-server",
            "use_ime2": true,
            "prompt_prefix": "/no_think\n",
            "chat_template_kwargs": {
                "enable_thinking": false
            },
            "backend_profile": {
                "runtime": "llama.cpp-tools-spacemit",
                "runtime_binary": "/usr/bin/llama-server",
                "artifact_source": "spacemit_model_zoo",
                "accelerator_path": "ime2",
                "requires_no_think": true,
                "api": "/v1/chat/completions",
                "role": "document_summary_and_long_context_organization",
                "model_family": "Qwen3-30B-A3B",
                "quantization": "Q4_0"
            },
            "latency_ms": {
                "ACCEL": 15000
            }
        },
        {
            "name": "llm-chat",
            "primary": "ACCEL",
            "fallback": [],
            "exclusive": true,
            "queue_capacity": 8,
            "worker_kind": "llama_http",
            "resource_domain": "ACCEL.chat",
            "resource_lease_type": "exclusive_session",
            "resource_lease_amount": 1,
            "model_path": "/root/models/spacemit-ai/llm/MiniCPM5-1B/MiniCPM5-1B-Q4_K_M.gguf",
            "preferred_threads": 8,
            "dram_gb": 1.2,
            "context": 4096,
            "service_class": "realtime_answer",
            "priority": 96,
            "estimated_runtime_ms": 3200,
            "cold_start_eta_ms": 15000,
            "deadline_ms": 12000,
            "max_context_tokens_sync": 4096,
            "max_context_tokens_async": 8192,
            "max_output_tokens_sync": 256,
            "max_output_tokens_async": 1024,
            "kv_cache_per_1k_tokens_gb": 0.08,
            "llama_bin": "/usr/bin/llama-server",
            "use_ime2": true,
            "prompt_prefix": "/no_think\n",
            "chat_template_kwargs": {
                "enable_thinking": false
            },
            "backend_profile": {
                "runtime": "llama.cpp-tools-spacemit",
                "runtime_binary": "/usr/bin/llama-server",
                "artifact_source": "vlm-llm-benchmark:minicpm-probe",
                "model_family": "MiniCPM5-1B",
                "role": "rag_answer_candidate",
                "accelerator_path": "ime2",
                "requires_no_think": true,
                "chat_template_kwargs": {
                    "enable_thinking": false
                },
                "api": "/v1/chat/completions",
                "quantization": "Q4_K_M",
                "recommended_stop": [
                    "\n\n",
                    "请注意",
                    "注：",
                    "停止。",
                    "以上。"
                ],
                "bench_evidence": "docs/minicpm-k3-rag-replacement.zh.md"
            },
            "latency_ms": {
                "ACCEL": 3200
            },
            "llama_server_args": [
                "--no-mmap",
                "--no-warmup",
                "-fa",
                "1"
            ]
        },
        {
            "name": "vlm",
            "primary": "ACCEL",
            "fallback": [],
            "exclusive": true,
            "queue_capacity": 4,
            "worker_kind": "llama_http",
            "resource_domain": "ACCEL.aux.session",
            "resource_lease_type": "exclusive_session",
            "resource_lease_amount": 1,
            "model_path": "/root/models/spacemit-ai/vlm/Qwen3.5-2B/qwen3_5_2b-text-q41.gguf",
            "preferred_threads": 6,
            "dram_gb": 5.5,
            "context": 2048,
            "service_class": "realtime_vlm_compact",
            "priority": 65,
            "estimated_runtime_ms": 11000,
            "cold_start_eta_ms": 25000,
            "deadline_ms": 20000,
            "sync_allowed": true,
            "max_context_tokens_sync": 2048,
            "max_context_tokens_async": 4096,
            "max_output_tokens_sync": 256,
            "max_output_tokens_async": 1024,
            "kv_cache_per_1k_tokens_gb": 0.125,
            "llama_bin": "/usr/bin/llama-server",
            "use_ime2": true,
            "prompt_prefix": "/no_think\n",
            "chat_template_kwargs": {
                "enable_thinking": false
            },
            "llama_env": {
                "SPACEMIT_EP_DENSE_ACCURACY_LEVEL": "1"
            },
            "llama_server_args": [
                "--media-backend",
                "smt",
                "--smt-config-dir",
                "/root/models/spacemit-ai/vlm/Qwen3.5-2B"
            ],
            "quality_profile": {
                "benchmark": "vlm_document_extraction",
                "model_family": "Qwen3.5-2B SMT",
                "field_accuracy": 1.0,
                "strict_json_rate": 0.967
            },
            "backend_profile": {
                "runtime": "llama.cpp-tools-spacemit",
                "runtime_binary": "/usr/bin/llama-server",
                "artifact_source": "spacemit_model_zoo",
                "media_backend": "smt",
                "smt_config_dir": "/root/models/spacemit-ai/vlm/Qwen3.5-2B",
                "accelerator_path": "ime2+smt",
                "requires_no_think": true,
                "api": "/v1/chat/completions",
                "model_family": "Qwen3.5-2B SMT",
                "quantization": "Q4_1"
            },
            "latency_ms": {
                "ACCEL": 1800
            }
        }
    ]
}
