Skip to content
forked from anse-app/anse

Supercharged experience for ChatGPT, DALL-E and Stable Diffusion.

License

Notifications You must be signed in to change notification settings

SkyKingL/gpt-anse

 
 

Repository files navigation

ChatGPT-API Demo v2

🍿 Live preview: https://v2.chatgpt.ddiu.me

We are working on V2 Version! Preview & more info on anse-app/chatgpt-demo#247.

Features

  • 🚀 Powerful Plugin System - Powered by Provider plugin , easy to extend AI platforms such as OpenAI, Bing ChatGPT, and also supports custom model parameters.
  • 💬 Session Record Saving - We use IndexDB to store local data, it will not be uploaded to the server, security issues are guaranteed.
  • 🎉 Multiple Session Modes - Provides different conversations modes,support Single Conversation, Continuous Conversation, OpenAI Image GenerationStable Diffusion and more.
  • 💎 Improved UI Experience - We have refactored the website UI for the previous version, optimized a lot of details, and also adapted to mobile end and dark mode.
  • 🌈 One-Click Deployment - Support one-click deployment, abandoned use environment variables, you can refer to our documentation to deploy the website to Vercel, Netlify, Docker, Node and other platforms.

Running Locally

Pre environment

  1. Node: Check that both your development environment and deployment environment are using Node v18 or later. You can use nvm to manage multiple node versions locally。
     node -v
  2. PNPM: We recommend using pnpm to manage dependencies. If you have never installed pnpm, you can install it with the following command:
     npm i -g pnpm
  3. OPENAI_API_KEY: Before running this application, you need to obtain the API key from OpenAI. You can register the API key at https://beta.openai.com/signup.

Getting Started

  1. Install dependencies
     pnpm install
  2. Run the application, the local project runs on http:https://localhost:3000/
     pnpm run dev
  3. add your OpenAI API key to the settings panel, then enjoy it!

Deploy

Deploy With Vercel

Deploy with Vercel

image

Deploy With Netlify

Deploy with Netlify

Step-by-step deployment tutorial:

  1. Fork this project,Go to https://app.netlify.com/start new Site, select the project you forked done, and connect it with your GitHub account.

image

image

  1. Select the feat/v2 branch, select the default build command and output directory, Click the Deploy Site button to start deploying the site。

image

Deploy with Docker

Docker Hub address.

Direct run

docker run -p 3000:3000 -d ddiu8081/chatgpt-demo-v2:latest

Docker compose

version: '3'
services:
  chatgpt-demo:
    image: ddiu8081/chatgpt-demo-v2:latest
    container_name: chatgpt-demo-v2
    restart: always
    ports:
      - '3000:3000'
# start
docker compose up -d
# down
docker-compose down

Deploy on more servers

Please refer to the official deployment documentation:https://docs.astro.build/en/guides/deploy

Frequently Asked Questions

Q: TypeError: fetch failed (can't connect to OpenAI Api)

A: Reference: anse-app/chatgpt-demo#34

Q: throw new TypeError(${context} is not a ReadableStream.)

A: The Node version needs to be v18 or later,reference: anse-app/chatgpt-demo#65

Q: Accelerate domestic access without the need for proxy deployment tutorial?

A: You can refer to this tutorial: anse-app/chatgpt-demo#270

Q: PWA is not working?

A: Current PWA does not support deployment on Netlify, you can choose vercel or node deployment.

Contributing

This project exists thanks to all those who contributed.

Thank you to all our supporters!🙏

img

License

MIT © ddiu8081

About

Supercharged experience for ChatGPT, DALL-E and Stable Diffusion.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 89.0%
  • CSS 5.6%
  • Astro 2.7%
  • JavaScript 2.5%
  • Dockerfile 0.2%