From 2c2a8ea549f94b71feaaf2b0e3871c7e92b836d1 Mon Sep 17 00:00:00 2001 From: Da Kuang Date: Fri, 21 Apr 2023 02:24:39 -0400 Subject: [PATCH 1/2] =?UTF-8?q?Update=20the=20readme=20file=20section:=20?= =?UTF-8?q?=E5=AE=89=E8=A3=85-=E6=96=B9=E6=B3=952=EF=BC=9A=E4=BD=BF?= =?UTF-8?q?=E7=94=A8Docker?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index e606db2..14c53f9 100644 --- a/README.md +++ b/README.md @@ -133,9 +133,11 @@ python main.py - 函数插件区下拉菜单中有更多功能可供选择 ``` -## 安装-方法2:使用Docker (Linux) +## 安装-方法2:使用Docker 1. 仅ChatGPT(推荐大多数人选择) + +在 Linux 环境下 ``` sh # 下载项目 git clone https://github.com/binary-husky/chatgpt_academic.git @@ -144,11 +146,25 @@ cd chatgpt_academic 用任意文本编辑器编辑 config.py # 安装 docker build -t gpt-academic . -# 运行 +# 运行 docker run --rm -it --net=host gpt-academic ``` -2. ChatGPT+ChatGLM(需要对docker熟悉 + 读懂Dockerfile + 电脑配置够强) +在 macOS 环境下 +``` sh +# 下载项目 +git clone https://github.com/binary-husky/chatgpt_academic.git +cd chatgpt_academic +# 配置 海外Proxy 和 OpenAI API KEY +# 把 WEB_PORT 设置为一个端口固定端口 (例如 50923) +用任意文本编辑器编辑 config.py +# 安装 +docker build -t gpt-academic . +# 运行时用 -p 将容器上的端口 (例如 50923) 暴露给主机上的端口 +docker run --rm -it -p 50923:50923 gpt-academic +``` + +1. ChatGPT+ChatGLM(需要对docker熟悉 + 读懂Dockerfile + 电脑配置够强) ``` sh # 修改Dockerfile From 5f319061d7bb954954f032a66b532a56436469eb Mon Sep 17 00:00:00 2001 From: binary-husky <96192199+binary-husky@users.noreply.github.com> Date: Fri, 21 Apr 2023 15:13:51 +0800 Subject: [PATCH 2/2] Update README.md --- README.md | 21 ++++----------------- 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 14c53f9..8d77108 100644 --- a/README.md +++ b/README.md @@ -137,34 +137,21 @@ python main.py 1. 仅ChatGPT(推荐大多数人选择) -在 Linux 环境下 ``` sh # 下载项目 git clone https://github.com/binary-husky/chatgpt_academic.git cd chatgpt_academic -# 配置 海外Proxy 和 OpenAI API KEY +# 配置 “海外Proxy”, “API_KEY” 以及 “WEB_PORT” (例如50923) 等 用任意文本编辑器编辑 config.py # 安装 docker build -t gpt-academic . -# 运行 +#(最后一步-选择1)在Linux环境下,用`--net=host`更方便快捷 docker run --rm -it --net=host gpt-academic -``` - -在 macOS 环境下 -``` sh -# 下载项目 -git clone https://github.com/binary-husky/chatgpt_academic.git -cd chatgpt_academic -# 配置 海外Proxy 和 OpenAI API KEY -# 把 WEB_PORT 设置为一个端口固定端口 (例如 50923) -用任意文本编辑器编辑 config.py -# 安装 -docker build -t gpt-academic . -# 运行时用 -p 将容器上的端口 (例如 50923) 暴露给主机上的端口 +#(最后一步-选择2)在macOS/windows环境下,只能用-p选项将容器上的端口(例如50923)暴露给主机上的端口 docker run --rm -it -p 50923:50923 gpt-academic ``` -1. ChatGPT+ChatGLM(需要对docker熟悉 + 读懂Dockerfile + 电脑配置够强) +2. ChatGPT+ChatGLM(需要对Docker熟悉 + 读懂Dockerfile + 电脑配置够强) ``` sh # 修改Dockerfile