diff --git a/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.spec.ts b/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.spec.ts index 774807a..fc4ed64 100644 --- a/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.spec.ts +++ b/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.spec.ts @@ -65,6 +65,7 @@ function makeCtx( return { userId: 'user_1', session, + autoExecuted: false, // tour-announce is propose-only; never auto-executed. platformApi: { get: vi.fn(), post: vi.fn() }, blocklist: { list: async (kind?: BlocklistKind) => diff --git a/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.ts b/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.ts index f3e51b7..425e73d 100644 --- a/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.ts +++ b/@platform/codebase/@features/bookings-tryst/ai-core/src/adapter/tour-announce/index.ts @@ -24,6 +24,7 @@ import { type AdapterContext, type BlocklistEntry, type GateRejection, + type PrecheckContext, type SurfaceAdapterAction, gateK3cGovtName, gateK3fAccommodationName, @@ -95,7 +96,7 @@ function forbiddenNames(entries: readonly BlocklistEntry[]): string[] { const action: SurfaceAdapterAction = { action: 'tour-announce', schema, - async precheck(input: Input, ctx: AdapterContext) { + async precheck(input: Input, ctx: PrecheckContext) { const rejections: GateRejection[] = []; // Tier slot-ceiling check (deterministic, no I/O). @@ -139,7 +140,7 @@ const action: SurfaceAdapterAction = { targetKind: 'surface_tour', stakes: 'medium', confidence: 1, - autoExecuted: false, + autoExecuted: ctx.autoExecuted, outcome: { legs: announced }, }); @@ -153,4 +154,6 @@ export const descriptor: ActionDescriptor = { verb: 'tour-announce', action: action as SurfaceAdapterAction, autoExecutable: false, + auditTargetKind: 'surface_tour', + auditStakes: 'medium', };