






















@@ -17,6 +17,7 @@ export type MatrixQaScenarioId =
1717| "matrix-thread-root-preservation"
1818| "matrix-thread-nested-reply-shape"
1919| "matrix-thread-isolation"
20+| "matrix-subagent-thread-spawn"
2021| "matrix-top-level-reply-shape"
2122| "matrix-room-thread-reply-override"
2223| "matrix-room-quiet-streaming-preview"
@@ -61,6 +62,7 @@ export type MatrixQaScenarioId =
6162| "matrix-e2ee-artifact-redaction"
6263| "matrix-e2ee-media-image"
6364| "matrix-e2ee-key-bootstrap-failure";
65+export type MatrixQaE2eeScenarioId = Extract<MatrixQaScenarioId, `matrix-e2ee-${string}`>;
64666567export type MatrixQaScenarioDefinition = LiveTransportScenarioDefinition<MatrixQaScenarioId> & {
6668configOverrides?: MatrixQaConfigOverrides;
@@ -73,6 +75,7 @@ export const MATRIX_QA_DRIVER_DM_SHARED_ROOM_KEY = "driver-dm-shared";
7375export const MATRIX_QA_E2EE_ROOM_KEY = "e2ee";
7476export const MATRIX_QA_E2EE_VERIFICATION_DM_ROOM_KEY = "e2ee-verification-dm";
7577export const MATRIX_QA_HOMESERVER_ROOM_KEY = "homeserver";
78+export const MATRIX_QA_MAIN_ROOM_KEY = "main";
7679export const MATRIX_QA_MEDIA_ROOM_KEY = "media";
7780export const MATRIX_QA_MEMBERSHIP_ROOM_KEY = "membership";
7881export const MATRIX_QA_RESTART_ROOM_KEY = "restart";
@@ -85,7 +88,7 @@ function buildMatrixQaDmTopology(
8588}>,
8689): MatrixQaTopologySpec {
8790return {
88-defaultRoomKey: "main",
91+defaultRoomKey: MATRIX_QA_MAIN_ROOM_KEY,
8992rooms: rooms.map((room) => ({
9093key: room.key,
9194kind: "dm" as const,
@@ -102,7 +105,7 @@ function buildMatrixQaSingleGroupTopology(params: {
102105requireMention: boolean;
103106}): MatrixQaTopologySpec {
104107return {
105-defaultRoomKey: "main",
108+defaultRoomKey: MATRIX_QA_MAIN_ROOM_KEY,
106109rooms: [
107110{
108111encrypted: params.encrypted === true,
@@ -116,6 +119,23 @@ function buildMatrixQaSingleGroupTopology(params: {
116119};
117120}
118121122+export function buildMatrixQaE2eeScenarioRoomKey(scenarioId: MatrixQaE2eeScenarioId) {
123+const suffix = scenarioId.replace(/^matrix-e2ee-/, "").replace(/[^A-Za-z0-9_-]/g, "-");
124+return `${MATRIX_QA_E2EE_ROOM_KEY}-${suffix}`;
125+}
126+127+function buildMatrixQaE2eeScenarioTopology(params: {
128+scenarioId: MatrixQaE2eeScenarioId;
129+name: string;
130+}): MatrixQaTopologySpec {
131+return buildMatrixQaSingleGroupTopology({
132+encrypted: true,
133+key: buildMatrixQaE2eeScenarioRoomKey(params.scenarioId),
134+name: params.name,
135+requireMention: true,
136+});
137+}
138+119139const MATRIX_QA_DRIVER_DM_TOPOLOGY = buildMatrixQaDmTopology([
120140{
121141key: MATRIX_QA_DRIVER_DM_ROOM_KEY,
@@ -170,13 +190,6 @@ const MATRIX_QA_HOMESERVER_ROOM_TOPOLOGY = buildMatrixQaSingleGroupTopology({
170190requireMention: true,
171191});
172192173-const MATRIX_QA_E2EE_ROOM_TOPOLOGY = buildMatrixQaSingleGroupTopology({
174-encrypted: true,
175-key: MATRIX_QA_E2EE_ROOM_KEY,
176-name: "Matrix QA E2EE Room",
177-requireMention: true,
178-});
179-180193const MATRIX_QA_E2EE_VERIFICATION_DM_TOPOLOGY: MatrixQaTopologySpec = {
181194defaultRoomKey: "main",
182195rooms: [
@@ -218,6 +231,25 @@ export const MATRIX_QA_SCENARIOS: MatrixQaScenarioDefinition[] = [
218231timeoutMs: 75_000,
219232title: "Matrix top-level reply stays out of prior thread",
220233},
234+{
235+id: "matrix-subagent-thread-spawn",
236+timeoutMs: 75_000,
237+title: "Matrix sessions_spawn thread=true creates a bound child thread",
238+configOverrides: {
239+groupsByKey: {
240+[MATRIX_QA_MAIN_ROOM_KEY]: {
241+tools: {
242+allow: ["sessions_spawn"],
243+},
244+},
245+},
246+threadBindings: {
247+enabled: true,
248+spawnSubagentSessions: true,
249+},
250+toolProfile: "coding",
251+},
252+},
221253{
222254id: "matrix-top-level-reply-shape",
223255standardId: "top-level-reply-shape",
@@ -448,49 +480,70 @@ export const MATRIX_QA_SCENARIOS: MatrixQaScenarioDefinition[] = [
448480id: "matrix-e2ee-basic-reply",
449481timeoutMs: 75_000,
450482title: "Matrix E2EE encrypted room replies decrypt end-to-end",
451-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
483+topology: buildMatrixQaE2eeScenarioTopology({
484+scenarioId: "matrix-e2ee-basic-reply",
485+name: "Matrix QA E2EE Basic Reply Room",
486+}),
452487configOverrides: MATRIX_QA_E2EE_CONFIG,
453488},
454489{
455490id: "matrix-e2ee-thread-follow-up",
456491timeoutMs: 75_000,
457492title: "Matrix E2EE encrypted threads preserve reply shape",
458-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
493+topology: buildMatrixQaE2eeScenarioTopology({
494+scenarioId: "matrix-e2ee-thread-follow-up",
495+name: "Matrix QA E2EE Thread Follow-up Room",
496+}),
459497configOverrides: MATRIX_QA_E2EE_CONFIG,
460498},
461499{
462500id: "matrix-e2ee-bootstrap-success",
463501timeoutMs: 90_000,
464502title: "Matrix E2EE bootstrap verifies the owner device and backup",
465-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
503+topology: buildMatrixQaE2eeScenarioTopology({
504+scenarioId: "matrix-e2ee-bootstrap-success",
505+name: "Matrix QA E2EE Bootstrap Success Room",
506+}),
466507configOverrides: MATRIX_QA_E2EE_CONFIG,
467508},
468509{
469510id: "matrix-e2ee-recovery-key-lifecycle",
470511timeoutMs: 90_000,
471512title: "Matrix E2EE recovery key restores and resets room-key backup",
472-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
513+topology: buildMatrixQaE2eeScenarioTopology({
514+scenarioId: "matrix-e2ee-recovery-key-lifecycle",
515+name: "Matrix QA E2EE Recovery Key Lifecycle Room",
516+}),
473517configOverrides: MATRIX_QA_E2EE_CONFIG,
474518},
475519{
476520id: "matrix-e2ee-device-sas-verification",
477521timeoutMs: 90_000,
478522title: "Matrix E2EE device verification completes SAS emoji compare",
479-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
523+topology: buildMatrixQaE2eeScenarioTopology({
524+scenarioId: "matrix-e2ee-device-sas-verification",
525+name: "Matrix QA E2EE Device SAS Verification Room",
526+}),
480527configOverrides: MATRIX_QA_E2EE_CONFIG,
481528},
482529{
483530id: "matrix-e2ee-qr-verification",
484531timeoutMs: 90_000,
485532title: "Matrix E2EE QR verification completes identity scan",
486-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
533+topology: buildMatrixQaE2eeScenarioTopology({
534+scenarioId: "matrix-e2ee-qr-verification",
535+name: "Matrix QA E2EE QR Verification Room",
536+}),
487537configOverrides: MATRIX_QA_E2EE_CONFIG,
488538},
489539{
490540id: "matrix-e2ee-stale-device-hygiene",
491541timeoutMs: 90_000,
492542title: "Matrix E2EE stale own devices can be removed without deleting the current device",
493-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
543+topology: buildMatrixQaE2eeScenarioTopology({
544+scenarioId: "matrix-e2ee-stale-device-hygiene",
545+name: "Matrix QA E2EE Stale Device Hygiene Room",
546+}),
494547configOverrides: MATRIX_QA_E2EE_CONFIG,
495548},
496549{
@@ -504,35 +557,50 @@ export const MATRIX_QA_SCENARIOS: MatrixQaScenarioDefinition[] = [
504557id: "matrix-e2ee-restart-resume",
505558timeoutMs: 90_000,
506559title: "Matrix E2EE encrypted rooms resume after gateway restart",
507-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
560+topology: buildMatrixQaE2eeScenarioTopology({
561+scenarioId: "matrix-e2ee-restart-resume",
562+name: "Matrix QA E2EE Restart Resume Room",
563+}),
508564configOverrides: MATRIX_QA_E2EE_CONFIG,
509565},
510566{
511567id: "matrix-e2ee-verification-notice-no-trigger",
512568timeoutMs: 30_000,
513569title: "Matrix E2EE verification notices do not trigger replies",
514-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
570+topology: buildMatrixQaE2eeScenarioTopology({
571+scenarioId: "matrix-e2ee-verification-notice-no-trigger",
572+name: "Matrix QA E2EE Verification Notice Room",
573+}),
515574configOverrides: MATRIX_QA_E2EE_CONFIG,
516575},
517576{
518577id: "matrix-e2ee-artifact-redaction",
519578timeoutMs: 75_000,
520579title: "Matrix E2EE decrypted payloads stay out of default event artifacts",
521-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
580+topology: buildMatrixQaE2eeScenarioTopology({
581+scenarioId: "matrix-e2ee-artifact-redaction",
582+name: "Matrix QA E2EE Artifact Redaction Room",
583+}),
522584configOverrides: MATRIX_QA_E2EE_CONFIG,
523585},
524586{
525587id: "matrix-e2ee-media-image",
526588timeoutMs: 90_000,
527589title: "Matrix E2EE encrypted image attachments reach the model vision path",
528-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
590+topology: buildMatrixQaE2eeScenarioTopology({
591+scenarioId: "matrix-e2ee-media-image",
592+name: "Matrix QA E2EE Media Image Room",
593+}),
529594configOverrides: MATRIX_QA_E2EE_CONFIG,
530595},
531596{
532597id: "matrix-e2ee-key-bootstrap-failure",
533598timeoutMs: 90_000,
534599title: "Matrix E2EE bootstrap reports room-key backup failures",
535-topology: MATRIX_QA_E2EE_ROOM_TOPOLOGY,
600+topology: buildMatrixQaE2eeScenarioTopology({
601+scenarioId: "matrix-e2ee-key-bootstrap-failure",
602+name: "Matrix QA E2EE Key Bootstrap Failure Room",
603+}),
536604configOverrides: MATRIX_QA_E2EE_CONFIG,
537605},
538606];
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。