googleapis / googleapis/nodejs-agentplatform

Constrained output and functionCall don't work together

Abierto
#435 1 comentario 3 reacciones 0 asignados Ver en GitHub
api: aiplatform priority: p2 type: bug
Lenguaje dominante
TypeScript
Estrellas
182
Forks
69
Merge medio
1 d 8 h
PR fusionados (30 d)
10

Descripción

Hi,

I’m currently working on developing LLM agents and in the same call, I’m using tools (functionCall) to make external API requests, while also using constrained output to format the response as JSON.

However, I’m encountering the following error:
“For controlled generation of only function calls (forced function calling), please set 'tool_config.function_calling_config.mode' field to ANY instead of populating 'response_mime_type' and 'response_schema' fields. For more details, see: [https://cloud.google.com/vertex-ai/generative-ai/docs/multimodal/function-calling#tool-config”](https://cloud.google.com/vertex-ai/generative-ai/docs/multimodal/function-calling#tool-config%E2%80%9D).

From what I understand, it seems like using tools alongside constrained output in JSON format isn't possible, though this is crucial for building agents.

Is this a bug, or is there another way to achieve this?

Thanks in advance for any help!

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

No se nombran archivos del repositorio, pruebas ni puntos de entrada. Empieza reproduciendo la misma llamada con tools más response_mime_type y response_schema; después, lee la guía vinculada de Vertex AI sobre function-calling; la tarea estará terminada cuando se determine si la combinación es compatible y se documente el comportamiento o la limitación confirmados.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
google-cloud, typescript
Área
ai, api
Tipo de issue
Error
Dificultad
5/5
Tiempo estimado
Más de una semana
Estado de actividad
Estancado
Claridad
Necesita aclaración
Aptitud para principiantes
20/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.