[Python] context precision and context recall issue in RAGAS

Discussão em 'Python' iniciado por Stack, Agosto 25, 2025.

  1. Stack

    Stack Membro Participativo

    I’m trying to evaluate retrieval quality using RAGAS, specifically with context precision and context recall.

    According to the documentation (and the prompt used inside the functions), the dataset format should contain:

    • question
    • context
    • answer

    The error says my dataset is not formatted correctly, it expects:

    • user_input
    • reference
    • retrieved_contexts

    When I change the format and run the evaluation, I keep getting RagasOutputParserException.

    This seems inconsistent: the functions themselves use a prompt that assumes question/context/answer, but the evaluation fails unless the dataset is structured differently. I’m fairly sure the issue is caused by this mismatch.

    Has anyone run into this? is there a way to make RAGAS accept the question/context/answer format that its own functions seem to expect?

    Continue reading...

Compartilhe esta Página