🐛 fix: Enforced Model Spec Icons/Labels and Agent Descriptions (#4979)

* fix: Previous convos missing model spec info when enforce is set to `true` #4749

* refactor: Include description field in agent list response
This commit is contained in:
Danny Avila
2024-12-13 16:15:48 -05:00
committed by GitHub
parent 0a5bc503b0
commit f15035542f
2 changed files with 5 additions and 0 deletions

View File

@@ -200,6 +200,7 @@ const getListAgents = async (searchParameter) => {
avatar: 1,
author: 1,
projectIds: 1,
description: 1,
isCollaborative: 1,
}).lean()
).map((agent) => {

View File

@@ -63,6 +63,10 @@ async function buildEndpointOption(req, res, next) {
}
try {
currentModelSpec.preset.spec = spec;
if (currentModelSpec.iconURL != null && currentModelSpec.iconURL !== '') {
currentModelSpec.preset.iconURL = currentModelSpec.iconURL;
}
parsedBody = parseCompactConvo({
endpoint,
endpointType,