set include_usage by default for all model providers (#1818)

This commit is contained in:
澄潭
2025-02-26 16:49:16 +08:00
committed by GitHub
parent f6c48415d1
commit 1787553294
3 changed files with 29 additions and 21 deletions

View File

@@ -292,6 +292,10 @@ func (c *ProviderConfig) GetProtocol() string {
return c.protocol
}
func (c *ProviderConfig) IsOpenAIProtocol() bool {
return c.protocol == protocolOpenAI
}
func (c *ProviderConfig) FromJson(json gjson.Result) {
c.id = json.Get("id").String()
c.typ = json.Get("type").String()