# A chatbot with OpenAI API
CREDITS: This project is adapted from [this repository](https://github.com/openai/openai-quickstart-node).
This is an example chatbot app based on the OpenAI API [quickstart tutorial](https://beta.openai.com/docs/quickstart). It uses the [Next.js](https://nextjs.org/) framework with [React](https://reactjs.org/). Check out the tutorial or follow the instructions below to get set up.
## Motivation
People from some regions, such as China, cannot access [ChatGPT](https://chat.openai.com/chat), so I want to build one private instance to help them out. With this instance, people can directly try ChatGPT, and do not need to login. One instance can be found [here](https://free-chat-gpt.vercel.app/).
![Alt text](screenshot.png)
## Setup
1. If you don’t have Node.js installed, [install it from here](https://nodejs.org/en/) (Node.js version >= 14.6.0 required)
2. Clone this repository
3. Navigate into the project directory
```bash
$ cd MyChatGPT
```
4. Install the requirements
```bash
$ npm install
```
5. Make a copy of the example environment variables file
On Linux systems:
```bash
$ cp .env.example .env
```
On Windows:
```powershell
$ copy .env.example .env
```
6. Add your [API key](https://beta.openai.com/account/api-keys) to the newly created `.env` file
7. Run the app
```bash
$ npm run dev
```
You should now be able to access the app at [http://localhost:3000](http://localhost:3000)! For the full context behind this example app, check out the [tutorial](https://beta.openai.com/docs/quickstart).
没有合适的资源?快使用搜索试试~ 我知道了~
这是一个基于 OpenAI API 的聊天机器人应用程序示例
共22个文件
jsx:6个
js:5个
yml:3个
需积分: 0 2 下载量 136 浏览量
2023-04-18
14:31:40
上传
评论 1
收藏 140KB ZIP 举报
温馨提示
这是一个基于 OpenAI API 的聊天机器人应用程序示例
资源推荐
资源详情
资源评论
收起资源包目录
FreeChatGPT.zip (22个子文件)
FreeChatGPT-main
pages
_document.js 341B
api
generate.js 1KB
index.js 1KB
lib
utils
useChatProps.js 2KB
components
Input.jsx 1KB
Tips.jsx 546B
ScrollToBottom.jsx 258B
Appbar.jsx 32B
SocialPanel.jsx 615B
Line.jsx 2KB
icons
SendIcon.js 390B
.github
ISSUE_TEMPLATE
feature_request.yml 611B
bug_report.yml 1010B
config.yml 348B
.env.example 15B
screenshot.png 110KB
package.json 396B
public
chatgpt.png 1KB
index.css 447B
package-lock.json 115KB
.gitignore 361B
README.md 2KB
共 22 条
- 1
资源评论
和风细动帘帷暖
- 粉丝: 3406
- 资源: 15
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功