mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-09-27 21:56:39 +08:00
feat: initialize token encoders in a goroutine to reduce service startup time
This commit is contained in:
parent
6ad169975f
commit
2a19e5e2f8
2
main.go
2
main.go
@ -88,7 +88,7 @@ func main() {
|
|||||||
if config.EnableMetric {
|
if config.EnableMetric {
|
||||||
logger.SysLog("metric enabled, will disable channel if too much request failed")
|
logger.SysLog("metric enabled, will disable channel if too much request failed")
|
||||||
}
|
}
|
||||||
openai.InitTokenEncoders()
|
go openai.InitTokenEncoders()
|
||||||
client.Init()
|
client.Init()
|
||||||
|
|
||||||
// Initialize HTTP server
|
// Initialize HTTP server
|
||||||
|
Loading…
Reference in New Issue
Block a user