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
+8
View File
@@ -126,6 +126,14 @@ async def test_skill_command_no_render_as_text(tmp_path: Path) -> None:
assert out.metadata.get("render_as") != "text"
@pytest.mark.asyncio
async def test_skill_command_does_not_list_goal_runtime_protocol(tmp_path: Path) -> None:
loop = _make_loop(tmp_path)
out = await cmd_skill(_ctx(loop))
assert "long-goal" not in out.content
@pytest.mark.asyncio
async def test_skill_command_registered_on_router(tmp_path: Path) -> None:
router = CommandRouter()