* feat: api3 WIP

* feat: add support for proxy of openai

* fix: if no proxy
This commit is contained in:
ikechan8370 2023-02-14 22:54:47 +08:00 committed by GitHub
parent ab021d0caa
commit 62c8d56e76
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 115 additions and 4 deletions

View file

@ -1,5 +1,5 @@
// 例如http://127.0.0.1:7890
const PROXY = ''
const PROXY = 'http://127.0.0.1:7890'
const API_KEY = ''
export const Config = {
@ -20,8 +20,12 @@ export const Config = {
apiKey: API_KEY,
// 模型名称选填。如无特殊需求保持默认即可会使用chatgpt-api库提供的当前可用的最适合的默认值。保底可用的是 text-davinci-003。当发现新的可用的chatGPT模型会更新这里的值
// 20230211 text-chat-davinci-002-sh-alpha-aoruigiofdj83 中午存活了几分钟
model: 'text-davinci-002-render',
api: '',
model: '',
// ***********************************************************************************************************************************
// 以下为API3方式的配置 *
// ***********************************************************************************************************************************
// from https://github.com/acheong08/ChatGPT
api: 'https://chat.duti.tech/api/conversation',
// ***********************************************************************************************************************************
// 以下为API2方式的配置 *
// ***********************************************************************************************************************************