增加模型别名
This commit is contained in:
@@ -225,6 +225,11 @@ func (h *UserGenerationHandler) Logs(c *gin.Context) {
|
||||
c.JSON(http.StatusInternalServerError, gin.H{"detail": "failed to load logs"})
|
||||
return
|
||||
}
|
||||
modelByID, err := h.admin.ModelNameMap(c.Request.Context())
|
||||
if err != nil {
|
||||
c.JSON(http.StatusInternalServerError, gin.H{"detail": "failed to load logs"})
|
||||
return
|
||||
}
|
||||
|
||||
out := make([]gin.H, 0, len(items))
|
||||
for _, item := range items {
|
||||
@@ -249,7 +254,7 @@ func (h *UserGenerationHandler) Logs(c *gin.Context) {
|
||||
"ts": item.TS.Unix(),
|
||||
"kind": item.Kind,
|
||||
"status": item.Status,
|
||||
"model": item.Model,
|
||||
"model": displayModelName(modelByID, item.Model),
|
||||
"provider": item.Provider,
|
||||
"prompt": item.Prompt,
|
||||
"ratio": item.Ratio,
|
||||
|
||||
Reference in New Issue
Block a user