Release v1.0.127: document executionProfile stream for HTML token streaming
All checks were successful
技能自动化发布 / release (push) Successful in 6s

This commit is contained in:
2026-10-25 18:22:25 +08:00
parent 8a8fa3cb0c
commit d911bd28cd
14 changed files with 141 additions and 63 deletions

View File

@@ -1382,12 +1382,12 @@ class TestPolicySkillAction001(unittest.TestCase):
"action.properties.executionProfile missing",
),
)
self.assertEqual(set(profile.get("enum") or []), {"sync", "async"})
self.assertEqual(set(profile.get("enum") or []), {"sync", "async", "stream"})
def test_actions_md_documents_execution_profile(self) -> None:
path = os.path.join(get_skill_root(), "references", "ACTIONS.md")
text = _read_text(path)
for marker in ("executionProfile", "async", "任务中心", "SKILL_ACTION_RUNTIME"):
for marker in ("executionProfile", "async", "stream", "任务中心", "SKILL_ACTION_RUNTIME"):
self.assertIn(
marker,
text,
@@ -1407,7 +1407,7 @@ class TestPolicySkillAction001(unittest.TestCase):
for action in manifest.get("actions") or []:
action_id = action.get("id", "?")
profile = action.get("executionProfile")
if profile not in ("sync", "async"):
if profile not in ("sync", "async", "stream"):
offenders.append(f"{action_id}: executionProfile={profile!r}")
self.assertEqual(
offenders,
@@ -1415,7 +1415,8 @@ class TestPolicySkillAction001(unittest.TestCase):
msg=_policy_msg(
"POLICY-SKILL-ACTION-001",
"assets/actions.json",
"every action must set executionProfile to sync|async:\n" + "\n".join(offenders),
"every action must set executionProfile to sync|async|stream:\n"
+ "\n".join(offenders),
),
)
@@ -1469,7 +1470,10 @@ class TestPolicySkillAction002(unittest.TestCase):
"executionProfile must be in action.required",
),
)
self.assertEqual(set(action["properties"]["executionProfile"].get("enum") or []), {"sync", "async"})
self.assertEqual(
set(action["properties"]["executionProfile"].get("enum") or []),
{"sync", "async", "stream"},
)
def test_manifest_actions_declare_execution_profile(self) -> None:
manifest = _load_actions_json(get_skill_root())
@@ -1478,7 +1482,7 @@ class TestPolicySkillAction002(unittest.TestCase):
offenders: list[str] = []
for action in manifest.get("actions") or []:
profile = action.get("executionProfile")
if profile not in ("sync", "async"):
if profile not in ("sync", "async", "stream"):
offenders.append(f"{action.get('id', '?')}: {profile!r}")
self.assertEqual(
offenders,
@@ -1486,7 +1490,8 @@ class TestPolicySkillAction002(unittest.TestCase):
msg=_policy_msg(
"POLICY-SKILL-ACTION-002",
"assets/actions.json",
"every action must set executionProfile to sync|async:\n" + "\n".join(offenders),
"every action must set executionProfile to sync|async|stream:\n"
+ "\n".join(offenders),
),
)
@@ -1588,7 +1593,7 @@ class TestPolicySkillAction004(unittest.TestCase):
def test_runtime_doc_states_orthogonality(self) -> None:
text = _read_text(os.path.join(get_skill_root(), "development", "SKILL_ACTION_RUNTIME.md"))
for marker in ("正交", "sync|async", "toolbar"):
for marker in ("正交", "sync|async|stream", "toolbar"):
self.assertIn(
marker,
text,