Files
Genarrative/apps/ai-game-creator-shell/src-tauri/src/agent/runtime_protocol.rs
T
k88936 6106b4e67c 退役AGC项目对话斜杠命令与终端swarm chat入口:应用与Rust实现删除
- 删除应用侧 /history 精确匹配分支与 reloadHistory、chatPromptPolish 的 / 前缀绕过、chatCommandMetadata、memoryCommands、projectSummaryConstants 命令清单
- 删除只服务退役摘要面板的 project-summary/*Summaries.ts 与 agentTrace.ts 及对应测试
- 删除 /sync-canvas-project、/read、/trace 草稿回填死链(agentPresentation.ts 与 Rust suggested_canvas_tool_call)
- 删除无人调用的 Tauri 命令 get_game_creation_agent_capabilities 与 get_limited_local_commands
- 删除 --swarm-chat 入口、SwarmChat 变体、src/swarm_cli.rs 与整个 swarm_cli/ 目录
- 收敛 agent/interaction.rs 至自然语言 steer 决策路径,删除交互内核整层
- 删除 SWARM_TURN_*_ERROR、print_runtime_response_stream_status 及其专属测试
- 更新 ChatMarkdownMessage、chatPromptPolish、rememberCommand 与 appSurface 用例,移除斜杠命令断言
2026-09-23 11:12:39 +08:00

124 lines
5.4 KiB
Rust

use super::*;
mod autonomous_completion;
mod context_bundle;
mod context_window;
mod design_session;
mod finalization;
mod json_sidecar;
mod models;
mod provider_control;
mod provider_retry;
mod real_e2e_checkpoint;
mod response_stream;
mod run_configuration;
mod steering;
mod verification;
pub(in crate::agent) use autonomous_completion::*;
pub(in crate::agent) use context_bundle::*;
pub(crate) use design_session::*;
pub(in crate::agent) use finalization::*;
pub(in crate::agent) use json_sidecar::*;
pub(in crate::agent) use models::*;
pub(in crate::agent) use provider_control::*;
pub(in crate::agent) use provider_retry::*;
pub(in crate::agent) use real_e2e_checkpoint::*;
pub(in crate::agent) use response_stream::*;
pub(in crate::agent) use run_configuration::*;
pub(in crate::agent) use steering::*;
pub(in crate::agent) use verification::*;
pub(crate) use autonomous_completion::autonomous_game_build_root_run_active_at;
pub(crate) use context_bundle::{
build_game_creator_agent_runtime_context_bundle,
continuation_from_game_creator_agent_runtime_context_bundle,
game_creator_agent_runtime_context_bundle_path, game_creator_agent_runtime_context_project_id,
persist_game_creator_agent_runtime_context, read_game_creator_agent_runtime_context_bundle,
read_game_creator_agent_runtime_context_bundle_for_idle_compaction,
write_game_creator_agent_runtime_context_bundle,
};
pub(crate) use context_window::{
agent_runtime_context_window_applies, sanitize_agent_runtime_context_observation,
AgentRuntimeContextCheckpoint,
};
#[allow(unused_imports)]
pub(crate) use finalization::{
game_creator_agent_runtime_finalization_message_id,
game_creator_agent_runtime_finalization_path,
read_game_creator_agent_runtime_finalization_journal,
remove_game_creator_agent_runtime_finalization_journal,
};
pub(crate) use json_sidecar::{
agent_runtime_json_sidecar_backup_path, read_agent_runtime_json_sidecar_with_max_bytes,
remove_agent_runtime_json_sidecar_backup, write_agent_runtime_json_sidecar_with_max_bytes,
};
pub(crate) use models::{
AgentBackgroundFinalizationOutcome, AgentBackgroundTaskOutcome, AgentRuntimeContextBundle,
AgentRuntimeContextWindowTracker, AgentRuntimeContinuationContext,
AgentRuntimeFinalizationCheckpoint, AgentRuntimeFinalizationJournal, AgentRuntimePlanUpdate,
AgentRuntimePlanUpdateStep, AgentRuntimeProjectRevision,
AgentRuntimeProviderActionBatchPreparation, AgentRuntimeProviderRequestSnapshot,
AgentRuntimeToolAction, AgentRuntimeToolObservation, AgentRuntimeToolPlan,
AgentRuntimeVerificationGate, ParsedAgentRuntimeToolPlan,
AGENT_RUNTIME_LOCK_STALE_AFTER_SECONDS,
};
#[cfg(test)]
pub(crate) use provider_control::mark_game_creator_agent_runtime_provider_success_handoff_needs_reconciliation_for_test;
pub(crate) use provider_retry::{
game_creator_agent_runtime_provider_request_id,
game_creator_agent_runtime_transient_retry_backoff_ms,
};
pub(crate) use real_e2e_checkpoint::AgentRuntimeRealE2eAckPublishPhase;
pub(crate) use response_stream::{
game_creator_agent_runtime_response_stream_path,
read_game_creator_agent_runtime_response_stream_at,
};
pub(crate) use run_configuration::{
agent_runtime_run_profile_identity_at, bind_game_creator_agent_runtime_run_profile_at,
game_creator_agent_runtime_project_revision_path,
game_creator_agent_runtime_provider_transient_retry_policy_at,
game_creator_agent_runtime_run_profile_binding_path,
read_game_creator_agent_runtime_run_profile_binding,
};
pub(crate) use steering::{
acquire_game_creator_agent_runtime_steer_project_write_lock_with_wait,
append_game_creator_agent_runtime_steer_decision_failure_reply_at,
consume_game_creator_agent_runtime_steers,
game_creator_agent_runtime_provider_request_count_for_roots,
game_creator_agent_runtime_steer_ledger_path,
interrupt_game_creator_agent_runtime_provider_for_decided_steer_at,
interrupt_game_creator_agent_runtime_provider_request_at,
interrupt_game_creator_agent_runtime_provider_requests_for_roots,
persist_game_creator_agent_runtime_steer_decision_and_reply_at,
read_game_creator_agent_runtime_steer_decision_at,
register_game_creator_agent_runtime_provider_request,
render_game_creator_agent_runtime_steers_for_prompt, steer_game_creator_agent_runtime_task_at,
steer_game_creator_agent_runtime_task_for_profile_at,
unregister_game_creator_agent_runtime_provider_request,
validate_game_creator_agent_runtime_steer_notification_at, AgentRuntimeSteerDecision,
};
pub(crate) use verification::{
game_creator_agent_runtime_verification_gate_path,
read_game_creator_agent_runtime_project_revision,
read_game_creator_agent_runtime_verification_gate,
write_game_creator_agent_runtime_project_revision,
write_game_creator_agent_runtime_verification_gate,
};
#[cfg(test)]
pub(crate) use provider_control::{
await_game_creator_agent_runtime_provider_request,
capture_game_creator_agent_runtime_provider_request_snapshot,
};
#[cfg(test)]
pub(crate) use provider_retry::append_game_creator_agent_runtime_provider_lifecycle_for_test;
#[cfg(test)]
pub(crate) use real_e2e_checkpoint::{
await_game_creator_agent_runtime_provider_request_with_control_hook_for_test,
await_game_creator_agent_runtime_provider_request_with_snapshot_for_test,
await_game_creator_agent_runtime_tool_plan_checkpoint_for_test,
publish_game_creator_agent_runtime_tool_plan_checkpoint_ack_for_test,
};