fix(assistant): CI of the web search and tour write cards

This commit is contained in:
Maurice
2026-10-23 18:08:26 +02:00
parent d07b8ba56e
commit 88e6f332d3
30 changed files with 78 additions and 38 deletions
@@ -55,7 +55,10 @@ export const UNLINK_TOUR_PACKING: ToolCards = {
return { placeId: args.placeId, category: typeof category === 'string' ? category : null };
},
reads: (args) => [{ tool: 'get_tour_packing', args: { placeId: args.placeId } }],
unchanged: (_result, snapshot, call?: UndoCall) =>
!!call && linkedCategory(readOf(snapshot, 'get_tour_packing', { placeId: call.args.placeId })) === undefined,
// Only a link there was can go back, and only while the tour points at nothing since.
unchanged: (result, snapshot, call?: UndoCall) =>
!!call &&
linkedCategory({ packing_link: recordOf(result).previous_link }) !== undefined &&
linkedCategory(readOf(snapshot, 'get_tour_packing', { placeId: call.args.placeId })) === undefined,
},
};
@@ -1,6 +1,6 @@
import type { Described, PreviewContext, ToolArgs, ToolCards, UndoCall, UndoSnapshot } from '../card-types';
import { argId, readKey, recordOf, type Row } from '../card-values';
import { Rows, text } from '../preview-format';
import { Rows } from '../preview-format';
/**
* The smaller writes on a saved tour, each with its card and, where the answer