Feat/design agent simple #305
+15
-13
@@ -1467,19 +1467,21 @@ pub(crate) fn decide_planning_artifact_v2_at(
|
||||
};
|
||||
approval.receipt_fingerprint = approval_fingerprint(&approval)?;
|
||||
write_approval_v2(root, &approval)?;
|
||||
append_planning_message_v2(
|
||||
root,
|
||||
&PlanningMessageV2 {
|
||||
schema_version: PLANNING_MESSAGE_V2_SCHEMA_VERSION.to_string(),
|
||||
message_id: format!("msg-{}", Uuid::new_v4().simple()),
|
||||
client_turn_id: input.decision_id.clone(),
|
||||
turn_index: session.turn_index,
|
||||
at_utc: approval.decided_at_utc.clone(),
|
||||
role: "user".to_string(),
|
||||
kind: "text".to_string(),
|
||||
payload: serde_json::json!({"text": format!("审批:{} {}", input.action, comment.as_deref().unwrap_or_default()), "approvalAction": input.action, "artifactId": gdd.gdd_id, "version": gdd.version}),
|
||||
},
|
||||
)?;
|
||||
if input.action != "revise" {
|
||||
append_planning_message_v2(
|
||||
root,
|
||||
&PlanningMessageV2 {
|
||||
schema_version: PLANNING_MESSAGE_V2_SCHEMA_VERSION.to_string(),
|
||||
message_id: format!("msg-{}", Uuid::new_v4().simple()),
|
||||
client_turn_id: input.decision_id.clone(),
|
||||
turn_index: session.turn_index,
|
||||
at_utc: approval.decided_at_utc.clone(),
|
||||
role: "user".to_string(),
|
||||
kind: "text".to_string(),
|
||||
payload: serde_json::json!({"text": format!("审批:{} {}", input.action, comment.as_deref().unwrap_or_default()), "approvalAction": input.action, "artifactId": gdd.gdd_id, "version": gdd.version}),
|
||||
},
|
||||
)?;
|
||||
}
|
||||
update_index_v2(
|
||||
root,
|
||||
&gdd,
|
||||
|
||||
+1
-1
@@ -810,7 +810,7 @@ fn build_provider_request_v2(
|
||||
let request = platform_llm::LlmRunRequest::new(messages)
|
||||
.with_api_kind(api_kind)
|
||||
.with_model(llm.model.clone())
|
||||
.with_max_output_tokens(4_096)
|
||||
.with_max_output_tokens(16_384)
|
||||
.with_request_timeout_ms(llm.request_timeout_ms)
|
||||
.with_function_tools(planning_v2_function_tools())
|
||||
.with_tool_choice(platform_llm::LlmToolChoice::Auto);
|
||||
|
||||
@@ -831,6 +831,13 @@ export function App({
|
||||
replayed: approval.replayed,
|
||||
});
|
||||
setPlanGddError(null);
|
||||
if (action === 'revise' && comment?.trim()) {
|
||||
await executePlanningV2Turn(
|
||||
targetProjectPath,
|
||||
`审批:revise ${comment.trim()}`,
|
||||
`planning-v2-revision-${crypto.randomUUID()}`,
|
||||
);
|
||||
}
|
||||
return;
|
||||
}
|
||||
await invokeDiagnostic(invoke, 'decide_game_creator_plan_gdd', {
|
||||
|
||||
Reference in New Issue
Block a user