Coder Social home page Coder Social logo

geminichatup's Introduction

Gemini ChatUp

中文

About

This project is a chat application based on the Google GeminiPro API Key, with support for responsive layout. It can retain multiple sets of conversations, and the basic parameters for each set of conversations can be set separately.

How to Use

Demo

You need to log in with an account or provide your own Gemini Pro API Key.
Developers can click to see how to deploy this feature.

Account/Password

Test Account Password
guest guest123456

Streaming Conversation

SCR-20240121-shmh

How to Deploy

Get Gemini API Key

Get API Key

Deploy to Vercel

Deploy with Vercel

Click the button to deploy to Vercel and follow the prompts to enter your Google GeminiPro API Key.

Adding User Authentication

This feature requires enabling Edge config in Vercel. Follow these steps:

  1. After the project is deployed, switch to the Storage Tab and select "New Edge Config."
    SCR-20240120-pofd

  2. In the Edge Config, switch to Projects and check if it is already associated with the current project.
    SCR-20240120-pmob

  3. Finally, switch to Items and at the bottom right, you can add usernames and passwords in JSON format by yourself.
    SCR-20240120-pmyd


Local Start

  1. Install dependencies

    npm i
    
  2. Create a new .envfile, copy the contents of .env.example into .env, and modify it with your own API Key and configuration options.


  1. Local Start
    npm run dev

Screenshots




SCR-20240104-mgmn

To Be Completed

  1. Streaming Q&A (completed)
  2. Clearing previous conversations (completed)
  3. Calculating tokens and removing excess conversations (completed)
  4. Global settings, supporting client integration with GeminiPro API (completed)
  5. Support for searching conversation content
  6. Add GeminiPro Vision API (completed)

geminichatup's People

Contributors

loo-y avatar

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

Watchers

 avatar  avatar

geminichatup's Issues

风险建议

你好,这个项目挺好的,不过部署到 Vercel 上,是不是可以考虑加一个密码验证的页面,验证不通过,不进入 Chat 页面,因为可能存在被滥用的问题,另外 Gemini 也有用量限制的。

或者在网页上提供一个输入 Key 的入口,让使用者自行输入 Key,然后保存到本地缓存中。

似乎本地运行崩溃的概率较高。

不太清楚是什么原因。本来用nohup跑的。但是似乎几个小时内就消失了。多次测试都这样。现在改成了pm2。一天下来发现pm2统计他重启了16次。服务器性能应该是满足的。也没有高负载的状态。不清楚具体原因。pm2的log记录内容不多。看了下nohup的日志。具体如下

▲ Next.js 14.0.4

warning package.json: "dependencies" has dependency "postcss" with range "8.4.28" that collides with a dependency in "devDependencies" of the same name with version "^8"
warning package.json: "dependencies" has dependency "tailwindcss" with range "3.3.3" that collides with a dependency in "devDependencies" of the same name with version "^3.3.0"
warning package.json: "dependencies" has dependency "typescript" with range "5.1.6" that collides with a dependency in "devDependencies" of the same name with version "^5"
✓ Ready in 4.2s
○ Compiling / ...
✓ Compiled / in 8.9s (2542 modules)
WARNING: Panel defaultSize prop recommended to avoid layout shift after server rendering
✓ Compiled in 2.2s (1258 modules)
○ Compiling /favicon.ico ...
✓ Compiled /favicon.ico in 1499ms (1312 modules)
○ Compiling /middleware ...
✓ Compiled /middleware in 868ms (75 modules)
○ Compiling /api/geminicontent ...
✓ Compiled /api/geminicontent in 724ms (197 modules)
Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
⨯ uncaughtException: Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
⨯ uncaughtException: Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
⨯ uncaughtException: Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
⨯ uncaughtException: Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
⨯ uncaughtException: Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
⨯ uncaughtException: Error: aborted
at abortIncoming (node:_http_server:793:17)
at socketOnClose (node:_http_server:787:3)
at Socket.emit (node:events:531:35)
at TCP. (node:net:337:12)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'ECONNRESET'
}
WARNING: Panel defaultSize prop recommended to avoid layout shift after server rendering
WARNING: Panel defaultSize prop recommended to avoid layout shift after server rendering
WARNING: Panel defaultSize prop recommended to avoid layout shift after server rendering
WARNING: Panel defaultSize prop recommended to avoid layout shift after server rendering

问了下gpt。是因为3个版本的问题么?

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.