Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
166 commits
Select commit Hold shift + click to select a range
00ade41
feat: 添加 Prompt 模板和 Prompt 商店支持 (#268)
Nothing1024 Mar 11, 2023
c0a1b56
feat: 设置添加关闭按钮
Chanzhaoyu Mar 11, 2023
6b8ba63
chore: format
Chanzhaoyu Mar 11, 2023
461d70a
chore: 2.10.4
Chanzhaoyu Mar 11, 2023
cf03b65
chore: cover
Chanzhaoyu Mar 11, 2023
84a19aa
fix: 更新JSON导入检查 (#523)
Nothing1024 Mar 12, 2023
379bbcd
feat: Improve zh-TW locale (#511)
PeterDaveHello Mar 12, 2023
86d720e
fix: cors in auth_secret_key model (#499)
yi-ge Mar 12, 2023
a4cfd0c
fix: 修改最大行数与官方保持一致 (#502)
yi-ge Mar 12, 2023
bc5e835
feat: support linux command line proxy standard (#308)
whatwewant Mar 12, 2023
7bebee2
fix: Prompt商店在线导入可以导入两种recommend.json里提到的模板 (#516) (#521)
simonwu53 Mar 12, 2023
de6632d
feat: 仓库添加翻译
Chanzhaoyu Mar 12, 2023
af76b89
feat: 仓库查询筛选
Chanzhaoyu Mar 12, 2023
0a9f9b6
feat: 调整界面
Chanzhaoyu Mar 12, 2023
f4be5b9
chore: update deps
Chanzhaoyu Mar 12, 2023
8a0cb90
feat: improve zh-TW locale, translate new strings (#542)
PeterDaveHello Mar 13, 2023
73bf8c0
feat: 语言设定改为下拉框选择
Chanzhaoyu Mar 13, 2023
0481726
feat: 修改 Prompt Store 移动端样式
Chanzhaoyu Mar 13, 2023
41ddc6a
chore: docs change
Chanzhaoyu Mar 13, 2023
db502e1
feat: 权限输入框改为密码类型
Chanzhaoyu Mar 13, 2023
efc9e81
fix: 清空上下文时不应该重置会话标题
Chanzhaoyu Mar 13, 2023
b288cd6
chore: docs change
Chanzhaoyu Mar 13, 2023
6cd1682
chore: optimize dockerfile to speed up building and reduce docker ima…
whatwewant Mar 13, 2023
cf788b1
chore: v2.10.5
Chanzhaoyu Mar 13, 2023
3a1466b
fix: 修复导入、导出错误
Chanzhaoyu Mar 14, 2023
25692f8
fix: inverted parameter for before each function (#585)
pdsuwwz Mar 15, 2023
c797ff5
fix: :bug: fix scroll bar style (#617)
haydenull Mar 16, 2023
1411c45
fix: typo (#636)
lizhongyuan3 Mar 17, 2023
951e9d8
perf: 优化移动端 prompt 商店样式 (#608)
CornerSkyless Mar 17, 2023
0b13846
chore: extract proxy setup code into reusable function (#583)
kirklin Mar 17, 2023
b3cfe7a
perf: 记录上下文设定保存到本地
Chanzhaoyu Mar 17, 2023
2ad7567
perf: 优化部份判断
Chanzhaoyu Mar 17, 2023
116ed7b
docs: 移除 docker-compose.yml 省略
Chanzhaoyu Mar 17, 2023
e46d368
feat: show api balance (#582)
pzcn Mar 17, 2023
c555289
chore: update deps and lint fix
Chanzhaoyu Mar 17, 2023
9572484
feat: session 返回接口方式做显示判断
Chanzhaoyu Mar 17, 2023
a8e9a24
fix: highlight.js 控制台兼容性警告
Chanzhaoyu Mar 17, 2023
71c5a88
chore: v2.10.6
Chanzhaoyu Mar 17, 2023
95ce026
fix: 回退 chatgpt 版本导致的代理失效
Chanzhaoyu Mar 17, 2023
560378f
fix: 添加 usingContext 缺省
Chanzhaoyu Mar 17, 2023
8fad91a
chore: v2.10.7
Chanzhaoyu Mar 17, 2023
08b5772
feat: 查询余额使用 API_BASE_URL 参数
Chanzhaoyu Mar 17, 2023
d422a80
feat: 渲染的链接新窗口打开
Chanzhaoyu Mar 17, 2023
d1c15f5
perf: config 接口添加权限验证
Chanzhaoyu Mar 19, 2023
f1584b6
fix: 手动重置异常的 loading
Chanzhaoyu Mar 19, 2023
47dc009
feat: 添加用于显示回复消息原文的选项 (#672)
yilozt Mar 21, 2023
e02ab1f
feat: 新增限流功能 (#718)
zhuxindong Mar 21, 2023
6ecc61a
feat: 添加角色设定预留API 设定页(#768)
quzard Mar 22, 2023
b1d0056
perf: 重置回答时滚动定位至该回答 (#781)
shunyue1320 Mar 22, 2023
31a8432
perf: scrollToBottom 改成 scrollToBottomIfAtBottom (#771)
shunyue1320 Mar 22, 2023
bf48eae
feat: 更新依赖并兼容已存在的代理
Chanzhaoyu Mar 22, 2023
3e509f6
feat: 当用gpt-4的API 时增加可用的 Max Tokens (#729)
simonwu53 Mar 22, 2023
60fd2ae
feat: Create start.cmd (#656)
vulgate11 Mar 22, 2023
1edf591
chore(vsc-debug): 增加 visual-studio-code 的 debug 启动文件 (#296)
uxiew Mar 22, 2023
e302175
fix line end with new-line in some backend (#474)
liut Mar 22, 2023
9c6a3d6
feat: 增加 ChatGPTUnofficialProxyAPI 的模型自定义配置 (#632)
hncboy Mar 22, 2023
9227893
chore: 显示原文时使用 .whitespace-pre-wrap (#779)
yilozt Mar 22, 2023
d2a22a3
feat: PWA 默认不开启
Chanzhaoyu Mar 22, 2023
814c3a2
feat: 切换 history 时自动聚焦输入框 (#735)
JS-an Mar 22, 2023
5fee113
perf: 网络连接时 500 自动跳转到主页
Chanzhaoyu Mar 22, 2023
e55fc06
docs: fix docker port to private (#802)
kilvn Mar 23, 2023
734eb7a
feat: add zh-TW prompts in the Promt Store (#796)
PeterDaveHello Mar 23, 2023
630e88b
fix: prompt store 样式问题
Chanzhaoyu Mar 23, 2023
c52195c
chore: v2.10.8
Chanzhaoyu Mar 23, 2023
917feec
fix: 重置时应该移除本地储存
Chanzhaoyu Mar 23, 2023
5fca2e9
fix: PWA 未添加的问题 (#807)
Mar 23, 2023
73e12b1
fix: 移动端新建会话关闭侧边栏 (#813)
Chanzhaoyu Mar 23, 2023
9081b22
perf: 移动端删除 chat 时,侧边栏应该收起
Chanzhaoyu Mar 23, 2023
57a1d6e
fix: ESM error (#826)
kidonng Mar 23, 2023
634c879
perf: 自动焦点时移动端上的不便
Chanzhaoyu Mar 23, 2023
9b0d7db
fix: 移动端焦点不触发的问题
Chanzhaoyu Mar 23, 2023
9023210
perf: 本地地址
Chanzhaoyu Mar 24, 2023
fb8ad37
fix: 反向代理限流失效 (#863)
gitgitgogogo Mar 25, 2023
639152f
docs: update README.md, add long reply feature
yi-ge Mar 25, 2023
365a7df
Merge pull request #883 from yi-ge/dev-main
yi-ge Mar 25, 2023
a3944f8
fix: missing VITE_GLOB_API_URL when docker build, fixed #690 #717 # (…
zaiMoe Mar 25, 2023
c3f4311
chore: update docs
Chanzhaoyu Mar 26, 2023
799af86
perf: add localization for sider (#911)
simonwu53 Mar 27, 2023
32ad204
chore: Update README.md (#880)
weifeng12x Mar 27, 2023
e2eeee4
fix: local import error and NModal not as expected (#938)
KingTwinkle Mar 28, 2023
b579d24
pref: message output optimization (#935)
assassinliujie Mar 28, 2023
07123b7
chore: rolled back to clear the impact
Chanzhaoyu Mar 28, 2023
c0a9fd5
fix: 快速按下删除会话导致的问题 #917
Chanzhaoyu Mar 28, 2023
78bcf7f
perf: optimized output (#962)
assassinliujie Mar 28, 2023
76cef65
chore: build rollback
Chanzhaoyu Mar 28, 2023
aa0487e
chore: gitHub action
Chanzhaoyu Mar 29, 2023
0878af0
perf: 加入容器名字 (#1035)
LOVECHEN Mar 31, 2023
468bed7
feat: allow user disable openai API debug log (#1041)
zcong1993 Mar 31, 2023
c0f4af0
feat: add typing effect (#1017)
puppywang Mar 31, 2023
da20aed
feat: add kubernetes deploy (#1001)
CaoYunzhou Mar 31, 2023
142759a
chore: lint fix
Chanzhaoyu Mar 31, 2023
85543de
feat: 添加 socks5 代理认证 (#999)
yimiaoxiehou Mar 31, 2023
d2a852d
chore: .eslintignore
Chanzhaoyu Mar 31, 2023
90f0c3a
feat: add socks username/password config (#890)
hank-cp Mar 31, 2023
15f3aac
perf: 调整光标位置
Chanzhaoyu Mar 31, 2023
40fa028
fix: some error
Chanzhaoyu Mar 31, 2023
b241240
perf: 默认 systemMessage
Chanzhaoyu Mar 31, 2023
431de38
perf: input auto size
Chanzhaoyu Mar 31, 2023
9bd88ea
fix: 宽度问题
Chanzhaoyu Mar 31, 2023
e2ad3fe
fix: x-scrollbar height (#1153)
Fog3211 Apr 3, 2023
5594b0b
fix: 空引用显示undefined (#1103)
vchenpeng Apr 3, 2023
4e4e41b
chore: update deps
Chanzhaoyu Apr 3, 2023
e3a3e4d
fix: Update @acheong08 Reverse Proxy URL (#1085)
idawnwon Apr 3, 2023
553e239
chore: update .env.examples
Chanzhaoyu Apr 3, 2023
c2b25a8
chore: default API_REVERSE_PROXY
Chanzhaoyu Apr 3, 2023
0ff7825
chore: update README.md
Chanzhaoyu Apr 3, 2023
a7c9702
chore: v2.10.9
Chanzhaoyu Apr 3, 2023
abc4c3a
chore: 回退 chatgpt 包版本,原因:token 长回复报错
Chanzhaoyu Apr 3, 2023
9b66fed
fix: requestOptions (#1188)
leafsummer Apr 3, 2023
b07f01b
chore: 引导用户触发提示词 (#1183)
RyanXinOne Apr 3, 2023
1187d88
fix: 修复API余额查询 (#1174)
LuckyWang6 Apr 4, 2023
86bba7d
feat: 添加自定义 temperature 和 top_p (#1260)
quzard Apr 7, 2023
439104f
fix: 查询使用量支持代理&修正使用量文案 (#1296)
zuoning777 Apr 8, 2023
44f00c9
fix: 调整光标到底部
Chanzhaoyu Apr 8, 2023
ddc7066
chore: 默认 100 秒
Chanzhaoyu Apr 8, 2023
20aa35f
chore: optimize code (#1328)
shunyue1320 Apr 9, 2023
05a2414
fix: conversationOptions
Chanzhaoyu Apr 10, 2023
527c861
chore: mark days
Chanzhaoyu Apr 10, 2023
da04383
fix: default return in `useLanguange()` hook (#1352)
idawnwon Apr 10, 2023
eed33fb
feat: Added Korean translation (#1372)
Kamilake Apr 12, 2023
5378729
Let's make GitHub happy (#1453)
PeterDaveHello Apr 15, 2023
7583985
chore: Improve zh-TW locale (#1460)
PeterDaveHello Apr 16, 2023
226ce2b
[fix] markdown 表格内没有换行 (#1492)
wanglong001 Apr 17, 2023
ac8b69d
Create ru-RU.ts (#1571)
aquaratixc Apr 24, 2023
d598dc6
fix(proxy url): change default proxy url (#1567)
24min Apr 24, 2023
89f78bd
添加nginx防止爬虫爬取配置 (#1187)
appotry Apr 24, 2023
838679f
chore: Update index.ts (#1570)
aquaratixc Apr 24, 2023
dd20e9a
chore: 移除无用文件
Chanzhaoyu Apr 26, 2023
3b033d0
feat: 补充语言列表
Chanzhaoyu Apr 26, 2023
dbb57d8
perf: 优化复制逻辑
Chanzhaoyu Apr 26, 2023
3dff5bd
chore: version 2.11.0
Chanzhaoyu Apr 26, 2023
0f51e51
fix: 移动端塌缩
Chanzhaoyu May 4, 2023
1cb5393
fix: 移动端新建会话关闭侧边栏 (#1661)
tranhungonline May 6, 2023
bc390ef
feat: "Stop Responding" 国际化,使用 chatgpt 翻译 (#1735)
shunyue1320 May 31, 2023
6e272bb
feat: 支持最新的gpt-3.5-turbo-16k模型 (#1789)
BertramRay Jun 19, 2023
847a2d4
style: 优化移动端代码展示 (#1752)
symant233 Jun 19, 2023
c6e1663
Create vi-VN.ts (#1798)
trongtindev Jun 26, 2023
b8f2a0e
feat: 允许temperature调到2 (#1797)
shansing Jun 26, 2023
b651ef8
chore: Improve zh-TW locale (#1837)
PeterDaveHello Jul 15, 2023
c2ce700
fix: store循环引用 (#1880)
mdongsheng Aug 9, 2023
2b2efe2
Update README.md (#1864)
yangchuansheng Aug 9, 2023
c226d07
fix: 修复打字机动画
Chanzhaoyu Sep 26, 2023
4f9232c
chore: 格式化代码
Chanzhaoyu Sep 26, 2023
e1d8f5f
feat: 清空聊天历史
Chanzhaoyu Sep 26, 2023
2683977
chore: 2.11.1
Chanzhaoyu Sep 26, 2023
a6f6701
fix: 不规范的引入
Chanzhaoyu Sep 26, 2023
3482565
chore: doc
Chanzhaoyu Oct 7, 2023
a6605e8
chore: v2.11.1
Chanzhaoyu Oct 11, 2023
ed1e41c
feat: support the latest GPT-4 Turbo (gpt-4-1106-preview) model (#1968)
PeterDaveHello Nov 24, 2023
15a6b19
localization: Add additional English translations (#1987)
eburnette Dec 3, 2023
60f1f71
Added es-ES (#1989)
eburnette Dec 7, 2023
05e1df5
fix: SvgIcon打包报类型错误 (#2012)
a417420427 Jan 10, 2024
15903fa
feat: support the latest GPT-4 Turbo preview models (#2024)
PeterDaveHello Feb 1, 2024
c520580
fix(server): compatible with gateway.ai.cloudflare.com (#2029)
mylukin Mar 6, 2024
6432efe
chore: doc
Chanzhaoyu Mar 11, 2024
8dd447c
feat: improve GPT-3.5 Turbo 16k support (#2049)
PeterDaveHello Mar 11, 2024
f4f1d35
Add GPT-4 Turbo API the latest GA version (#2072)
PeterDaveHello Apr 16, 2024
a410376
perf: html2canvas => html-to-image
Chanzhaoyu Apr 19, 2024
ab9dca4
perf: change katex package
Chanzhaoyu May 16, 2024
fa8874b
update esno to fix tsx issue on Node v18.19 (#2083)
iizenn May 16, 2024
f257a54
feat: add GPT-4o support (#2082)
PeterDaveHello May 16, 2024
e1a3308
chore: replace EOL Node.js v19 w/ LTS v20 in engine spec (#2080)
PeterDaveHello May 16, 2024
e3ce91c
fix: model error
Chanzhaoyu May 17, 2024
a546d85
feat: markdown mermaid
Chanzhaoyu Jun 7, 2024
574aac2
perf: 数学公式 $$ 处理
Chanzhaoyu Jun 7, 2024
7474b2c
Add GPT-4o mini support (#2102)
PeterDaveHello Jul 19, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/typescript-node
{
"name": "Node.js & TypeScript",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/typescript-node:1-20-bullseye"

// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Use 'postCreateCommand' to run commands after the container is created.
// "postCreateCommand": "yarn install",

// Configure tool-specific properties.
// "customizations": {},

// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ node_modules
Dockerfile
.*
*/.*
!.env
5 changes: 4 additions & 1 deletion .env
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# Glob API URL
VITE_GLOB_API_URL=/api

VITE_APP_API_BASE_URL=http://localhost:3002/
VITE_APP_API_BASE_URL=http://127.0.0.1:3002/

# Whether long replies are supported, which may result in higher API fees
VITE_GLOB_OPEN_LONG_REPLY=false

# When you want to use PWA
VITE_GLOB_APP_PWA=false
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
docker-compose
kubernetes
22 changes: 22 additions & 0 deletions .github/workflows/issues_close.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Close inactive issues
on:
schedule:
- cron: '30 1 * * *'

jobs:
close-issues:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/stale@v5
with:
days-before-issue-stale: 10
days-before-issue-close: 2
stale-issue-label: stale
stale-issue-message: This issue is stale because it has been open for 10 days with no activity.
close-issue-message: This issue was closed because it has been inactive for 2 days since being marked as stale.
days-before-pr-stale: -1
days-before-pr-close: -1
repo-token: ${{ secrets.GITHUB_TOKEN }}
25 changes: 25 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "launch",
"name": "Launch Web App",
"url": "http://localhost:1002",
"webRoot": "${workspaceFolder}"
},
{
"type": "node",
"request": "launch",
"name": "Launch Service Server",
"runtimeExecutable": "${workspaceFolder}/service/node_modules/.bin/esno",
"skipFiles": ["<node_internals>/**"],
"program": "${workspaceFolder}/service/src/index.ts",
"outFiles": ["${workspaceFolder}/service/**/*.js"],
"envFile": "${workspaceFolder}/service/.env"
}
]
}
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"prettier.enable": false,
"editor.formatOnSave": false,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
"source.fixAll.eslint": "explicit"
},
"eslint.validate": [
"javascript",
Expand Down Expand Up @@ -37,6 +37,7 @@
"linkify",
"logprobs",
"mdhljs",
"mila",
"nodata",
"OPENAI",
"pinia",
Expand Down
178 changes: 178 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,181 @@
## v2.11.1

`2023-10-11`

## Enhancement
- 优化打字机光标效果
- 清空聊天历史按钮
- 更新文档

## BugFix
- 修复移动端上的问题
- 修复不规范的引入导致的问题

## v2.11.0

`2023-04-26`

> [chatgpt-web-plus](https://github.com/Chanzhaoyu/chatgpt-web-plus) 新界面、完整用户管理

## Enhancement
- 更新默认 `accessToken` 反代地址为 [[pengzhile](https://github.com/pengzhile)] 的 `https://ai.fakeopen.com/api/conversation` [[24min](https://github.com/Chanzhaoyu/chatgpt-web/pull/1567/files)]
- 添加自定义 `temperature` 和 `top_p` [[quzard](https://github.com/Chanzhaoyu/chatgpt-web/pull/1260)]
- 优化代码 [[shunyue1320](https://github.com/Chanzhaoyu/chatgpt-web/pull/1328)]
- 优化复制代码反馈效果

## BugFix
- 修复余额查询和文案 [[luckywangxi](https://github.com/Chanzhaoyu/chatgpt-web/pull/1174)][[zuoning777](https://github.com/Chanzhaoyu/chatgpt-web/pull/1296)]
- 修复默认语言错误 [[idawnwon](https://github.com/Chanzhaoyu/chatgpt-web/pull/1352)]
- 修复 `onRegenerate` 下问题 [[leafsummer](https://github.com/Chanzhaoyu/chatgpt-web/pull/1188)]

## Other
- 引导用户触发提示词 [[RyanXinOne](https://github.com/Chanzhaoyu/chatgpt-web/pull/1183)]
- 添加韩语翻译 [[Kamilake](https://github.com/Chanzhaoyu/chatgpt-web/pull/1372)]
- 添加俄语翻译 [[aquaratixc](https://github.com/Chanzhaoyu/chatgpt-web/pull/1571)]
- 优化翻译和文本检查 [[PeterDaveHello](https://github.com/Chanzhaoyu/chatgpt-web/pull/1460)]
- 移除无用文件

## v2.10.9

`2023-04-03`

> 更新默认 `accessToken` 反代地址为 [[pengzhile](https://github.com/pengzhile)] 的 `https://ai.fakeopen.com/api/conversation`

## Enhancement
- 添加 `socks5` 代理认证 [[yimiaoxiehou](https://github.com/Chanzhaoyu/chatgpt-web/pull/999)]
- 添加 `socks` 代理用户名密码的配置 [[hank-cp](https://github.com/Chanzhaoyu/chatgpt-web/pull/890)]
- 添加可选日志打印 [[zcong1993](https://github.com/Chanzhaoyu/chatgpt-web/pull/1041)]
- 更新侧边栏按钮本地化[[simonwu53](https://github.com/Chanzhaoyu/chatgpt-web/pull/911)]
- 优化代码块滚动条高度 [[Fog3211](https://github.com/Chanzhaoyu/chatgpt-web/pull/1153)]
## BugFix
- 修复 `PWA` 问题 [[bingo235](https://github.com/Chanzhaoyu/chatgpt-web/pull/807)]
- 修复 `ESM` 错误 [[kidonng](https://github.com/Chanzhaoyu/chatgpt-web/pull/826)]
- 修复反向代理开启时限流失效的问题 [[gitgitgogogo](https://github.com/Chanzhaoyu/chatgpt-web/pull/863)]
- 修复 `docker` 构建时 `.env` 可能被忽略的问题 [[zaiMoe](https://github.com/Chanzhaoyu/chatgpt-web/pull/877)]
- 修复导出异常错误 [[KingTwinkle](https://github.com/Chanzhaoyu/chatgpt-web/pull/938)]
- 修复空值异常 [[vchenpeng](https://github.com/Chanzhaoyu/chatgpt-web/pull/1103)]
- 移动端上的体验问题

## Other
- `Docker` 容器名字名义 [[LOVECHEN](https://github.com/Chanzhaoyu/chatgpt-web/pull/1035)]
- `kubernetes` 部署配置 [[CaoYunzhou](https://github.com/Chanzhaoyu/chatgpt-web/pull/1001)]
- 感谢 [[assassinliujie](https://github.com/Chanzhaoyu/chatgpt-web/pull/962)] 和 [[puppywang](https://github.com/Chanzhaoyu/chatgpt-web/pull/1017)] 的某些贡献
- 更新 `kubernetes/deploy.yaml` [[idawnwon](https://github.com/Chanzhaoyu/chatgpt-web/pull/1085)]
- 文档更新 [[#yi-ge](https://github.com/Chanzhaoyu/chatgpt-web/pull/883)]
- 文档更新 [[weifeng12x](https://github.com/Chanzhaoyu/chatgpt-web/pull/880)]
- 依赖更新

## v2.10.8

`2023-03-23`

如遇问题,请删除 `node_modules` 重新安装依赖。

## Feature
- 显示回复消息原文的选项 [[yilozt](https://github.com/Chanzhaoyu/chatgpt-web/pull/672)]
- 添加单 `IP` 每小时请求限制。环境变量: `MAX_REQUEST_PER_HOUR` [[zhuxindong ](https://github.com/Chanzhaoyu/chatgpt-web/pull/718)]
- 前端添加角色设定,仅 `API` 方式可见 [[quzard](https://github.com/Chanzhaoyu/chatgpt-web/pull/768)]
- `OPENAI_API_MODEL` 变量现在对 `ChatGPTUnofficialProxyAPI` 也生效,注意:`Token` 和 `API` 的模型命名不一致,不能直接填入 `gpt-3.5` 或者 `gpt-4` [[hncboy](https://github.com/Chanzhaoyu/chatgpt-web/pull/632)]
- 添加繁体中文 `Prompts` [[PeterDaveHello](https://github.com/Chanzhaoyu/chatgpt-web/pull/796)]

## Enhancement
- 重置回答时滚动定位至该回答 [[shunyue1320](https://github.com/Chanzhaoyu/chatgpt-web/pull/781)]
- 当 `API` 是 `gpt-4` 时增加可用的 `Max Tokens` [[simonwu53](https://github.com/Chanzhaoyu/chatgpt-web/pull/729)]
- 判断和忽略回复字符 [[liut](https://github.com/Chanzhaoyu/chatgpt-web/pull/474)]
- 切换会话时,自动聚焦输入框 [[JS-an](https://github.com/Chanzhaoyu/chatgpt-web/pull/735)]
- 渲染的链接新窗口打开
- 查询余额可选 `API_BASE_URL` 代理地址
- `config` 接口添加验证防止被无限制调用
- `PWA` 默认不开启,现在需手动修改 `.env` 文件 `VITE_GLOB_APP_PWA` 变量
- 当网络连接时,刷新页面,`500` 错误页自动跳转到主页

## BugFix
- `scrollToBottom` 调回 `scrollToBottomIfAtBottom` [[shunyue1320](https://github.com/Chanzhaoyu/chatgpt-web/pull/771)]
- 重置异常的 `loading` 会话

## Common
- 创建 `start.cmd` 在 `windows` 下也可以运行 [vulgatecnn](https://github.com/Chanzhaoyu/chatgpt-web/pull/656)]
- 添加 `visual-studio-code` 中调试配置 [[ChandlerVer5](https://github.com/Chanzhaoyu/chatgpt-web/pull/296)]
- 修复文档中 `docker` 端口为本地 [[kilvn](https://github.com/Chanzhaoyu/chatgpt-web/pull/802)]
## Other
- 依赖更新


## v2.10.7

`2023-03-17`

## BugFix
- 回退 `chatgpt` 版本,原因:导致 `OPENAI_API_BASE_URL` 代理失效
- 修复缺省状态的 `usingContext` 默认值

## v2.10.6

`2023-03-17`

## Feature
- 显示 `API` 余额 [[pzcn](https://github.com/Chanzhaoyu/chatgpt-web/pull/582)]

## Enhancement
- 美化滚动条样式和 `UI` 保持一致 [[haydenull](https://github.com/Chanzhaoyu/chatgpt-web/pull/617)]
- 优化移动端 `Prompt` 样式 [[CornerSkyless](https://github.com/Chanzhaoyu/chatgpt-web/pull/608)]
- 上下文开关改为全局开关,现在记录在本地缓存中
- 配置信息按接口类型显示

## Perf
- 优化函数方法 [[kirklin](https://github.com/Chanzhaoyu/chatgpt-web/pull/583)]
- 字符错误 [[pdsuwwz](https://github.com/Chanzhaoyu/chatgpt-web/pull/585)]
- 文档描述错误 [[lizhongyuan3](https://github.com/Chanzhaoyu/chatgpt-web/pull/636)]

## BugFix
- 修复 `Prompt` 导入、导出兼容性错误
- 修复 `highlight.js` 控制台兼容性警告

## Other
- 依赖更新

## v2.10.5

`2023-03-13`

更新依赖,`access_token` 默认代理为 [pengzhile](https://github.com/pengzhile) 的 `https://bypass.duti.tech/api/conversation`

## Feature
- `Prompt` 商店在线导入可以导入两种 `recommend.json`里提到的模板 [simonwu53](https://github.com/Chanzhaoyu/chatgpt-web/pull/521)
- 支持 `HTTPS_PROXY` [whatwewant](https://github.com/Chanzhaoyu/chatgpt-web/pull/308)
- `Prompt` 添加查询筛选

## Enhancement
- 调整输入框最大行数 [yi-ge](https://github.com/Chanzhaoyu/chatgpt-web/pull/502)
- 优化 `docker` 打包 [whatwewant](https://github.com/Chanzhaoyu/chatgpt-web/pull/520)
- `Prompt` 添加翻译和优化布局
- 「繁体中文」补全和审阅 [PeterDaveHello](https://github.com/Chanzhaoyu/chatgpt-web/pull/542)
- 语言选择调整为下路框形式
- 权限输入框类型调整为密码形式

## BugFix
- `JSON` 导入检查 [Nothing1024](https://github.com/Chanzhaoyu/chatgpt-web/pull/523)
- 修复 `AUTH_SECRET_KEY` 模式下跨域异常并添加对 `node.js 19` 版本的支持 [yi-ge](https://github.com/Chanzhaoyu/chatgpt-web/pull/499)
- 确定清空上下文时不应该重置会话标题

## Other
- 调整文档
- 更新依赖

## v2.10.4

`2023-03-11`

## Feature
- 感谢 [Nothing1024](https://github.com/Chanzhaoyu/chatgpt-web/pull/268) 添加 `Prompt` 模板和 `Prompt` 商店支持

## Enhancement
- 设置添加关闭按钮[#495]

## Demo

![Prompt](https://camo.githubusercontent.com/6a51af751eb29238cb7ef4f8fbd89f63db837562f97f33273095424e62dc9194/68747470733a2f2f73312e6c6f63696d672e636f6d2f323032332f30332f30342f333036326665633163613562632e676966)

## v2.10.3

`2023-03-10`
Expand Down
56 changes: 42 additions & 14 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,28 +1,56 @@
# build front-end
FROM node:lts-alpine AS builder
FROM node:lts-alpine AS frontend

RUN npm install pnpm -g
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

15% of developers fix this issue

DL3016: Pin versions in npm. Instead of npm install <package> use npm install <package>@<version>

❗❗ 2 similar findings have been found in this PR

🔎 Expand here to view all instances of this finding
File Path Line Number
Dockerfile 21
Dockerfile 38

Visit the Lift Web Console to find more details in your report.


ℹ️ Expand to see all @sonatype-lift commands

You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.

Command Usage
@sonatype-lift ignore Leave out the above finding from this PR
@sonatype-lift ignoreall Leave out all the existing findings from this PR
@sonatype-lift exclude <file|issue|path|tool> Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file

Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.


Help us improve LIFT! (Sonatype LiftBot external survey)

Was this a good recommendation for you? Answering this survey will not impact your Lift settings.

[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]


COPY ./ /app
WORKDIR /app

RUN apk add --no-cache git \
&& npm install pnpm -g \
&& pnpm install \
&& pnpm run build \
&& rm -rf /root/.npm /root/.pnpm-store /usr/local/share/.cache /tmp/*
COPY ./package.json /app

COPY ./pnpm-lock.yaml /app

RUN pnpm install

COPY . /app

RUN pnpm run build

# build backend
FROM node:lts-alpine as backend

RUN npm install pnpm -g

WORKDIR /app

COPY /service/package.json /app

COPY /service/pnpm-lock.yaml /app

RUN pnpm install

COPY /service /app

RUN pnpm build

# service
FROM node:lts-alpine

COPY /service /app
COPY --from=builder /app/dist /app/public
RUN npm install pnpm -g

WORKDIR /app
RUN apk add --no-cache git \
&& npm install pnpm -g \
&& pnpm install --only=production \
&& rm -rf /root/.npm /root/.pnpm-store /usr/local/share/.cache /tmp/*

COPY /service/package.json /app

COPY /service/pnpm-lock.yaml /app

RUN pnpm install --production && rm -rf /root/.npm /root/.pnpm-store /usr/local/share/.cache /tmp/*

COPY /service /app

COPY --from=frontend /app/dist /app/public

COPY --from=backend /app/build /app/build

EXPOSE 3002

CMD ["pnpm", "run", "start"]
CMD ["pnpm", "run", "prod"]
Loading