清理:移除全部注入型消息(会话上下文/附件系统通知/开始执行指令)

- 会话上下文:删 sessionContextContent/ensureSessionContext/loadHistoryForModel/modelDisplayName 及 bindToSession、runLoopInner、createSession 三处注入;存档/hasUserSince/hasPendingUser 去掉 session_context 特判;SSE 请求历史改用 loadHistory 直取;server.js prompt dump 去掉第 3 部分
- 附件通知:删 routes/messages.js 的 composeWithAttachments/fmtSize 与 POST 路由的 attachments 拼接,正文原样入库、content 必填;前端 send() 不再随 body 传 attachments,无文字时拦截并提示(附件仅上传任务目录);parseUploadNotice 保留兼容旧库行
- 开始执行:删 START_EXECUTION_MESSAGE、engine.startExecution、POST /:id/start 路由与导出(v2 前端本无入口)
- 注释与 README 同步清理
This commit is contained in:
2026-09-10 08:12:56 +08:00
parent 775d92eb67
commit 4051fcdd5c
8 changed files with 22 additions and 148 deletions
+1 -1
View File
@@ -114,7 +114,7 @@ function normalizePlatforms(rawPlatforms) {
models.push({
id: String(m.id),
display_name: m.display_name ? String(m.display_name) : String(m.id), // 缺省 = id
vision: m.vision === true, // 支持时 read_file 读图会回传图片,会话上下文会告知 AI
vision: m.vision === true, // 支持时 read_file 读图会回传图片内容
enable: m.enable !== false, // 选填,默认启用;禁用后不进模型池,不参与分配/绑定(重启生效)
// 选填:模型特有的请求体参数对象。发往上游时整体合并进 body 顶层。
extra_params: (m.extra_params && typeof m.extra_params === 'object' && !Array.isArray(m.extra_params)) ? m.extra_params : {},