conversation-session-model-provider-settings-transition.json 3.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. {
  2. "version": 1,
  3. "caseName": "conversation-session-model-provider-settings-transition",
  4. "spec": "./test/e2e/conversation-session/models/conversation-session-model-provider-settings-transition.test.ts",
  5. "fixtures": [
  6. {
  7. "id": "model-provider-transition-title",
  8. "description": "设置页往返用例的非流式标题响应。",
  9. "metadata": {
  10. "kind": "common",
  11. "timingPolicy": "fast-text",
  12. "source": "synthetic",
  13. "syntheticReason": "标题生成不属于设置页往返的模型选择语义,但首发后的请求必须完整回放。"
  14. },
  15. "match": {
  16. "method": "POST",
  17. "pathIncludes": "/chat/completions",
  18. "bodyIncludes": ["Generate a concise title", "E2E_MODEL_PROVIDER_TRANSITION_"]
  19. },
  20. "response": {
  21. "statusCode": 200,
  22. "statusMessage": "OK",
  23. "headers": {
  24. "content-type": "application/json; charset=utf-8"
  25. },
  26. "body": "{\"id\":\"model-provider-transition-title\",\"object\":\"chat.completion\",\"created\":0,\"model\":\"deepseek-v4-flash\",\"choices\":[{\"index\":0,\"message\":{\"role\":\"assistant\",\"content\":\"{\\\"title\\\":\\\"Model provider transition\\\"}\"},\"finish_reason\":\"stop\"}],\"usage\":{\"prompt_tokens\":32,\"completion_tokens\":8,\"total_tokens\":40}}"
  27. }
  28. },
  29. {
  30. "id": "model-provider-transition-s01",
  31. "description": "I29 切换 BigModel Family 连接后首发仍使用 上游。",
  32. "metadata": {
  33. "kind": "main",
  34. "timingPolicy": "fast-text",
  35. "source": "synthetic",
  36. "syntheticReason": "验证切换 BigModel Family 连接后 上游 deferred draft 的首发请求仍使用 上游。"
  37. },
  38. "maxMatches": 1,
  39. "match": {
  40. "method": "POST",
  41. "pathIncludes": "/chat/completions",
  42. "lastUserMessageIncludes": ["E2E_MODEL_PROVIDER_TRANSITION_S01"],
  43. "bodyExcludes": ["Generate a concise title"]
  44. },
  45. "response": {
  46. "statusCode": 200,
  47. "statusMessage": "OK",
  48. "headers": {
  49. "content-type": "text/event-stream; charset=utf-8"
  50. },
  51. "body": "data: {\"id\":\"model-provider-transition-s01\",\"object\":\"chat.completion.chunk\",\"created\":0,\"model\":\"deepseek-v4-flash\",\"choices\":[{\"index\":0,\"delta\":{\"content\":\"upstream-e2e-ok\"},\"finish_reason\":null}]}\n\ndata: {\"id\":\"model-provider-transition-s01\",\"object\":\"chat.completion.chunk\",\"created\":0,\"model\":\"deepseek-v4-flash\",\"choices\":[{\"index\":0,\"delta\":{},\"finish_reason\":\"stop\"}]}\n\ndata: [DONE]\n\n"
  52. }
  53. },
  54. {
  55. "id": "model-provider-transition-s02",
  56. "description": "I30 重复选择当前 Team Plan 后首发仍使用 上游。",
  57. "metadata": {
  58. "kind": "main",
  59. "timingPolicy": "fast-text",
  60. "source": "synthetic",
  61. "syntheticReason": "验证重复选择当前 Team Plan 不改变 上游 draft。"
  62. },
  63. "maxMatches": 1,
  64. "match": {
  65. "method": "POST",
  66. "pathIncludes": "/chat/completions",
  67. "lastUserMessageIncludes": ["E2E_MODEL_PROVIDER_TRANSITION_S02"],
  68. "bodyExcludes": ["Generate a concise title"]
  69. },
  70. "response": {
  71. "statusCode": 200,
  72. "statusMessage": "OK",
  73. "headers": {
  74. "content-type": "text/event-stream; charset=utf-8"
  75. },
  76. "body": "data: {\"id\":\"model-provider-transition-s02\",\"object\":\"chat.completion.chunk\",\"created\":0,\"model\":\"deepseek-v4-flash\",\"choices\":[{\"index\":0,\"delta\":{\"content\":\"upstream-e2e-ok\"},\"finish_reason\":null}]}\n\ndata: {\"id\":\"model-provider-transition-s02\",\"object\":\"chat.completion.chunk\",\"created\":0,\"model\":\"deepseek-v4-flash\",\"choices\":[{\"index\":0,\"delta\":{},\"finish_reason\":\"stop\"}]}\n\ndata: [DONE]\n\n"
  77. }
  78. }
  79. ]
  80. }