refactor(agent): gate sustained goals behind explicit /goal

Replace the legacy long-goal skill contract with command-scoped goal tools and runtime guidance. Keep goal state durable across continuations while restricting create and replace mutations to explicit user /goal turns.
This commit is contained in:
chengyongru
2026-07-12 00:35:17 +08:00
committed by Xubin Ren
parent edf78e7054
commit 7f8c3453e1
24 changed files with 1131 additions and 375 deletions
+3 -3
View File
@@ -254,10 +254,10 @@ class TestSpawn:
return AgentRunResult(final_content="done", messages=[], stop_reason="completed")
sm.runner.run = _slow_run
long_task = "A" * 50
await sm.spawn(long_task, runtime=_runtime(), session_key="s1")
long_label_source = "A" * 50
await sm.spawn(long_label_source, runtime=_runtime(), session_key="s1")
status = next(iter(sm._task_statuses.values()))
assert status.label == long_task[:30] + "..."
assert status.label == long_label_source[:30] + "..."
block.set()
await _drain_subagent_tasks(sm)