1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import { chat } from "https://esm.town/v/webup/chat";
export const chatSampleStepByStep = (async () => {
const text = `
在一个迷人的村庄里,兄妹杰克和吉尔出发去一个山顶井里打水。
他们一边唱着欢乐的歌,一边往上爬,然而不幸降临 —— 杰克绊了一块石头,从山上滚了下来,吉尔紧随其后。
虽然略有些摔伤,但他们还是回到了温馨的家中。
尽管出了这样的意外,他们的冒险精神依然没有减弱,继续充满愉悦地探索。
`;
const prompt = `
执行以下操作:
1-用一句话概括下面用三个引号括起来的文本。
2-将摘要翻译成法语。
3-在法语摘要中列出每个人名。
4-输出一个 JSON 对象,其中包含以下键:French_summary,num_names。
请用换行符分隔您的答案。"""${text}"""
`;
return await chat(prompt);
})();
Val Town is a social website to write and deploy JavaScript.
Build APIs and schedule functions from your browser.
Comments
Nobody has commented on this val yet: be the first!
October 23, 2023