feat: add generated scene skill platform hardening

This commit is contained in:
木炎
2026-04-21 23:19:06 +08:00
parent 118fc77935
commit 956f0c2b68
439 changed files with 61974 additions and 3645 deletions

View File

@@ -9,10 +9,8 @@ use sgclaw::runtime::{RuntimeEngine, RuntimeProfile, ToolPolicy};
use uuid::Uuid;
fn temp_skill_root() -> PathBuf {
let root = std::env::temp_dir().join(format!(
"sgclaw-runtime-profile-skills-{}",
Uuid::new_v4()
));
let root =
std::env::temp_dir().join(format!("sgclaw-runtime-profile-skills-{}", Uuid::new_v4()));
fs::create_dir_all(root.join("skills")).unwrap();
root
}
@@ -141,12 +139,7 @@ fn ws_cleanup_browser_profile_does_not_inject_95598_scene_contract() {
fn browser_attached_unrelated_task_does_not_receive_95598_scene_contract() {
let engine = RuntimeEngine::new(RuntimeProfile::BrowserAttached);
let instruction = engine.build_instruction(
"帮我总结今天的会议纪要",
None,
None,
true,
);
let instruction = engine.build_instruction("帮我总结今天的会议纪要", None, None, true);
assert!(!instruction.contains("collect_repair_orders"));
assert!(!instruction.contains("browser workflow, not a text-only task"));