mirror of
https://github.com/NanmiCoder/cc-haha
synced 2026-07-29 16:03:34 +08:00
标题生成未正确调用模型接口
标题生成未正确调用模型接口
This commit is contained in:
parent
4b724ed2c9
commit
f0b8236258
@ -1047,9 +1047,11 @@ function bindTitleSessionOutput(
|
|||||||
if (cliMsg?.type === 'result') {
|
if (cliMsg?.type === 'result') {
|
||||||
conversationService.removeOutputCallback(sessionId, callback)
|
conversationService.removeOutputCallback(sessionId, callback)
|
||||||
const completedTurnCount = completeActiveTitleTurn(sessionId)
|
const completedTurnCount = completeActiveTitleTurn(sessionId)
|
||||||
if (!cliMsg.is_error) {
|
// Always attempt AI title generation — even on error turns the user
|
||||||
triggerTitleGeneration(ws, sessionId, 'turn-complete', completedTurnCount ?? undefined)
|
// message (and partial assistant output) contain enough context for a
|
||||||
}
|
// good title. generateTitle is fire-and-forget and returns null on
|
||||||
|
// any failure, so this is safe.
|
||||||
|
triggerTitleGeneration(ws, sessionId, 'turn-complete', completedTurnCount ?? undefined)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user