This commit is contained in:
2026-05-13 12:36:48 +08:00
parent 21255a701d
commit 066294e74f
11 changed files with 194 additions and 80 deletions

View File

@ -28,18 +28,18 @@ const config = {
kernel.init(config);
const response = await fetch('http://localhost:3001/api/models/auto-load/list')
const data = await response.json()
const models = data.data // 这就是模型列表
console.log(models);
models.forEach(model => {
const response = await fetch('http://localhost:3001/api/models/auto-load/list')
const data = await response.json()
const models = data.data // 这就是模型列表
console.log(models);
models.forEach(model => {
kernel.model.add({
modelId: model.id,
modelUrl: model.file_url || `http://localhost:3001${model.file_path}`,
modelControlType: model.model_control_type,
modelId: model.id,
modelUrl: model.file_url || `http://localhost:3001${model.file_path}`,
modelControlType: model.model_control_type,
});
})
})
// kernel.model.add({
// modelId: "框架",