Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] 随便聊聊被注入了LobeHub或LobeChat的Prompt #2278

Closed
1PercentSync opened this issue Apr 29, 2024 · 13 comments · Fixed by #2289
Closed

[Bug] 随便聊聊被注入了LobeHub或LobeChat的Prompt #2278

1PercentSync opened this issue Apr 29, 2024 · 13 comments · Fixed by #2289
Labels
🐛 Bug Something isn't working | 缺陷 released

Comments

@1PercentSync
Copy link

💻 系统环境

Windows

📦 部署环境

Vercel / Zeabur / Sealos

🌐 浏览器

Edge

🐛 问题描述

image 如图,随便聊聊的prompt没有任何设置,但是它认为自己是lobe助手什么的

🚦 期望结果

No response

📷 复现步骤

No response

📝 补充信息

No response

@1PercentSync 1PercentSync added the 🐛 Bug Something isn't working | 缺陷 label Apr 29, 2024
@lobehubbot
Copy link
Member

👀 @1PercentSync

Thank you for raising an issue. We will investigate into the matter and get back to you as soon as possible.
Please make sure you have given us as much context as possible.
非常感谢您提交 issue。我们会尽快调查此事,并尽快回复您。 请确保您已经提供了尽可能多的背景信息。

@arvinxx
Copy link
Contributor

arvinxx commented Apr 29, 2024

我们在 #2086 的确注入了一些和 LobeChat 相关的prompt,看来得只有部分问题再注入才行,我晚点修一下

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


We did inject some prompts related to LobeChat in #2086. It seems that only some problems need to be injected again. I will fix it later.

@crybest
Copy link

crybest commented Apr 29, 2024

同样问题,被注入了4000多个token,这太狠了

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Same problem, more than 4,000 tokens were injected, this is too cruel

@arvinxx
Copy link
Contributor

arvinxx commented Apr 29, 2024

@crybest 哪里有4000这么多了?你是不是开了插件?我们测下来是一次 1000 左右:
image

@RubuJam
Copy link
Contributor

RubuJam commented Apr 29, 2024

我们在 #2086 的确注入了一些和 LobeChat 相关的prompt,看来得只有部分问题再注入才行,我晚点修一下

我感觉可以把src/const/guide.ts里的Initialization内容单独抽出来,作为一个准则(但感觉这么做又和用户输入预处理重合了),其余有关LobeHubLobeChat的内容放在一起,并且有个环境变量,控制是否向用户展示LobeHubLobeChat的内容

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


We did inject some prompts related to LobeChat in #2086. It seems that only some problems need to be injected again. I will fix it later.

I think we can separate Initialization in src/const/guide.ts as a guideline (but I feel that doing so overlaps with user input preprocessing), and the rest is related to LobeHub and LobeChat The contents are put together, and there is an environment variable to control whether to display the contents of LobeHub and LobeChat to the user.

@arvinxx
Copy link
Contributor

arvinxx commented Apr 29, 2024

@RubuJam

核心目的是为了解答这里的这些问题,之前测下来是发现只要注入之后的效果就挺不错的。但是忘记去测正常使用的 case 了,算是我们的失误。

image

我目前准备只针对这些问题做注入,这样估计就没啥问题了。后续这个 welcome 会再优化一下,允许用户自行配置欢迎语句和预设问题(即 #891 这个 RPFC)

@crybest
Copy link

crybest commented Apr 29, 2024

@crybest 哪里有4000这么多了?你是不是开了插件?我们测下来是一次 1000 左右: image

对,是的,我看错了

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


@crybest Where are there so many 4000? Have you turned on the plug-in? We measured it to be about 1000 at a time: image

Yes, yes, I saw it wrong

@lobehubbot
Copy link
Member

@1PercentSync

This issue is closed, If you have any questions, you can comment and reply.
此问题已经关闭。如果您有任何问题,可以留言并回复。

@lobehubbot
Copy link
Member

🎉 This issue has been resolved in version 0.151.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 Bug Something isn't working | 缺陷 released
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

5 participants