Mishig commited on
Commit
13489e8
1 Parent(s): ce3e193

[Fix] small fixes in websearch generateQuery (#727)

Browse files
src/lib/server/websearch/generateQuery.ts CHANGED
@@ -40,7 +40,7 @@ Current Question: What about Mexico?
40
  content: `Previous questions:
41
  - When is the next formula 1 grand prix?
42
 
43
- Current Question: Where is it being hosted ?`,
44
  },
45
  {
46
  from: "assistant",
@@ -54,12 +54,12 @@ Current Question: Where is it being hosted ?`,
54
  from: "assistant",
55
  content: "Epson F2270 DTG printer printhead",
56
  },
57
- { from: "user", content: "What were the news yesterday ?" },
58
  {
59
  from: "assistant",
60
  content: `news ${format(new Date(Date.now() - 864e5), "MMMM d, yyyy")}`,
61
  },
62
- { from: "user", content: "What is the current weather in Paris ?" },
63
  { from: "assistant", content: `weather in Paris ${currentDate}` },
64
  {
65
  from: "user",
@@ -69,7 +69,7 @@ Current Question: Where is it being hosted ?`,
69
  .map(({ content }) => `- ${content}`)
70
  .join("\n")}`
71
  : "") +
72
- "\n\nCurrent Question:" +
73
  lastMessage.content,
74
  },
75
  ];
 
40
  content: `Previous questions:
41
  - When is the next formula 1 grand prix?
42
 
43
+ Current Question: Where is it being hosted?`,
44
  },
45
  {
46
  from: "assistant",
 
54
  from: "assistant",
55
  content: "Epson F2270 DTG printer printhead",
56
  },
57
+ { from: "user", content: "What were the news yesterday?" },
58
  {
59
  from: "assistant",
60
  content: `news ${format(new Date(Date.now() - 864e5), "MMMM d, yyyy")}`,
61
  },
62
+ { from: "user", content: "What is the current weather in Paris?" },
63
  { from: "assistant", content: `weather in Paris ${currentDate}` },
64
  {
65
  from: "user",
 
69
  .map(({ content }) => `- ${content}`)
70
  .join("\n")}`
71
  : "") +
72
+ "\n\nCurrent Question: " +
73
  lastMessage.content,
74
  },
75
  ];