feat(canvas): 生成合同 - 统一节点参数并补充模型上下文能力
This commit is contained in:
1 parent
a59b77cf70
commit
3bf21d79af
18 files changed
+965
-40
No files matched your search
@@ -352,6 +352,12 @@ func (s *Service) processCanvasGenerationTask(ctx context.Context, userID string
|
||||
return nil, err
|
||||
}
|
||||
input.Config = config
|
||||
if input.Mode == "text" && input.Config.CapabilityConfig != nil && input.Config.CapabilityConfig.Text != nil {
|
||||
// The same capability contract drives provider output limits, billing
|
||||
// estimates and Agent context budgeting. Never silently fall back to a
|
||||
// transport-specific fixed token count when the model declares one.
|
||||
input.MaxOutputTokens = input.Config.CapabilityConfig.Text.MaxOutputTokens
|
||||
}
|
||||
var textPublisher *taskTextStreamPublisher
|
||||
if input.Mode == "text" && strings.HasPrefix(taskType, "canvas_text") {
|
||||
requestedStream := input.TextOptions.Stream == nil || *input.TextOptions.Stream
|
||||
|
||||
Reference in new issue
Block a user