Fix config (#3476)

* feat: SiliconCloud doc

* feat: SiliconCloud doc

* perf: silicon cloud doc

* perf: silicon cloud doc
This commit is contained in:
Archer
2024-12-26 21:36:09 +08:00
committed by GitHub
parent f7942655a2
commit a209856d48
40 changed files with 476 additions and 246 deletions

View File

@@ -4,7 +4,7 @@ description: 'FastGPT 配置参数介绍'
icon: 'settings'
draft: false
toc: true
weight: 708
weight: 707
---
由于环境变量不利于配置复杂的内容,新版 FastGPT 采用了 ConfigMap 的形式挂载配置文件,你可以在 `projects/app/data/config.json` 看到默认的配置文件。可以参考 [docker-compose 快速部署](/docs/development/docker/) 来挂载配置文件。
@@ -97,7 +97,9 @@ weight: 708
"customExtractPrompt": "",
"defaultSystemChatPrompt": "",
"defaultConfig": {
"temperature": 1
"temperature": 1,
"max_tokens": null,
"stream": false
}
},
{
@@ -122,7 +124,9 @@ weight: 708
"customExtractPrompt": "",
"defaultSystemChatPrompt": "",
"defaultConfig": {
"temperature": 1
"temperature": 1,
"max_tokens": null,
"stream": false
}
}
],
@@ -185,7 +189,7 @@ weight: 708
}
```
## 模型提供商
## 内置的模型提供商ID
为了方便模型分类展示FastGPT 内置了部分模型提供商的名字和 Logo。如果你期望补充提供商可[提交 Issue](https://github.com/labring/FastGPT/issues),并提供几个信息:
@@ -213,9 +217,33 @@ weight: 708
- Other - 其他
## 特殊模型
## ReRank 模型接入
### ReRank 接入(私有部署)
由于 OneAPI 不支持 Rerank 模型,所以需要单独配置接入,这里
### 使用硅基流动的在线模型
有免费的 `bge-reranker-v2-m3` 模型可以使用。
1. [点击注册硅基流动账号](https://cloud.siliconflow.cn/i/TR9Ym0c4)
2. 进入控制台,获取 API key: https://cloud.siliconflow.cn/account/ak
3. 修改 FastGPT 配置文件
```json
{
"reRankModels": [
{
"model": "BAAI/bge-reranker-v2-m3", // 这里的model需要对应 siliconflow 的模型名
"name": "BAAI/bge-reranker-v2-m3",
"requestUrl": "https://api.siliconflow.cn/v1/rerank",
"requestAuth": "siliconflow 上申请的 key"
}
]
}
```
### 私有部署模型
请使用 4.6.6-alpha 以上版本,配置文件中的 `reRankModels` 为重排模型虽然是数组不过目前仅有第1个生效。
@@ -236,44 +264,3 @@ weight: 708
]
}
```
### ReRank 接入(硅基流动)
有免费的 `bge-reranker-v2-m3` 模型可以使用。
1. 注册硅基流动账号: https://siliconflow.cn/
2. 进入控制台,获取 API key: https://cloud.siliconflow.cn/account/ak
3. 修改 FastGPT 配置文件
```json
{
"reRankModels": [
{
"model": "BAAI/bge-reranker-v2-m3", // 这里的model需要对应 siliconflow 的模型名
"name": "BAAI/bge-reranker-v2-m3",
"requestUrl": "https://api.siliconflow.cn/v1/rerank",
"requestAuth": "siliconflow 上申请的 key"
}
]
}
```
### ReRank 接入Cohere
这个重排模型对中文不是很好,不如 bge 的好用。
1. 申请 Cohere 官方 Key: https://dashboard.cohere.com/api-keys
2. 修改 FastGPT 配置文件
```json
{
"reRankModels": [
{
"model": "rerank-multilingual-v2.0", // 这里的model需要对应 cohere 的模型名
"name": "rerank-multilingual-v2.0",
"requestUrl": "https://api.cohere.ai/v1/rerank",
"requestAuth": "Coherer上申请的key"
}
]
}
```