🏷️ fix: Ensure modelLabel Field Usage for ModelSpecs/GPTPlugins (#4224)

This commit is contained in:
Danny Avila 2024-09-24 07:27:11 -04:00 committed by GitHub
parent 321260e3c7
commit 6f498eee0f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 20 additions and 10 deletions

View file

@ -3,6 +3,7 @@ const generateArtifactsPrompt = require('~/app/clients/prompts/artifacts');
const buildOptions = (endpoint, parsedBody) => {
const {
modelLabel,
chatGptLabel,
promptPrefix,
agentOptions,
@ -16,10 +17,10 @@ const buildOptions = (endpoint, parsedBody) => {
} = parsedBody;
const endpointOption = removeNullishValues({
endpoint,
tools:
tools
.map((tool) => tool?.pluginKey ?? tool)
.filter((toolName) => typeof toolName === 'string'),
tools: tools
.map((tool) => tool?.pluginKey ?? tool)
.filter((toolName) => typeof toolName === 'string'),
modelLabel,
chatGptLabel,
promptPrefix,
agentOptions,