conversation-session-tool-cross-product.json 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688
  1. {
  2. "version": 1,
  3. "caseName": "conversation-session-tool-cross-product",
  4. "spec": "./test/e2e/conversation-session/conversation-session-tool-cross-product.test.ts",
  5. "fixtures": [
  6. {
  7. "id": "upstream-tool-cross-product-read-call",
  8. "metadata": {
  9. "kind": "main",
  10. "source": "synthetic",
  11. "timingPolicy": "tool-use",
  12. "syntheticReason": "固定触发 Read 工具,验证 completed 工具历史与 compact/fork/goal 的交互。"
  13. },
  14. "description": "Conversation tool cross product: Read tool_use.",
  15. "match": {
  16. "method": "POST",
  17. "pathIncludes": "/messages",
  18. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_READ"],
  19. "lastUserMessageExcludes": [
  20. "E2E_TOOL_CROSS_PRODUCT_READ_SESSION_CONTEXT"
  21. ],
  22. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_READ"],
  23. "bodyExcludes": [
  24. "E2E_TOOL_CROSS_PRODUCT_READ_SESSION_CONTEXT",
  25. "Generate a concise title",
  26. "CRITICAL: Respond with TEXT ONLY"
  27. ]
  28. },
  29. "response": {
  30. "statusCode": 200,
  31. "toolUse": {
  32. "id": "toolu_e2e_tool_cross_product_read",
  33. "name": "Read",
  34. "input": {
  35. "file_path": "{{e2eRuntimeRoot}}/conversation-session-tool-cross-product/read-fixture.txt"
  36. }
  37. }
  38. }
  39. },
  40. {
  41. "id": "upstream-tool-cross-product-write-call",
  42. "metadata": {
  43. "kind": "main",
  44. "source": "synthetic",
  45. "timingPolicy": "tool-use",
  46. "syntheticReason": "固定触发 Write 工具,验证写文件工具历史不会污染默认工作区。"
  47. },
  48. "description": "Conversation tool cross product: Write tool_use.",
  49. "match": {
  50. "method": "POST",
  51. "pathIncludes": "/messages",
  52. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_WRITE"],
  53. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_WRITE"],
  54. "bodyExcludes": [
  55. "Generate a concise title",
  56. "CRITICAL: Respond with TEXT ONLY"
  57. ]
  58. },
  59. "response": {
  60. "statusCode": 200,
  61. "toolUse": {
  62. "id": "toolu_e2e_tool_cross_product_write",
  63. "name": "Write",
  64. "input": {
  65. "file_path": "{{e2eRuntimeRoot}}/conversation-session-tool-cross-product/write-output.txt",
  66. "content": "E2E_TOOL_RESULT_WRITE\n"
  67. }
  68. }
  69. }
  70. },
  71. {
  72. "id": "upstream-tool-cross-product-edit-call",
  73. "metadata": {
  74. "kind": "main",
  75. "source": "synthetic",
  76. "timingPolicy": "tool-use",
  77. "syntheticReason": "固定触发 Edit 工具,覆盖可写工具的 completed 历史入口。"
  78. },
  79. "description": "Conversation tool cross product: Edit tool_use.",
  80. "match": {
  81. "method": "POST",
  82. "pathIncludes": "/messages",
  83. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_EDIT"],
  84. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_EDIT"],
  85. "bodyExcludes": [
  86. "Generate a concise title",
  87. "CRITICAL: Respond with TEXT ONLY"
  88. ]
  89. },
  90. "response": {
  91. "statusCode": 200,
  92. "toolUse": {
  93. "id": "toolu_e2e_tool_cross_product_edit",
  94. "name": "Edit",
  95. "input": {
  96. "file_path": "{{e2eRuntimeRoot}}/conversation-session-tool-cross-product/edit-output.txt",
  97. "old_string": "",
  98. "new_string": "E2E_TOOL_RESULT_EDIT\n"
  99. }
  100. }
  101. }
  102. },
  103. {
  104. "id": "upstream-tool-cross-product-bash-call",
  105. "metadata": {
  106. "kind": "main",
  107. "source": "synthetic",
  108. "timingPolicy": "tool-use",
  109. "syntheticReason": "固定触发 Bash 工具,避免真实模型命令选择影响工具叉乘稳定性。"
  110. },
  111. "description": "Conversation tool cross product: Bash tool_use.",
  112. "match": {
  113. "method": "POST",
  114. "pathIncludes": "/messages",
  115. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_BASH"],
  116. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_BASH"],
  117. "bodyExcludes": [
  118. "Generate a concise title",
  119. "CRITICAL: Respond with TEXT ONLY"
  120. ]
  121. },
  122. "response": {
  123. "statusCode": 200,
  124. "toolUse": {
  125. "id": "toolu_e2e_tool_cross_product_bash",
  126. "name": "Bash",
  127. "input": {
  128. "command": "printf 'E2E_TOOL_RESULT_BASH\\n'"
  129. }
  130. }
  131. }
  132. },
  133. {
  134. "id": "upstream-tool-cross-product-glob-call",
  135. "metadata": {
  136. "kind": "main",
  137. "source": "synthetic",
  138. "timingPolicy": "tool-use",
  139. "syntheticReason": "固定触发 Glob 工具,覆盖文件搜索工具的 completed 历史入口。"
  140. },
  141. "description": "Conversation tool cross product: Glob tool_use.",
  142. "match": {
  143. "method": "POST",
  144. "pathIncludes": "/messages",
  145. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_GLOB"],
  146. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_GLOB"],
  147. "bodyExcludes": [
  148. "Generate a concise title",
  149. "CRITICAL: Respond with TEXT ONLY"
  150. ]
  151. },
  152. "response": {
  153. "statusCode": 200,
  154. "toolUse": {
  155. "id": "toolu_e2e_tool_cross_product_glob",
  156. "name": "Glob",
  157. "input": {
  158. "path": "{{e2eRuntimeRoot}}/conversation-session-tool-cross-product",
  159. "pattern": "*.e2e"
  160. }
  161. }
  162. }
  163. },
  164. {
  165. "id": "upstream-tool-cross-product-grep-call",
  166. "metadata": {
  167. "kind": "main",
  168. "source": "synthetic",
  169. "timingPolicy": "tool-use",
  170. "syntheticReason": "固定触发 Grep 工具,覆盖内容搜索工具的 completed 历史入口。"
  171. },
  172. "description": "Conversation tool cross product: Grep tool_use.",
  173. "match": {
  174. "method": "POST",
  175. "pathIncludes": "/messages",
  176. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_GREP"],
  177. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_GREP"],
  178. "bodyExcludes": [
  179. "Generate a concise title",
  180. "CRITICAL: Respond with TEXT ONLY"
  181. ]
  182. },
  183. "response": {
  184. "statusCode": 200,
  185. "toolUse": {
  186. "id": "toolu_e2e_tool_cross_product_grep",
  187. "name": "Grep",
  188. "input": {
  189. "path": "{{e2eRuntimeRoot}}/conversation-session-tool-cross-product",
  190. "pattern": "E2E_TOOL_RESULT_GREP",
  191. "output_mode": "content"
  192. }
  193. }
  194. }
  195. },
  196. {
  197. "id": "upstream-tool-cross-product-webfetch-call",
  198. "metadata": {
  199. "kind": "main",
  200. "source": "synthetic",
  201. "timingPolicy": "tool-use",
  202. "syntheticReason": "固定触发 WebFetch 的可预期失败路径,覆盖外部请求工具历史。"
  203. },
  204. "description": "Conversation tool cross product: WebFetch controlled fast-fail tool_use.",
  205. "match": {
  206. "method": "POST",
  207. "pathIncludes": "/messages",
  208. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_WEBFETCH"],
  209. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_WEBFETCH"],
  210. "bodyExcludes": [
  211. "Generate a concise title",
  212. "CRITICAL: Respond with TEXT ONLY"
  213. ]
  214. },
  215. "response": {
  216. "statusCode": 200,
  217. "toolUse": {
  218. "id": "toolu_e2e_tool_cross_product_webfetch",
  219. "name": "WebFetch",
  220. "input": {
  221. "url": "http://127.0.0.1:9/zcode-e2e-tool-cross-product",
  222. "prompt": "Return E2E_TOOL_RESULT_WEBFETCH"
  223. }
  224. }
  225. }
  226. },
  227. {
  228. "id": "upstream-tool-cross-product-todo-read-call",
  229. "metadata": {
  230. "kind": "main",
  231. "source": "synthetic",
  232. "timingPolicy": "tool-use",
  233. "syntheticReason": "固定触发 TodoRead 工具;空结果没有稳定可见卡片时,以 provider-visible 结构化工具历史证明保留。"
  234. },
  235. "description": "Conversation tool cross product: TodoRead tool_use.",
  236. "match": {
  237. "method": "POST",
  238. "pathIncludes": "/messages",
  239. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_TODO_READ"],
  240. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_TODO_READ"],
  241. "bodyExcludes": [
  242. "Generate a concise title",
  243. "CRITICAL: Respond with TEXT ONLY"
  244. ]
  245. },
  246. "response": {
  247. "statusCode": 200,
  248. "toolUse": {
  249. "id": "toolu_e2e_tool_cross_product_todo_read",
  250. "name": "TodoRead",
  251. "input": {}
  252. }
  253. }
  254. },
  255. {
  256. "id": "upstream-tool-cross-product-todo-write-call",
  257. "metadata": {
  258. "kind": "main",
  259. "source": "synthetic",
  260. "timingPolicy": "tool-use",
  261. "syntheticReason": "固定触发 TodoWrite 工具,覆盖 todo 状态写入后的工具历史。"
  262. },
  263. "description": "Conversation tool cross product: TodoWrite tool_use.",
  264. "match": {
  265. "method": "POST",
  266. "pathIncludes": "/messages",
  267. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_TODO_WRITE"],
  268. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_TODO_WRITE"],
  269. "bodyExcludes": [
  270. "Generate a concise title",
  271. "CRITICAL: Respond with TEXT ONLY"
  272. ]
  273. },
  274. "response": {
  275. "statusCode": 200,
  276. "toolUse": {
  277. "id": "toolu_e2e_tool_cross_product_todo_write",
  278. "name": "TodoWrite",
  279. "input": {
  280. "todos": [
  281. {
  282. "content": "E2E_TOOL_RESULT_TODO_WRITE",
  283. "status": "completed",
  284. "priority": "low"
  285. }
  286. ]
  287. }
  288. }
  289. }
  290. },
  291. {
  292. "id": "upstream-tool-cross-product-goal-read-call",
  293. "metadata": {
  294. "kind": "main",
  295. "source": "synthetic",
  296. "timingPolicy": "tool-use",
  297. "syntheticReason": "固定触发 GoalRead 工具,覆盖目标读取工具历史。"
  298. },
  299. "description": "Conversation tool cross product: GoalRead tool_use.",
  300. "match": {
  301. "method": "POST",
  302. "pathIncludes": "/messages",
  303. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_GOAL_READ"],
  304. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_GOAL_READ"],
  305. "bodyExcludes": [
  306. "Generate a concise title",
  307. "CRITICAL: Respond with TEXT ONLY"
  308. ]
  309. },
  310. "response": {
  311. "statusCode": 200,
  312. "toolUse": {
  313. "id": "toolu_e2e_tool_cross_product_goal_read",
  314. "name": "GoalRead",
  315. "input": {}
  316. }
  317. }
  318. },
  319. {
  320. "id": "upstream-tool-cross-product-enter-plan-mode-call",
  321. "metadata": {
  322. "kind": "main",
  323. "source": "synthetic",
  324. "timingPolicy": "tool-use",
  325. "syntheticReason": "固定触发 EnterPlanMode 工具;V4 隐藏内部模式切换行时,以 provider-visible 结构化工具历史证明保留,并在 goal 前切回 Full access。"
  326. },
  327. "description": "Conversation tool cross product: EnterPlanMode tool_use.",
  328. "match": {
  329. "method": "POST",
  330. "pathIncludes": "/messages",
  331. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_ENTER_PLAN_MODE"],
  332. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_ENTER_PLAN_MODE"],
  333. "bodyExcludes": [
  334. "Generate a concise title",
  335. "CRITICAL: Respond with TEXT ONLY"
  336. ]
  337. },
  338. "response": {
  339. "statusCode": 200,
  340. "toolUse": {
  341. "id": "toolu_e2e_tool_cross_product_enter_plan_mode",
  342. "name": "EnterPlanMode",
  343. "input": {}
  344. }
  345. }
  346. },
  347. {
  348. "id": "upstream-tool-cross-product-exit-plan-mode-call",
  349. "metadata": {
  350. "kind": "main",
  351. "source": "synthetic",
  352. "timingPolicy": "tool-use",
  353. "syntheticReason": "固定触发 ExitPlanMode 工具,覆盖计划模式退出后的工具历史。"
  354. },
  355. "description": "Conversation tool cross product: ExitPlanMode fast-fail tool_use.",
  356. "match": {
  357. "method": "POST",
  358. "pathIncludes": "/messages",
  359. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_EXIT_PLAN_MODE"],
  360. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_EXIT_PLAN_MODE"],
  361. "bodyExcludes": [
  362. "Generate a concise title",
  363. "CRITICAL: Respond with TEXT ONLY"
  364. ]
  365. },
  366. "response": {
  367. "statusCode": 200,
  368. "toolUse": {
  369. "id": "toolu_e2e_tool_cross_product_exit_plan_mode",
  370. "name": "ExitPlanMode",
  371. "input": {
  372. "plan": "E2E_TOOL_RESULT_EXIT_PLAN_MODE"
  373. }
  374. }
  375. }
  376. },
  377. {
  378. "id": "upstream-tool-cross-product-ask-user-question-call",
  379. "metadata": {
  380. "kind": "main",
  381. "source": "synthetic",
  382. "timingPolicy": "tool-use",
  383. "syntheticReason": "固定触发 AskUserQuestion 工具,覆盖用户问询阻塞与自动选择路径。"
  384. },
  385. "description": "Conversation tool cross product: AskUserQuestion tool_use.",
  386. "match": {
  387. "method": "POST",
  388. "pathIncludes": "/messages",
  389. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_ASK_USER_QUESTION"],
  390. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_ASK_USER_QUESTION"],
  391. "bodyExcludes": [
  392. "Generate a concise title",
  393. "CRITICAL: Respond with TEXT ONLY",
  394. "toolu_e2e_tool_cross_product_ask_user_question"
  395. ]
  396. },
  397. "response": {
  398. "statusCode": 200,
  399. "toolUse": {
  400. "id": "toolu_e2e_tool_cross_product_ask_user_question",
  401. "name": "AskUserQuestion",
  402. "input": {
  403. "questions": [
  404. {
  405. "question": "E2E_TOOL_CROSS_PRODUCT_ASK_USER_QUESTION: choose an answer?",
  406. "header": "E2E",
  407. "options": [
  408. {
  409. "label": "Use default",
  410. "description": "Continue the e2e run with the default answer."
  411. },
  412. {
  413. "label": "Use fallback",
  414. "description": "Continue the e2e run with the fallback answer."
  415. }
  416. ]
  417. }
  418. ]
  419. }
  420. }
  421. }
  422. },
  423. {
  424. "id": "upstream-tool-cross-product-read-session-context-call",
  425. "metadata": {
  426. "kind": "main",
  427. "source": "synthetic",
  428. "timingPolicy": "tool-use",
  429. "syntheticReason": "固定触发 ReadSessionContext 的可预期失败路径,覆盖会话读取工具历史。"
  430. },
  431. "description": "Conversation tool cross product: ReadSessionContext tool_use.",
  432. "match": {
  433. "method": "POST",
  434. "pathIncludes": "/messages",
  435. "lastUserMessageIncludes": [
  436. "E2E_TOOL_CROSS_PRODUCT_READ_SESSION_CONTEXT"
  437. ],
  438. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_READ_SESSION_CONTEXT"],
  439. "bodyExcludes": [
  440. "Generate a concise title",
  441. "CRITICAL: Respond with TEXT ONLY"
  442. ]
  443. },
  444. "response": {
  445. "statusCode": 200,
  446. "toolUse": {
  447. "id": "toolu_e2e_tool_cross_product_read_session_context",
  448. "name": "ReadSessionContext",
  449. "input": {
  450. "sessionId": "sess_e2e_missing_tool_cross_product",
  451. "query": "E2E_TOOL_RESULT_READ_SESSION_CONTEXT",
  452. "strategy": "relevant"
  453. }
  454. }
  455. }
  456. },
  457. {
  458. "id": "upstream-tool-cross-product-send-message-call",
  459. "metadata": {
  460. "kind": "main",
  461. "source": "synthetic",
  462. "timingPolicy": "tool-use",
  463. "syntheticReason": "固定触发 SendMessage 的可预期失败路径,覆盖跨 agent 消息工具历史。"
  464. },
  465. "description": "Conversation tool cross product: SendMessage conditional tool_use.",
  466. "match": {
  467. "method": "POST",
  468. "pathIncludes": "/messages",
  469. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_SEND_MESSAGE"],
  470. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_SEND_MESSAGE"],
  471. "bodyExcludes": [
  472. "Generate a concise title",
  473. "CRITICAL: Respond with TEXT ONLY"
  474. ]
  475. },
  476. "response": {
  477. "statusCode": 200,
  478. "toolUse": {
  479. "id": "toolu_e2e_tool_cross_product_sendmessage",
  480. "name": "SendMessage",
  481. "input": {
  482. "to": "agent_e2e_missing_tool_cross_product",
  483. "summary": "E2E_TOOL_RESULT_SEND_MESSAGE",
  484. "message": "E2E_TOOL_RESULT_SEND_MESSAGE"
  485. }
  486. }
  487. }
  488. },
  489. {
  490. "id": "upstream-tool-cross-product-agent-call",
  491. "metadata": {
  492. "kind": "main",
  493. "source": "synthetic",
  494. "timingPolicy": "tool-use",
  495. "syntheticReason": "固定触发 Agent 的可预期失败路径,覆盖子 agent 工具历史。"
  496. },
  497. "description": "Conversation tool cross product: Agent fast-fail tool_use.",
  498. "match": {
  499. "method": "POST",
  500. "pathIncludes": "/messages",
  501. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_AGENT"],
  502. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_AGENT"],
  503. "bodyExcludes": [
  504. "Generate a concise title",
  505. "CRITICAL: Respond with TEXT ONLY"
  506. ]
  507. },
  508. "response": {
  509. "statusCode": 200,
  510. "toolUse": {
  511. "id": "toolu_e2e_tool_cross_product_agent",
  512. "name": "Agent",
  513. "input": {
  514. "description": "E2E fast fail",
  515. "prompt": "E2E_TOOL_RESULT_AGENT",
  516. "subagent_type": "Missing"
  517. }
  518. }
  519. }
  520. },
  521. {
  522. "id": "upstream-tool-cross-product-skill-call",
  523. "metadata": {
  524. "kind": "main",
  525. "source": "synthetic",
  526. "timingPolicy": "tool-use",
  527. "syntheticReason": "固定触发 Skill 的可预期失败路径,覆盖技能工具历史。"
  528. },
  529. "description": "Conversation tool cross product: Skill fast-fail tool_use.",
  530. "match": {
  531. "method": "POST",
  532. "pathIncludes": "/messages",
  533. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_SKILL"],
  534. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_SKILL"],
  535. "bodyExcludes": [
  536. "Generate a concise title",
  537. "CRITICAL: Respond with TEXT ONLY"
  538. ]
  539. },
  540. "response": {
  541. "statusCode": 200,
  542. "toolUse": {
  543. "id": "toolu_e2e_tool_cross_product_skill",
  544. "name": "Skill",
  545. "input": {
  546. "skill": "zcode-e2e-missing-skill"
  547. }
  548. }
  549. }
  550. },
  551. {
  552. "id": "upstream-tool-cross-product-workflow-call",
  553. "metadata": {
  554. "kind": "main",
  555. "source": "synthetic",
  556. "timingPolicy": "tool-use",
  557. "syntheticReason": "固定触发 Workflow 的可预期失败路径,覆盖 workflow 工具历史。"
  558. },
  559. "description": "Conversation tool cross product: Workflow fast-fail tool_use.",
  560. "match": {
  561. "method": "POST",
  562. "pathIncludes": "/messages",
  563. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_WORKFLOW"],
  564. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_WORKFLOW"],
  565. "bodyExcludes": [
  566. "Generate a concise title",
  567. "CRITICAL: Respond with TEXT ONLY"
  568. ]
  569. },
  570. "response": {
  571. "statusCode": 200,
  572. "toolUse": {
  573. "id": "toolu_e2e_tool_cross_product_workflow",
  574. "name": "Workflow",
  575. "input": {}
  576. }
  577. }
  578. },
  579. {
  580. "id": "upstream-tool-cross-product-fork-probe-final",
  581. "metadata": {
  582. "kind": "main",
  583. "source": "synthetic",
  584. "timingPolicy": "fast-text",
  585. "syntheticReason": "隐藏工具行和空结果工具在 fork child 中通过 provider-visible continuation 的配对 tool_use/tool_result 证明历史已复制;child toolCallId 按 stable fork 合同重映射。"
  586. },
  587. "description": "Conversation tool cross product: fork child history probe.",
  588. "match": {
  589. "method": "POST",
  590. "pathIncludes": "/messages",
  591. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_FORK_PROBE"],
  592. "bodyIncludes": [
  593. "E2E_TOOL_CROSS_PRODUCT_FORK_PROBE"
  594. ],
  595. "bodyExcludes": [
  596. "Generate a concise title",
  597. "CRITICAL: Respond with TEXT ONLY"
  598. ]
  599. },
  600. "response": {
  601. "statusCode": 200,
  602. "text": "upstream-e2e-ok"
  603. }
  604. },
  605. {
  606. "id": "upstream-tool-cross-product-compact-success",
  607. "metadata": {
  608. "kind": "compact",
  609. "source": "synthetic",
  610. "timingPolicy": "fast-text",
  611. "syntheticReason": "固定响应 TX 显式触发的 manual compact,避免缺失 replay fixture 进入 provider retry。"
  612. },
  613. "description": "Conversation tool cross product: summarize an explicitly requested manual compact after a completed tool turn.",
  614. "match": {
  615. "method": "POST",
  616. "pathIncludes": "/messages",
  617. "bodyIncludes": [
  618. "CRITICAL: Respond with TEXT ONLY",
  619. "E2E_TOOL_CROSS_PRODUCT",
  620. "toolu_e2e_tool_cross_product",
  621. "\"stream\":true"
  622. ],
  623. "bodyExcludes": ["Generate a concise title"]
  624. },
  625. "response": {
  626. "statusCode": 200,
  627. "statusMessage": "OK",
  628. "text": {
  629. "id": "upstream-e2e-tool-cross-product-compact-success",
  630. "inputTokens": 256,
  631. "outputTokens": 48,
  632. "text": "<analysis>Summarized the completed tool turn.</analysis>\n\n<summary>E2E_TOOL_CROSS_PRODUCT completed a tool call and returned upstream-e2e-ok before the user requested manual compact.</summary>"
  633. }
  634. }
  635. },
  636. {
  637. "id": "upstream-tool-cross-product-tool-final",
  638. "metadata": {
  639. "kind": "main",
  640. "source": "synthetic",
  641. "timingPolicy": "fast-text",
  642. "syntheticReason": "工具结果回填后稳定结束当前轮,真实 provider 文案不影响工具历史断言。"
  643. },
  644. "description": "Conversation tool cross product: final text after any tool_result.",
  645. "match": {
  646. "method": "POST",
  647. "pathIncludes": "/messages",
  648. "bodyIncludes": [
  649. "E2E_TOOL_CROSS_PRODUCT",
  650. "toolu_e2e_tool_cross_product"
  651. ],
  652. "bodyExcludes": [
  653. "Generate a concise title",
  654. "CRITICAL: Respond with TEXT ONLY",
  655. "E2E_TOOL_CROSS_PRODUCT_GOAL_OBJECTIVE"
  656. ]
  657. },
  658. "response": {
  659. "statusCode": 200,
  660. "text": "upstream-e2e-ok"
  661. }
  662. },
  663. {
  664. "id": "upstream-tool-cross-product-goal-final",
  665. "metadata": {
  666. "kind": "main",
  667. "source": "synthetic",
  668. "timingPolicy": "fast-text",
  669. "syntheticReason": "goal continuation 只需稳定完成,真实 provider 文案不影响目标状态断言。"
  670. },
  671. "description": "Conversation tool cross product: final text for goal continuation.",
  672. "match": {
  673. "method": "POST",
  674. "pathIncludes": "/messages",
  675. "lastUserMessageIncludes": ["E2E_TOOL_CROSS_PRODUCT_GOAL_OBJECTIVE"],
  676. "bodyIncludes": ["E2E_TOOL_CROSS_PRODUCT_GOAL_OBJECTIVE"],
  677. "bodyExcludes": [
  678. "Generate a concise title",
  679. "CRITICAL: Respond with TEXT ONLY"
  680. ]
  681. },
  682. "response": {
  683. "statusCode": 200,
  684. "text": "upstream-e2e-ok"
  685. }
  686. }
  687. ]
  688. }