This commit is contained in:
josc146
2023-05-06 23:39:23 +08:00
parent fbeee1917c
commit 2acf9f71ae
10 changed files with 295 additions and 7 deletions

15
backend-golang/rwkv.go Normal file
View File

@@ -0,0 +1,15 @@
package backend_golang
import (
"os/exec"
)
func (a *App) StartServer(strategy string, modelPath string) string {
//cmd := exec.Command(`explorer`, `/select,`, `e:\RWKV-4-Raven-7B-v10-Eng49%25-Chn50%25-Other1%25-20230420-ctx4096.pth`)
cmd := exec.Command("cmd-helper", "python", "./backend-python/main.py", strategy, modelPath)
out, err := cmd.CombinedOutput()
if err != nil {
return err.Error()
}
return string(out)
}