mirror of
https://github.com/kou029w/daraz-llm.git
synced 2025-01-18 08:05:12 +00:00
Q:
and A:
This commit is contained in:
parent
fcb934e1c7
commit
8465393e1d
1 changed files with 3 additions and 3 deletions
|
@ -31,9 +31,9 @@ const app = new App({ token, receiver });
|
||||||
|
|
||||||
// required app_mentions:read chat:write
|
// required app_mentions:read chat:write
|
||||||
app.event("app_mention", async ({ event, say }) => {
|
app.event("app_mention", async ({ event, say }) => {
|
||||||
const prompt = `語尾を「にゃん」にして質問にこたえる\n${event.text
|
const prompt = `語尾を「にゃん」にして質問にこたえる
|
||||||
.replace(/<@[0-9A-Z]+>/, "")
|
Q:${event.text.replace(/^<@[0-9A-Z]+>/, "").trim()}
|
||||||
.trim()}\n`;
|
A:`;
|
||||||
const text = await gpt(prompt);
|
const text = await gpt(prompt);
|
||||||
await say(text);
|
await say(text);
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Reference in a new issue