release: bump version to 0.84.0
ci / backend (push) Canceled after 0s
ci / frontend (push) Canceled after 0s
ci / delivery (push) Canceled after 0s

This commit is contained in:
linkong committed 2026-12-04 07:07:19 +08:00
1 parent 3b1b9ef68c
commit e1cc27f13d
241 files changed
+42779 -6027

No files matched your search

+48 -8
View File
@@ -197,13 +197,13 @@ async def test_ai_workflow_optimize_whitelist_and_playground_sse_runs(monkeypatc
"summary": "Add fetch tool & block bad tool",
"node_patches": [
{
"node_id": "l2_agent_research",
"node_id": "l2_judge_r1",
"field": "tools",
"after": ["fetch_source_url", "evil_rm_rf_tool"],
"reason": "Keep only whitelisted tool",
},
{
"node_id": "l2_agent_research",
"node_id": "l2_judge_r1",
"field": "max_steps",
"after": 5,
"reason": "Allow 5 steps",
@@ -306,9 +306,23 @@ async def test_ensure_builtin_workflows_upgrades_untouched_legacy_positions_only
loc_spec = next(
item for item in BUILTIN_WORKFLOWS if item["workflow_id"] == "location.resolve_unknown"
)
legacy_loc_graph = copy.deepcopy(loc_spec["graph"])
for node in legacy_loc_graph["nodes"]:
lx, ly = _LEGACY_BUILTIN_POSITIONS["location.resolve_unknown"][node["id"]]
legacy_loc_graph = {
"nodes": [
{"id": "l0_normalize", "node_type": "trigger", "position": {"x": 40, "y": 140}},
{"id": "l1_knowledge", "node_type": "deterministic", "position": {"x": 320, "y": 60}},
{"id": "l2_agent_research", "node_type": "llm_agent", "position": {"x": 320, "y": 250}},
{"id": "l3_geo_guardrail", "node_type": "guardrail", "position": {"x": 640, "y": 140}},
{"id": "l4_persist_outcome", "node_type": "output", "position": {"x": 940, "y": 140}},
],
"edges": [],
}
wg_spec = next(
item for item in BUILTIN_WORKFLOWS if item["workflow_id"] == "wargame.infrastructure"
)
legacy_wg_graph = copy.deepcopy(wg_spec["graph"])
for node in legacy_wg_graph["nodes"]:
lx, ly = _LEGACY_BUILTIN_POSITIONS["wargame.infrastructure"][node["id"]]
node["position"] = {"x": lx, "y": ly}
gen_spec = next(
@@ -333,6 +347,22 @@ async def test_ensure_builtin_workflows_upgrades_untouched_legacy_positions_only
updated_by="system",
)
)
session.add(
AIWorkflow(
workflow_id="wargame.infrastructure",
name=wg_spec["name"],
name_en=wg_spec["name_en"],
category=wg_spec["category"],
description=wg_spec["description"],
description_en=wg_spec["description_en"],
is_default=False,
is_builtin=True,
active_revision=1,
published_graph=legacy_wg_graph,
draft_graph=None,
updated_by="system",
)
)
session.add(
AIWorkflow(
workflow_id="default.general",
@@ -360,9 +390,19 @@ async def test_ensure_builtin_workflows_upgrades_untouched_legacy_positions_only
select(AIWorkflow).where(AIWorkflow.workflow_id == "location.resolve_unknown")
)
).scalar_one()
l1 = next(n for n in upgraded_loc.published_graph["nodes"] if n["id"] == "l1_knowledge")
l2 = next(n for n in upgraded_loc.published_graph["nodes"] if n["id"] == "l2_agent_research")
assert l2["position"]["x"] > l1["position"]["x"]
loc_ids = [n["id"] for n in upgraded_loc.published_graph["nodes"]]
assert "l2_research_r1" in loc_ids
assert "l2_judge_r1" in loc_ids
assert "l3_geocode" in loc_ids
upgraded_wg = (
await session.execute(
select(AIWorkflow).where(AIWorkflow.workflow_id == "wargame.infrastructure")
)
).scalar_one()
wg_trig = next(n for n in upgraded_wg.published_graph["nodes"] if n["id"] == "wg_trigger")
wg_inv = next(n for n in upgraded_wg.published_graph["nodes"] if n["id"] == "wg_investigator")
assert wg_inv["position"]["x"] - wg_trig["position"]["x"] >= 700
untouched_gen = (
await session.execute(