mirror of
https://wget.la/https://github.com/leookun/cursor-byok
synced 2026-08-18 03:57:06 +08:00
refactor: update model details handling in CLI
- Renamed test function to better reflect its purpose. - Enhanced model details structure by adding DisplayName and DisplayNameShort fields in buildCLIModelDetails. - Updated test cases to validate the new fields and ensure correct functionality.
This commit is contained in:
@@ -728,8 +728,10 @@ func buildCLIModelDetails(adapters []legacyruntime.ModelAdapterConfig) []map[str
|
||||
continue
|
||||
}
|
||||
models = append(models, map[string]any{
|
||||
"modelId": channelID,
|
||||
"displayModelId": channelID,
|
||||
"modelId": channelID,
|
||||
"displayModelId": channelID,
|
||||
"displayName": strings.TrimSpace(adapter.DisplayName),
|
||||
"displayNameShort": strings.TrimSpace(adapter.DisplayName),
|
||||
"apiKeyCredentials": map[string]any{
|
||||
"apiKey": strings.TrimSpace(adapter.APIKey),
|
||||
"baseUrl": strings.TrimSpace(adapter.BaseURL),
|
||||
|
||||
Reference in New Issue
Block a user