Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/geremyjampiersalasgarcia-eng/Caso_Practico_Semillero_IA/llms.txt

Use this file to discover all available pages before exploring further.

The Catalog Agent (agente_catalogo) is the go-to specialist for anything related to Patito S.A.’s product lineup. When the LangGraph classifier detects the intent catalogo_precios, it routes the query directly to this agent. The agent retrieves the most relevant chunks from the col_catalogo ChromaDB collection — populated from 01_Catalogo_Productos_Precios.txt — injects them into its system prompt, and calls Gemini to produce a structured answer that always includes product name, list price (USD, pre-tax, pre-discount), and availability status.

Agent properties

PropertyValue
nameagente_catalogo
collection_namecol_catalogo
system_prompt_pathbackend/app/prompts/catalogo_prompt.md
Knowledge document01_Catalogo_Productos_Precios.txt
Intent triggercatalogo_precios

Source class

from app.agents.base_agent import BaseAgent
import os


class CatalogoAgent(BaseAgent):
    """
    Agente de Catálogo y Precios.
    Responsable de responder sobre productos, especificaciones,
    disponibilidad y lista de precios vigente de Patito S.A.
    """

    @property
    def name(self) -> str:
        return "agente_catalogo"

    @property
    def description(self) -> str:
        return (
            "Responde consultas sobre productos, especificaciones, "
            "disponibilidad y lista de precios vigente de Patito S.A."
        )

    @property
    def collection_name(self) -> str:
        return "col_catalogo"

    @property
    def system_prompt_path(self) -> str:
        return os.path.join(
            os.path.dirname(__file__), "..", "prompts", "catalogo_prompt.md"
        )
CatalogoAgent inherits the full RAG pipeline from BaseAgent and only needs to declare the four abstract properties. No override of process_query is required.

Example queries

The following examples illustrate the kinds of questions this agent handles and what a correct answer looks like. 1. List price and availability
¿Cuál es el precio de lista y la disponibilidad del producto Patito Pro 2026?
Expected answer shape:
  • Producto: Patito Pro 2026
  • Precio de lista: USD listed in the catalog (pre-tax, pre-discount)
  • Disponibilidad: EN STOCK or bajo pedido
  • Source cited: 01_Catalogo_Productos_Precios.txt
2. Product line overview
¿Qué productos de la línea Patito Lite están disponibles?
Expected answer shape: list of Patito Lite 2026 and Patito Lite Mini with their respective prices and stock status. 3. Accessory lookup
¿Qué accesorios vende Patito S.A. y cuánto cuestan?
Expected answer shape: list of accessories (Funda protectora, Cargador rápido 65W, Mouse inalámbrico Patito) with unit prices and availability. 4. Out-of-scope graceful fallback
¿Qué descuentos puedo ofrecer en el Patito Pro Max 2026?
Expected answer: the agent returns the list price and notes that discount policies are handled by the Policies Agent, not this one.

Response format

Every AgentResult returned by agente_catalogo follows this structure:
FieldDescription
agent_nameAlways "agente_catalogo"
answerMarkdown-formatted text with product name, list price in USD, availability (EN STOCK / bajo pedido), and estimated delivery time if applicable. Prices are stated as pre-tax and pre-discount.
sourcesList of SourceInfo objects: document_name (01_Catalogo_Productos_Precios.txt), content_snippet (first 200 chars of the matched chunk), relevance_score (cosine similarity from ChromaDB).
tokens_inputGemini input token count for this call.
tokens_outputGemini output token count for this call.
The Multimodal Agent also queries col_catalogo as its knowledge base. When a user uploads a product image, Gemini Vision first identifies the item visually, then the same catalog collection is searched to retrieve pricing and availability — so both agents draw from the same ground-truth data. See the Multimodal Agent page for details.

Build docs developers (and LLMs) love