@curless/hotel-storefront 0.19.2 → 0.21.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"surface.d.ts","sourceRoot":"","sources":["../src/surface.ts"],"names":[],"mappings":"AACA,OAAO,EAAa,KAAK,aAAa,EAAE,MAAM,YAAY,CAAC;AAY3D;;;;;;;;;GASG;AACH,eAAO,MAAM,iBAAiB,GAAI,OAAO,aAAa,KAAG,MA6ExD,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,SAAS,GAAI,CAAC,SAAS;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAA;CAAE,EACzE,OAAO,SAAS,CAAC,EAAE,EACnB,eAAe,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACtC,SAAS,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAClD,YAAW,WAAW,CAAC,MAAM,CAAa;;;;;;;;;;;;;;;KAexC,CAAC;AAEL;;;;;GAKG;AACH,eAAO,MAAM,UAAU;;;CAIb,CAAC;AAEX,6DAA6D;AAC7D,eAAO,MAAM,aAAa,GAAI,OAAO,aAAa,KAAG,WAAW,CAAC,MAAM,CAkBnE,CAAC"}
1
+ {"version":3,"file":"surface.d.ts","sourceRoot":"","sources":["../src/surface.ts"],"names":[],"mappings":"AACA,OAAO,EAAa,KAAK,aAAa,EAAE,MAAM,YAAY,CAAC;AAY3D;;;;;;;;;GASG;AACH,eAAO,MAAM,iBAAiB,GAAI,OAAO,aAAa,KAAG,MAuFxD,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,SAAS,GAAI,CAAC,SAAS;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAA;CAAE,EACzE,OAAO,SAAS,CAAC,EAAE,EACnB,eAAe,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACtC,SAAS,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAClD,YAAW,WAAW,CAAC,MAAM,CAAa;;;;;;;;;;;;;;;KAexC,CAAC;AAEL;;;;;GAKG;AACH,eAAO,MAAM,UAAU;;;CAIb,CAAC;AAEX,6DAA6D;AAC7D,eAAO,MAAM,aAAa,GAAI,OAAO,aAAa,KAAG,WAAW,CAAC,MAAM,CAkBnE,CAAC"}
package/dist/surface.js CHANGED
@@ -79,7 +79,17 @@ export const buildInstructions = (brand) => {
79
79
  // day-by-day plan needs a base, so asked to plan a city with no hotel
80
80
  // chosen, the model listed four and asked on one run and proposed one on
81
81
  // the next (2026-09-18). Neither is wrong; flipping between them is.
82
- `A day-by-day plan needs a ${v.noun} to be based at. When the guest has not chosen one, list them and ask which - that choice is theirs. Once they have, ${t.itinerary} draws the days.`,
82
+ //
83
+ // ⚠️ SETTLED ON PROPOSING ONE, IN ONE CARD (robin, 2026-09-29: 「这个行程推荐
84
+ // 问题很大,会发一堆东西,和 claude 的行程推荐不一样」). "Plan Shanghai, 1-7
85
+ // January" drew a list, two hotels, a comparison and then a timeline the
86
+ // model drew itself - five cards, four of them research. A plan is the one
87
+ // card; the pick is the model's, said as a pick, with the other there.
88
+ `A day-by-day plan needs a ${v.noun} to be based at. When the guest asked for a plan without naming one, pick the one that fits what they said, say in one sentence why, and name one alternative in a sentence; the plan is where they see your pick, and nothing on it is booked, so the choice is still theirs.`,
89
+ // ⚠️ ONE PLAN, ONE CARD. Each call to a tool here draws a card, so looking
90
+ // hotels up before planning put them all above the plan; and a timeline the
91
+ // model draws itself is a second, unchecked copy of the plan beside ours.
92
+ `A plan is ONE ${t.itinerary} call: no ${t.listHotels}, ${t.getHotel} or ${t.compare} before it, since each of them draws its own card above the plan, and it reads every price itself. Put the day's moments in each day's \`plan\` - when, and what - and the ${v.noun} in its \`items\`. The card is the plan: do not draw a timeline, a table or another picture of the same days yourself.`,
83
93
  // ⚠️ THE PLAN'S SHAPE IS ITS NIGHTS. The server reads a hotel named on
84
94
  // consecutive days as one stay of that many nights - so a hotel left off
85
95
  // the second of two nights is a one-night stay on the card.
@@ -1 +1 @@
1
- {"version":3,"file":"surface.js","sourceRoot":"","sources":["../src/surface.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AACxC,OAAO,EAAE,SAAS,EAAsB,MAAM,YAAY,CAAC;AAE3D,+EAA+E;AAC/E,yEAAyE;AACzE,EAAE;AACF,8EAA8E;AAC9E,gFAAgF;AAChF,8EAA8E;AAC9E,gFAAgF;AAChF,gFAAgF;AAChF,4CAA4C;AAE5C;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,KAAoB,EAAU,EAAE;IAChE,MAAM,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,GAAG,KAAK,CAAC;IACrC,MAAM,YAAY,GAAG,KAAK,CAAC,MAAM,CAAC,OAAO,EAAE,IAAI,KAAK,QAAQ,CAAC;IAC7D,OAAO;QACL,GAAG,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,UAAU,mDAAmD,CAAC,CAAC,UAAU,+GAA+G;QACxM,oBAAoB,CAAC,CAAC,KAAK,UAAU,CAAC,CAAC,IAAI,2GAA2G;QACtJ,2EAA2E;QAC3E,GAAG,CAAC,CAAC,CAAC,IAAI;YACR,CAAC,CAAC;gBACE,MAAM,SAAS,4FAA4F;aAC5G;YACH,CAAC,CAAC,EAAE,CAAC;QACP,4EAA4E;QAC5E,uEAAuE;QACvE,kEAAkE;QAClE,yEAAyE;QACzE,yEAAyE;QACzE,qDAAqD;QACrD,oBAAoB,CAAC,CAAC,UAAU,4OAA4O,CAAC,CAAC,UAAU,2XAA2X,CAAC,CAAC,UAAU,iKAAiK,CAAC,CAAC,OAAO,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CA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KAAoB,EAAuB,EAAE,CACzE,IAAI,GAAG,CAAC;IACN,KAAK,CAAC,KAAK,CAAC,SAAS;IACrB,KAAK,CAAC,KAAK,CAAC,QAAQ;IACpB,KAAK,CAAC,KAAK,CAAC,SAAS;IACrB,KAAK,CAAC,KAAK,CAAC,cAAc;IAC1B,KAAK,CAAC,KAAK,CAAC,mBAAmB;IAC/B,KAAK,CAAC,KAAK,CAAC,aAAa;IACzB,0EAA0E;IAC1E,8DAA8D;IAC9D,KAAK,CAAC,KAAK,CAAC,YAAY;IACxB,KAAK,CAAC,KAAK,CAAC,aAAa;IACzB,KAAK,CAAC,KAAK,CAAC,aAAa;IACzB,0CAA0C;IAC1C,KAAK,CAAC,KAAK,CAAC,UAAU;IACtB,0EAA0E;IAC1E,8BAA8B;IAC9B,KAAK,CAAC,KAAK,CAAC,SAAS;CACtB,CAAC,CAAC"}
package/dist/tools.d.ts CHANGED
@@ -33,7 +33,7 @@ export declare const buildTools: (n: ToolNames, v: Vocabulary) => readonly [{
33
33
  };
34
34
  readonly limit: {
35
35
  readonly type: "number";
36
- readonly description: "How many to return, 1 to 50. Default 20";
36
+ readonly description: "How many to return, 1 to 50. Default 12";
37
37
  };
38
38
  readonly offset: {
39
39
  readonly type: "number";
@@ -539,7 +539,7 @@ export declare const buildTools: (n: ToolNames, v: Vocabulary) => readonly [{
539
539
  };
540
540
  }, {
541
541
  readonly name: `show_${string}itinerary`;
542
- readonly description: `A day-by-day plan as one card: each day carries its own label, an optional note, and the ${string} and add-ons attached to it, with their details filled in from their own records. Each item is marked with whether it is in the trip or only in the plan, and the card says how many of each. Nothing is added to the trip.`;
542
+ readonly description: `A day-by-day plan as one card: each day carries its own label, an optional note, the moments of the day in order, and the ${string} and add-ons attached to it, with their details filled in from their own records - a ${string} with its photograph and, given dates, the price of its nights. Each stay is marked with whether it is booked, in the trip or only in the plan, and the card says how many of each. Nothing is added to the trip.`;
543
543
  readonly annotations: {
544
544
  readonly title: string;
545
545
  readonly readOnlyHint: true;
@@ -589,6 +589,29 @@ export declare const buildTools: (n: ToolNames, v: Vocabulary) => readonly [{
589
589
  readonly maxItems: 6;
590
590
  readonly description: `${string} and add-ons for that day, by name or id`;
591
591
  };
592
+ readonly plan: {
593
+ readonly type: "array";
594
+ readonly maxItems: 5;
595
+ readonly description: "The day in order, in your own words: when, and what happens then. Nothing in it is booked or priced";
596
+ readonly items: {
597
+ readonly type: "object";
598
+ readonly properties: {
599
+ readonly time: {
600
+ readonly type: "string";
601
+ readonly description: "When in the day, e.g. \"Afternoon\" or \"19:00\"";
602
+ };
603
+ readonly what: {
604
+ readonly type: "string";
605
+ readonly description: "What happens then, in a few words";
606
+ };
607
+ readonly note: {
608
+ readonly type: "string";
609
+ readonly description: "One line more, optional";
610
+ };
611
+ };
612
+ readonly required: readonly ["what"];
613
+ };
614
+ };
592
615
  };
593
616
  readonly required: readonly ["label"];
594
617
  };
@@ -1 +1 @@
1
- {"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../src/tools.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAI7C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAahD,OAAO,EAGL,KAAK,SAAS,EAGf,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAYV,eAAe,EAIhB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAa,KAAK,UAAU,EAAE,MAAM,YAAY,CAAC;AAkExD,eAAO,MAAM,UAAU,GAAI,GAAG,SAAS,EAAE,GAAG,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AAM,QAAQ,EACd,MAAM,MAAM,EACZ,SAAS,OAAO,EAChB,KAAK,WAAW,KACf,OAAO,CAAC,UAAU,CAMpB,CAAC"}
package/dist/tools.js CHANGED
@@ -1,9 +1,9 @@
1
- import { LASTING_REQUESTS, MAX_PAGE, REQUEST_KINDS, REQUEST_NOTE_MAX } from './backend.js';
1
+ import { DEFAULT_PAGE, LASTING_REQUESTS, MAX_PAGE, REQUEST_KINDS, REQUEST_NOTE_MAX, } from './backend.js';
2
2
  import { isDay, nights as nightsBetween } from './dates.js';
3
3
  import { FACILITIES } from './facilities.js';
4
4
  import { DESCRIPTION_MAX, POLICY_MAX, hotelText } from './fence.js';
5
5
  import { formatMoney, money, multiplyMoney, toMinor } from './money.js';
6
- import { MAX_COMPARED, MAX_CONS, MAX_DAYS, MAX_ITEMS_PER_DAY, MAX_PROS, buildItinerary, compareHotels, } from './present.js';
6
+ import { MAX_COMPARED, MAX_CONS, MAX_DAYS, MAX_ITEMS_PER_DAY, MAX_MOMENTS, MAX_PROS, buildItinerary, compareHotels, } from './present.js';
7
7
  import { regionOf } from './regions.js';
8
8
  import { MAX_EXTRA_QUANTITY, MAX_ROOMS_PER_LINE, clampCount, tripKey, } from './trip.js';
9
9
  import { DEMO_NOTE } from './vocab.js';
@@ -100,7 +100,7 @@ export const buildTools = (n, v) => {
100
100
  },
101
101
  limit: {
102
102
  type: 'number',
103
- description: `How many to return, 1 to ${MAX_PAGE}. Default 20`,
103
+ description: `How many to return, 1 to ${MAX_PAGE}. Default ${DEFAULT_PAGE}`,
104
104
  },
105
105
  offset: {
106
106
  type: 'number',
@@ -425,7 +425,7 @@ export const buildTools = (n, v) => {
425
425
  },
426
426
  {
427
427
  name: n.itinerary,
428
- description: `A day-by-day plan as one card: each day carries its own label, an optional note, and the ${v.nounPlural} and add-ons attached to it, with their details filled in from their own records. Each item is marked with whether it is in the trip or only in the plan, and the card says how many of each. Nothing is added to the trip.`,
428
+ description: `A day-by-day plan as one card: each day carries its own label, an optional note, the moments of the day in order, and the ${v.nounPlural} and add-ons attached to it, with their details filled in from their own records - a ${v.noun} with its photograph and, given dates, the price of its nights. Each stay is marked with whether it is booked, in the trip or only in the plan, and the card says how many of each. Nothing is added to the trip.`,
429
429
  annotations: reads(`Lay out a ${v.brand} itinerary`, open),
430
430
  inputSchema: {
431
431
  type: 'object',
@@ -449,6 +449,23 @@ export const buildTools = (n, v) => {
449
449
  maxItems: MAX_ITEMS_PER_DAY,
450
450
  description: `${v.nounPlural} and add-ons for that day, by name or id`,
451
451
  },
452
+ plan: {
453
+ type: 'array',
454
+ maxItems: MAX_MOMENTS,
455
+ description: 'The day in order, in your own words: when, and what happens then. Nothing in it is booked or priced',
456
+ items: {
457
+ type: 'object',
458
+ properties: {
459
+ time: {
460
+ type: 'string',
461
+ description: 'When in the day, e.g. "Afternoon" or "19:00"',
462
+ },
463
+ what: { type: 'string', description: 'What happens then, in a few words' },
464
+ note: { type: 'string', description: 'One line more, optional' },
465
+ },
466
+ required: ['what'],
467
+ },
468
+ },
452
469
  },
453
470
  required: ['label'],
454
471
  },
@@ -1829,7 +1846,7 @@ const answerTool = async (deps, name, rawArgs, ctx) => {
1829
1846
  // host has no card at all cannot tap the one it tells them to tap. The
1830
1847
  // count and the name of the next step say the same thing everywhere.
1831
1848
  more > 0
1832
- ? `— ${offset ? `${offset + 1} to ${offset + hotels.length}` : hotels.length} in this answer and ${more} more. A city or a country narrows it; \`offset\` ${offset + hotels.length} is the next page.`
1849
+ ? `— ${offset ? `${offset + 1} to ${offset + hotels.length}` : hotels.length} in this answer and ${more} more. A city, a country or a filter narrows it; \`offset\` ${offset + hotels.length} is the next page.`
1833
1850
  : '',
1834
1851
  ...priceNotes,
1835
1852
  widened?.found ? `Nothing matched ${widened.from}, so this is ${widened.to}.` : '',
@@ -2605,11 +2622,13 @@ const answerTool = async (deps, name, rawArgs, ctx) => {
2605
2622
  label: str(d.label),
2606
2623
  note: typeof d.note === 'string' ? d.note : undefined,
2607
2624
  items: d.items ?? [],
2625
+ ...(Array.isArray(d.plan) ? { plan: d.plan } : {}),
2608
2626
  })), {
2609
2627
  title: str(args.title),
2610
2628
  stay: asStay(args),
2611
2629
  trip: deps.trips.read(key),
2612
2630
  bookings: await deps.backend.listBookings(identity(deps, ctx, key, args), 50),
2631
+ who: identity(deps, ctx, key),
2613
2632
  });
2614
2633
  if (plan.days.length === 0) {
2615
2634
  return {