| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343 |
- {
- "version": 1,
- "caseName": "conversation-session-reply-language",
- "spec": "./test/e2e/conversation-session/context/conversation-session-reply-language.test.ts",
- "fixtures": [
- {
- "id": "rl-title-default",
- "description": "RL01 首轮结束后的标题请求:默认规则。",
- "metadata": {
- "kind": "common",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "首轮结束后异步触发 title sidecar;用任务首轮 marker 隔离并固定标题响应;语言规则由 spec 断言。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "bodyIncludes": ["Generate a concise title", "E2E_RL_DEFAULT"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-title-default",
- "inputTokens": 64,
- "outputTokens": 8,
- "text": "{\"title\": \"Reply Language\"}"
- }
- }
- },
- {
- "id": "rl-title-new-task",
- "description": "RL07 新任务首轮结束后的标题请求:按公告语言。",
- "metadata": {
- "kind": "common",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "首轮结束后异步触发 title sidecar;用任务首轮 marker 隔离并固定标题响应;语言规则由 spec 断言。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "bodyIncludes": ["Generate a concise title", "E2E_RL_NEWTASK"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-title-new-task",
- "inputTokens": 64,
- "outputTokens": 8,
- "text": "{\"title\": \"Reply Language\"}"
- }
- }
- },
- {
- "id": "rl-default",
- "description": "RL01 默认留空的首轮:不公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_DEFAULT"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-default",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_DEFAULT"
- }
- }
- },
- {
- "id": "rl-set",
- "description": "RL02 输入 简体中文 后的一轮:首次公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_SET"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-set",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_SET"
- }
- }
- },
- {
- "id": "rl-same",
- "description": "RL03 值不变的一轮:不再公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_SAME"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-same",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_SAME"
- }
- }
- },
- {
- "id": "rl-changed",
- "description": "RL04 改成 日本語 后的一轮:追加一条公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_CHANGED"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-changed",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_CHANGED"
- }
- }
- },
- {
- "id": "rl-compact-summary",
- "description": "RL05 手动 /compact 的 summary 请求。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "手动 compact 需要固定 summary;summary 文案不参与断言。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "bodyIncludes": ["E2E_RL_CHANGED", "CRITICAL: Respond with TEXT ONLY"],
- "bodyExcludes": ["Generate a concise title"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-compact-summary",
- "inputTokens": 256,
- "outputTokens": 64,
- "text": "<analysis>The user sent three short messages and asked for fixed replies.</analysis>\n\n<summary>1. Primary Request and Intent:\n The user asked for fixed replies. The assistant replied with the fixed text each time.\n</summary>"
- }
- }
- },
- {
- "id": "rl-compacted",
- "description": "RL05 compact 后的第一轮:重述 日本語 公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_COMPACTED"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-compacted",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_COMPACTED"
- }
- }
- },
- {
- "id": "rl-resumed",
- "description": "RL06 重启 App 冷恢复后的一轮:不再公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_RESUMED"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-resumed",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_RESUMED"
- }
- }
- },
- {
- "id": "rl-new-task",
- "description": "RL07 新任务首轮:公告当前设置。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_NEWTASK"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-new-task",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_NEWTASK"
- }
- }
- },
- {
- "id": "rl-cleared",
- "description": "RL08 清空设置后的一轮:发一次清除公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_CLEARED"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-cleared",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_CLEARED"
- }
- }
- },
- {
- "id": "rl-after-clear",
- "description": "RL08 清除后的第二轮:不再公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_AFTERCLEAR"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-after-clear",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_AFTERCLEAR"
- }
- }
- },
- {
- "id": "rl-other-window",
- "description": "RL09 在第二个窗口改设置后,第一个窗口的一轮:追加 Deutsch 公告。",
- "metadata": {
- "kind": "main",
- "timingPolicy": "fast-text",
- "source": "synthetic",
- "syntheticReason": "以本轮 marker 匹配最后一条 user 消息,固定回复;语言公告的形态由 spec 读取请求体断言,不在 matcher 里门禁。"
- },
- "maxMatches": 2,
- "match": {
- "method": "POST",
- "pathIncludes": "/messages",
- "lastUserMessageIncludes": ["E2E_RL_OTHERWINDOW"],
- "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
- },
- "response": {
- "statusCode": 200,
- "text": {
- "id": "rl-other-window",
- "inputTokens": 80,
- "outputTokens": 8,
- "text": "RL_A_OTHERWINDOW"
- }
- }
- }
- ]
- }
|