Code Monkey home page Code Monkey logo

chatchat's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

chatchat's Issues

添加全局key

能否加一个配置全局key的地方,这样即使用户不登录也可以用我提供的key与特定的模型对话?

Error [TypeError]: Failed to parse URL from https://()=>process.env.BASE_URL/api/team/info?accessCode

我创建了团队,然后应用设置服务提供商为Team,填入Team Access Code(访问码),然后对话出错,日志如下:

Error [TypeError]: Failed to parse URL from https://()=>process.env.BASE_URL/api/team/info?accessCode=******
    at context.fetch (file:///app/node_modules/next/dist/server/web/sandbox/context.js:265:38)
    at H (file:///app/.next/server/app/api/messages/route.js:22:38145)
    at <unknown> (file:///app/.next/server/app/api/messages/route.js:22:40095)
    at <unknown> (file:///app/.next/server/app/api/messages/route.js:22:45261)
    at a.with (file:///app/.next/server/app/api/messages/route.js:5:18870)
    at l.with (file:///app/.next/server/app/api/messages/route.js:5:13050)
    at l.startActiveSpan (file:///app/.next/server/app/api/messages/route.js:5:28070)
    at i.startActiveSpan (file:///app/.next/server/app/api/messages/route.js:5:28732)
    at <unknown> (file:///app/.next/server/app/api/messages/route.js:22:45113)
    at a.with (file:///app/.next/server/app/api/messages/route.js:5:18870)

我尝试BASE_URL去掉前缀(https://),NODE ENV环境变量改为:development,没有解决问题。

无法打开新会话

无法连续对话,每次问都会从头开始;
无法创建新会话;
无法保存记录。
版本:v0.0.7,之前的版本没有这个问题,使用新版本并且使用Team之后就有了。

Cannot switch to gpt-4-32k

Hi,
I got an error when I configure and switch to azure gpt-4-32k. I found that the server still use gpt-3.5-turbo instead of gpt-4-32k.

And I got the error when I refresh the webpage and start a new conversation.

Unhandled Runtime Error
Error: Text content does not match server-rendered HTML.

Warning: Text content did not match. Server: "gpt-3.5-turbo" Client: "gpt-4-32k"

See more info here: https://nextjs.org/docs/messages/react-hydration-error

image

I have checked the gpt model:
image

Thanks!

Application error: a client-side exception has occurred (see the browser console for more information).

Hello, when I try to deploy this project to vercel or any of the ones you said like railway, the issue of "Application error: a client-side exception has occurred (see the browser console for more information)" Keeps coming up. and in console it says, "Error: An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error." How to fix?

latex公式块重复输出

Screenshot_20240315_084804_com.android.chrome.png

如图,在渲染到用$$包裹的公式块时会显示一次渲染过的和未渲染完全的内容
经测试,是渲染问题不是API返回内容问题(在开启渲染用户输入内容时,自己输入公式同样可出发此bug)

Code/File page login return 404

In the code / file page the login button return 404.

image

For the upload function, it is recommended that need to be login to allow it.

Profile menu items show “404 Not Found” after latest update

After merging the latest commit, errors appear when clicking on the menu items under Profile.

For example, when I click on Profile > Record, instead of pointing me to https://[baseURL]/profile/info/record, I am directed to https://[baseURL]/profile/profile/info/record, which obviously doesn’t exist.

What has gone wrong?

File Chat - history

Hi,

Is there a way to enable referring to previous file chat conversations ? right now, if we upload file and do some Q/A and then close the app or open new conversation, we are not able to go back to previous file chat, as the chat item is not clickable. Hopefully you can consider adding this as feature.

Use ENV

Can we use Variables in the env for all the keys/models? for our own personal hosted version?

Context mode for Claude Model

Hi,

Currently there is limitation on context mode for Claude Model, the context doesnt work. Will you be able to add the context mode for Claude model. there were lots of feedback on the limitation of the Claude Documentation on implementation chat/context mode but with recent release from Vercel SDK for Claude chat implementation, i think thats fixed. it will be great to have this feature in ChatChat.

message rendering issues

Hi,
Thank you for sharing this interesting project.

I encountered an issue where "\n\n" + "number" cannot be rendered properly. I appreciate your help in addressing this problem.

image

Thanks!
Yang

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • chore(deps): update dependency @tailwindcss/typography to v0.5.12
  • chore(deps): update dependency @types/pdf-parse to v1.1.4
  • chore(deps): update dependency @types/react-speech-recognition to v3.9.5
  • chore(deps): update dependency @types/react-syntax-highlighter to v15.5.11
  • chore(deps): update dependency prettier-plugin-tailwindcss to v0.5.13
  • fix(deps): update dependency @dqbd/tiktoken to v1.0.13
  • fix(deps): update dependency @radix-ui/react-avatar to v1.0.4
  • fix(deps): update dependency @radix-ui/react-dialog to v1.0.5
  • fix(deps): update dependency @radix-ui/react-dropdown-menu to v2.0.6
  • fix(deps): update dependency @radix-ui/react-popover to v1.0.7
  • fix(deps): update dependency @vercel/speed-insights to v1.0.10
  • fix(deps): update dependency axios to v1.6.8
  • fix(deps): update dependency cmdk to v0.2.1
  • fix(deps): update dependency next-auth to v4.24.7
  • fix(deps): update dependency nodemailer to v6.9.13 (nodemailer, @types/nodemailer)
  • fix(deps): update dependency react-icons to v5.0.1
  • fix(deps): update dependency tailwindcss to v3.4.3
  • fix(deps): update nextjs monorepo to v14.1.4 (eslint-config-next, next)
  • chore(deps): update dependency @typescript-eslint/parser to v6.21.0
  • chore(deps): update dependency eslint-plugin-tailwindcss to v3.15.1
  • chore(deps): update dependency prettier to v3.2.5
  • chore(deps): update dependency webpack to v5.91.0
  • fix(deps): update dependency @vercel/analytics to v1.2.2
  • fix(deps): update dependency clsx to v2.1.0
  • fix(deps): update dependency eslint to v8.57.0
  • fix(deps): update dependency eventsource-parser to v1.1.2
  • fix(deps): update dependency jotai to v2.7.2
  • fix(deps): update dependency next-intl to v3.11.1
  • fix(deps): update dependency next-themes to ^0.3.0
  • fix(deps): update dependency typescript to v5.4.4
  • fix(deps): update prisma monorepo to v5.12.1 (@prisma/client, prisma)
  • fix(deps): update dependency cmdk to v1
  • fix(deps): update dependency eslint to v9
  • 🔐 Create all rate-limited PRs at once 🔐

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

docker-compose
docker-compose.yml
dockerfile
Dockerfile
github-actions
.github/workflows/docker-image.yml
  • actions/checkout v4
  • docker/setup-buildx-action v3
  • docker/login-action v3
  • docker/build-push-action v3
  • docker/login-action v3
  • docker/build-push-action v3
.github/workflows/sync.yml
  • actions/checkout v4
  • aormsby/Fork-Sync-With-Upstream-action v3.4
npm
package.json
  • @dqbd/tiktoken ^1.0.7
  • @next-auth/prisma-adapter ^1.0.7
  • @prisma/client ^5.6.0
  • @radix-ui/react-accordion ^1.1.2
  • @radix-ui/react-avatar ^1.0.3
  • @radix-ui/react-checkbox ^1.0.4
  • @radix-ui/react-dialog ^1.0.4
  • @radix-ui/react-dropdown-menu ^2.0.5
  • @radix-ui/react-label ^2.0.2
  • @radix-ui/react-popover ^1.0.6
  • @radix-ui/react-select ^1.2.2
  • @radix-ui/react-separator ^1.0.3
  • @radix-ui/react-slider ^1.1.2
  • @radix-ui/react-slot ^1.0.2
  • @radix-ui/react-switch ^1.0.3
  • @radix-ui/react-tabs ^1.0.4
  • @tippyjs/react ^4.2.6
  • @vercel/analytics ^1.1.1
  • @vercel/speed-insights ^1.0.1
  • autoprefixer 10.4.16
  • axios ^1.6.2
  • cheerio ^1.0.0-rc.12
  • class-variance-authority ^0.7.0
  • clsx ^2.0.0
  • cmdk ^0.2.0
  • eslint ^8.56.0
  • eslint-config-next 14.1.0
  • eventsource-parser ^1.0.0
  • formidable ^3.5.1
  • jotai ^2.6.0
  • next 14.1.0
  • next-auth ^4.24.5
  • next-intl ^3.1.4
  • next-pwa ^5.6.0
  • next-themes ^0.2.1
  • nodemailer ^6.9.5
  • pdf-parse ^1.1.1
  • postcss 8.4.33
  • react 18.2.0
  • react-dom 18.2.0
  • react-hot-toast ^2.4.1
  • react-icons ^5.0.0
  • react-markdown ^8.0.7
  • react-speech-recognition ^3.10.0
  • react-spinners ^0.13.8
  • react-syntax-highlighter ^15.5.0
  • react-textarea-autosize ^8.5.3
  • rehype-katex ^6.0.3
  • remark-gfm ^3.0.1
  • remark-math ^5.1.1
  • tailwind-merge ^1.14.0
  • tailwindcss 3.4.1
  • tailwindcss-animate ^1.0.7
  • typescript 5.3.3
  • @tailwindcss/typography ^0.5.10
  • @types/formidable ^3.4.3
  • @types/node 20.10.7
  • @types/nodemailer ^6.4.10
  • @types/pdf-parse ^1.1.1
  • @types/react 18.2.47
  • @types/react-dom 18.2.18
  • @types/react-speech-recognition ^3.9.2
  • @types/react-syntax-highlighter ^15.5.7
  • @typescript-eslint/parser ^6.19.1
  • eslint-plugin-tailwindcss ^3.14.1
  • prettier ^3.1.0
  • prettier-plugin-tailwindcss ^0.5.7
  • prisma ^5.6.0
  • webpack ^5.88.2

  • Check this box to trigger a request for Renovate to run again on this repository

[Q&A] 可能遇到的问题

可能遇到的问题

Application error: a client-side exception has occurred (see the browser console for more information).

未完整填写所有所需环境变量导致,请看 https://docs.okis.dev/zh-CN/chat/deployment/

输出内容杂乱

这通常是相关模型不完善导致的。

所以你可能看到以下情况:

CleanShot 2023-05-02 at 03 50 18@2x

这是因为模型返回的内容本身如下:
CleanShot 2023-05-02 at 03 49 59@2x
CleanShot 2023-05-02 at 03 33 01@2x

抓取网页(返回成功,但是生成 AI 内容)失败

基本上是页面投喂的内容超过了当前 AI 模型最大的 token 限制

搜索配置

需要获取 Google Programmable Search Engine ID 和 API Key,分别在 https://programmablesearchengine.google.com/controlpanel/allhttps://developers.google.com/custom-search/v1/introduction

vercel部署需要设置环境变量吗?

如题,未设置环境变量部署后,打开vercel网页显示

Application error: a client-side exception has occurred (see the browser console for more information).
Digest: 908203380

不知道是不是没设置环境变量的原因!

[Feature]新增自动语音回复

能否添加一个自动语言,每次ai回答完之后自动语音回复,另外添加代码高量与语音回复跳过代码?

is it possible to provide the Source URL for reference ?

非常感谢作者提供了这个软件

我的场景是这个样子的,我们拥有一款非常复杂的MIT 协议的开源运维平台运维软件,用户手册非常的厚,全部已经放在公网了。https://bk.tencent.com/docs/

由于产品过于复杂, 我需要一个chatbot 去为用户提供技术支持,因为产品比较复杂, 光文字描述也不能满足用户支持的, 用户需要查看文档中的图片

我希望chatbot在回答的问题时候,可以顺带提供相关的文档url作为参考,用户可以根据需求, 点到相关连接中查看更细节的信息。

具体可以参考 , https://astro-labs.app/docs 下面的source, 或者 new bing

Nice to have 功能:

  1. 预览, 用户在不需要点击链接的时候后, 就能预览相关链接内容的相关部分,帮助用户快速判断内容是否需要。 (这个是上面chatgpt-pgvector项目没有做好的地方)

  2. 提供选项,可以右侧直接是提取完关键字的搜索结果

500 Error after latest merge

The docker log shows the following:

Error: Cannot find module 'webpack'
Require stack:

  • /app/node_modules/workbox-webpack-plugin/build/generate-sw.js
  • /app/node_modules/workbox-webpack-plugin/build/index.js
  • /app/node_modules/next-pwa/index.js
  • /app/next.config.js
    at Module._resolveFilename (node:internal/modules/cjs/loader:1077:15)
    at /app/node_modules/next/dist/server/require-hook.js:185:36
    at Module._load (node:internal/modules/cjs/loader:922:27)
    at Module.require (node:internal/modules/cjs/loader:1143:19)
    at require (node:internal/modules/cjs/helpers:110:18)
    at Object. (/app/node_modules/workbox-webpack-plugin/build/generate-sw.js:18:35)
    at Module._compile (node:internal/modules/cjs/loader:1256:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Module._load (node:internal/modules/cjs/loader:960:12) {
    code: 'MODULE_NOT_FOUND',
    requireStack: [
    '/app/node_modules/workbox-webpack-plugin/build/generate-sw.js',
    '/app/node_modules/workbox-webpack-plugin/build/index.js',
    '/app/node_modules/next-pwa/index.js',
    '/app/next.config.js'
    ]
    }

Is there a fix for the error?

Azure OpenAI env variables missing?

Hi! This is a fudging awesome piece of software you've written. Thank you.

I've been trying to spin up locally since I need to perform testing across different providers (Cohere, Azure, etc).

I cannot seem to find environment variables for Azure. Only OpenAI directly.

Could you please update documentation to show how? :)

is it possible to edit messages?

Dear all,

Thanks for sharing such a useful tool.

May I ask if there are any plans to support message editing for this project? ChatGPT/ChatWithGPT has similar support, and I believe this feature is also very important for users.

Thanks!

New user signup fails

On the ../register page, after entering an email address, clicking on the signup button produces no effect, and no email is sent.

Below is my database log:

2023-05-04 23:21:16.764 HKT [3383] ERROR:  relation "public.users" does not exist at character 344
2023-05-04 23:21:16.764 HKT [3383] STATEMENT:  SELECT "public"."users"."id", "public"."users"."platform", "public"."users"."name", "public"."users"."email", "public"."users"."emailVerified", "public"."users"."image", "public"."users"."created_at", "public"."users"."updated_at", "public"."users"."defaultProvider", "public"."users"."openAIKey", "public"."users"."allowRecordCloudSync" FROM "public"."users" WHERE ("public"."users"."email" = $1 AND 1=1) LIMIT $2 OFFSET $3

Below is my docker log:

[next-auth][error][adapter_error_getUserByEmail] 
https://next-auth.js.org/errors#adapter_error_getuserbyemail 
Invalid `prisma.user.findUnique()` invocation:
The table `public.users` does not exist in the current database. {
  message: '\n' +
    'Invalid `prisma.user.findUnique()` invocation:\n' +
    '\n' +
    '\n' +
    'The table `public.users` does not exist in the current database.',
  stack: 'Error: \n' +
    'Invalid `prisma.user.findUnique()` invocation:\n' +
    '\n' +
    '\n' +
    'The table `public.users` does not exist in the current database.\n' +
    '    at pn.handleRequestError (/app/node_modules/@prisma/client/runtime/library.js:176:6477)\n' +
    '    at pn.handleAndLogRequestError (/app/node_modules/@prisma/client/runtime/library.js:176:5907)\n' +
    '    at pn.request (/app/node_modules/@prisma/client/runtime/library.js:176:5786)\n' +
    '    at async t._request (/app/node_modules/@prisma/client/runtime/library.js:179:10484)',
  name: 'Error'
}
Error: 
Invalid `prisma.user.findUnique()` invocation:
The table `public.users` does not exist in the current database.
    at pn.handleRequestError (/app/node_modules/@prisma/client/runtime/library.js:176:6477)
    at pn.handleAndLogRequestError (/app/node_modules/@prisma/client/runtime/library.js:176:5907)
    at pn.request (/app/node_modules/@prisma/client/runtime/library.js:176:5786)
    at async t._request (/app/node_modules/@prisma/client/runtime/library.js:179:10484) {
  name: 'GetUserByEmailError',
  code: 'P2021'

Messages are not coming

Hello, when i try out the ai and say like hello or hi or anything else, it doesnt respond with anything.
image

Support for Claude 3?

Hi! I could only find the option to select claude 2 api Is it possible to add support for Claude 3?

Possible to add the support for vector DB/Embedding

Hi,

I tried testing some PDF file, but when i wanted to query/ask it give error that the context window limit is reached, so i believe you are adding the whole content of the file into the prompt, i can see that this will be helpful with the Claude 100K context window, but for the Chatgpt 4 at the moment this is limitation.

Is it possible to add support for the vector DB such as Supabase which will store the embedding and then it will be queried to retrieve the most relevant chunk(s) based on the user query.

File Chat - Option to disable default summary prompt

Hi,
How can we disable the default setting for the file chat, that will summarize the doc you upload. i am testing it with big text file and upon upload, i have to them wait longer for the file to generate summary which takes time and tokens which is not needed at all. I would prefer to have an option where i can just upload file and then i get some confirmation that file is upload and ready for QA.

Hope this can be done.

打开网页出现错误

系统:Arch linux
浏览器:Firefox 112.0.2
部署方式:Vercel
出现错误:

Application error: a client-side exception has occurred (see the browser console for more information).

Digest: 908203380

控制台报错:

Error: An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error.
8139-47a3c092b3f12070.js:1:3452
    NextJS 61
        error
        la
        callback
        nh
        nm
        aw
        aE
        aA
        aE
        aA
        aE
        aA
        aE
        aA
        aE
        aA
        aE
        aA
        aE
        aA
        aE
        aA
        aE
        oQ
        oQ
        oz
        oE
        j
        C
        (异步:EventHandlerNonNull)
    24248
        c
        26183
        c
        42614
        c
        8431
        c
        82672
        c
        93488
        c
        35456
        c
        50406
        c
        70566
        c
        20520
        c
        47858
        c
        17732
        r
        r
        17732
        c
        n
        <anonymous>
        O
        r
        <anonymous>

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.