feat: Update model lists and enhance model retrieval in Adaptor
- Refactored ModelList in the gemini constant to include new models and remove outdated ones. - Modified the GetModelList function in the Adaptor to consolidate model lists from multiple sources, ensuring a comprehensive and updated list is returned. - Commented out deprecated models in the vertex constants for clarity and future reference.
This commit is contained in:
@@ -176,7 +176,20 @@ func (a *Adaptor) DoResponse(c *gin.Context, resp *http.Response, info *relaycom
|
||||
}
|
||||
|
||||
func (a *Adaptor) GetModelList() []string {
|
||||
return ModelList
|
||||
var modelList []string
|
||||
for i, s := range ModelList {
|
||||
modelList = append(modelList, s)
|
||||
ModelList[i] = s
|
||||
}
|
||||
for i, s := range claude.ModelList {
|
||||
modelList = append(modelList, s)
|
||||
claude.ModelList[i] = s
|
||||
}
|
||||
for i, s := range gemini.ModelList {
|
||||
modelList = append(modelList, s)
|
||||
gemini.ModelList[i] = s
|
||||
}
|
||||
return modelList
|
||||
}
|
||||
|
||||
func (a *Adaptor) GetChannelName() string {
|
||||
|
||||
Reference in New Issue
Block a user