Skip to content
This repository was archived by the owner on Apr 15, 2025. It is now read-only.

Commit 06cf9b5

Browse files
authored
Merge pull request #7 from aurora-develop/yjmp14-main
Update duckgo convert.go to support Llama-3-70b and Mixtral-8x7B models
2 parents e80698d + 0269180 commit 06cf9b5

3 files changed

Lines changed: 11 additions & 2 deletions

File tree

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242
env:
4343
GITHUB_TOKEN: ${{ secrets.GHCR_PAT }}
4444
with:
45-
tag_name: v2.0.9
45+
tag_name: v2.1.0
4646
files: |
4747
duck2api-linux-amd64.tar.gz
4848
duck2api-windows-amd64.tar.gz

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ curl --location 'http://你的服务器ip:8080/v1/chat/completions' \
6161
"stream": true
6262
}'
6363
```
64-
支持claude和gpt-3.5-turbo
64+
## 支持的模型
65+
claude和gpt-3.5-turbo,Llama-3-70b,Mixtral-8x7B等模型
6566
## 高级设置
6667

6768
默认情况不需要设置,除非你有需求

conversion/requests/duckgo/convert.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,14 @@ func ConvertAPIRequest(api_request officialtypes.APIRequest) duckgotypes.ApiRequ
1313
if strings.HasPrefix(strings.ToLower(api_request.Model), "claude") {
1414
duckgo_request.Model = "claude-3-haiku-20240307"
1515
}
16+
if strings.HasPrefix(strings.ToLower(api_request.Model), "Llama-3-70b") {
17+
18+
duckgo_request.Model = "meta-llama/Llama-3-70b-chat-hf"
19+
}
20+
if strings.HasPrefix(strings.ToLower(api_request.Model), "Mixtral-8x7B") {
21+
22+
duckgo_request.Model = "mistralai/Mixtral-8x7B-Instruct-v0.1"
23+
}
1624
content := buildContent(&api_request)
1725
duckgo_request.AddMessage("user", content)
1826
return duckgo_request

0 commit comments

Comments
 (0)