feat(AI): MNN 模型纳入下载体系 ModelKind.mnnLLM(Phase 4)
文本 MNN 模型用 taobao-mnn/Qwen3.5-2B-MNN 官方预转换格式(~1.10GiB), 不再从头转换(避开多模态转文本风险,官方转更可靠)。 - ModelStore.ModelKind 新增 .mnnLLM = "Qwen3.5-2B-MNN" - ModelManifest:.mnnLLM 文件清单(config.json/llm_config.json/llm.mnn/ llm.mnn.weight 1.1GB/tokenizer.txt/visual.mnn,HF API 实测字节) - AIRuntime:mnnModelFolder + 就绪判定改走 ModelStore.isComplete(.mnnLLM) - ModelManagementView:subtitle 加 .mnnLLM 文案(仅此一处,未动其它 WIP) - ModelManifestTests:+4 条 mnnLLM 断言(文件数/总字节/必需文件/URL) 模拟器 ModelManifestTests TEST SUCCEEDED。下载经现有链路,需上传到 file.myv0.com/Qwen3.5-2B-MNN/(CDN 清单随附)。 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -59,6 +59,19 @@ nonisolated enum ModelManifest {
|
||||
ModelFile(path: "preprocessor_config.json", bytes: 782),
|
||||
ModelFile(path: "video_preprocessor_config.json", bytes: 817),
|
||||
]
|
||||
case .mnnLLM:
|
||||
// taobao-mnn/Qwen3.5-2B-MNN 预转换 MNN 格式(HF API 实测,2026-06)。
|
||||
// 运行时必需:config.json(MNN llm 配置)+ llm_config.json(超参)+ llm.mnn(图)
|
||||
// + llm.mnn.weight(量化权重 ~1.1GB)+ tokenizer.txt + visual.mnn(多模态,文本路径不用但配置含 mllm)。
|
||||
// 排除 README/.gitattributes 与可读 dump(llm.mnn.json / export_args.json)。
|
||||
return [
|
||||
ModelFile(path: "config.json", bytes: 652),
|
||||
ModelFile(path: "llm_config.json", bytes: 8_692),
|
||||
ModelFile(path: "llm.mnn", bytes: 2_148_136),
|
||||
ModelFile(path: "llm.mnn.weight", bytes: 1_176_647_702),
|
||||
ModelFile(path: "tokenizer.txt", bytes: 6_465_727),
|
||||
ModelFile(path: "visual.mnn", bytes: 488_096),
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user