feat: 挑战的题目要求发给 AI 当对照清单,学生没提到的不替他做,在“想一想”里问
Deploy / deploy (build, debian, 22) (push) Canceled after 0s
Deploy / deploy (build, debian, 22) (push) Canceled after 0s
学生不用再整段贴题目;AI 只做学生说了的,从没提到的要求里挑一项问他打算怎么做。 整段贴了题目的照做。自由创作的题目是学生自己写的,不发。输入框提示改成“用你自己的话说说”。 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
43c18cdb88
commit
5bdacc438d
6 files changed
+55
-9
No files matched your search
+3
-1
@@ -3,6 +3,7 @@ import { all, get, run, iso, uuidOut } from "./db"
|
||||
import { userFromAccessToken, type User } from "./auth"
|
||||
import {
|
||||
canAccessTask,
|
||||
challengeBrief,
|
||||
codeAsMarkdown,
|
||||
getOrCreateActiveConversation,
|
||||
guidanceContext,
|
||||
@@ -132,7 +133,8 @@ async function handlePrompt(ws: WS, data: any) {
|
||||
}))
|
||||
let full: string
|
||||
try {
|
||||
full = await streamToClient(ws, streamChat(history, model, ws.data.abort.signal))
|
||||
const brief = challengeBrief(ws.data.taskId)
|
||||
full = await streamToClient(ws, streamChat(history, model, ws.data.abort.signal, brief))
|
||||
} catch (e) {
|
||||
// 客户端自己断开导致的中止不算出错
|
||||
if (!ws.data.closed) send(ws, { type: "error", content: userFacingError(e) })
|
||||
|
||||
Reference in new issue
Block a user