103
*/
104
export function prependAnnouncementToFirstTurn(turns: readonly Turn[], announcement: string): readonly Turn[] {
106
return turns;
107
}
109
>
const first = result[0];
110
>
const part = first.responseParts[0];
111
>
if (part?.kind === ResponsePartKind.Markdown) {
112
const responseParts = first.responseParts.slice();
113
responseParts[0] = { ...part, content: announcement + part.content };
114
result[0] = { ...first, responseParts };
116
>
const responseParts: ResponsePart[] = [
117
>
{ kind: ResponsePartKind.Markdown, id: generateUuid(), content: announcement },
118
>
...first.responseParts,
119
>
];
120
>
result[0] = { ...first, responseParts };
121
>
}
122
>
return result;
123
>
}
124
125
/** Parameters for {@link WorktreeIsolation.resolveIsolationConfig}. */