Skip to content
This repository was archived by the owner on Aug 21, 2026. It is now read-only.
This repository was archived by the owner on Aug 21, 2026. It is now read-only.

Bug: Incorrect CORRECTNESS_PROMPT — missing format placeholders (user_question, report, answer) #217

Open

Description

Hi team! Thank you for the great project.

I found that CORRECTNESS_PROMPT does not use user_question, report, or answer in tests/prompts.py:

CORRECTNESS_PROMPT = """You are evaluating the correctness of a research report that was generated by a research agent.
You will be provided with the question, the report, and the answer from an independent authority.
Score the report from 1-5 on how well it mirrors the answer from the authority.
We expect the report to contain more information that is not in the answer, that's perfectly okay.
They likely won't be perfectly the same, but they should have the same themes and ideas to get a high score.
Use your best judgement when comparing the answer to the report!
"""

However, the eval_correctness function in tests/evaluators.py formats the prompt with these fields:

user_input_content = CORRECTNESS_PROMPT.format(user_question=query, report=final_report, answer=answer, today=get_today_str())

As a result, format() has no effect and the evaluator receives a prompt that lacks the actual question, the generated report, and the authoritative answer.

Could you please confirm whether this is a bug?

Activity

  1. krishnamurthi-ramesh commented on Feb 5, 2026

    @krishnamurthi-ramesh

    Hi @nariaki3551,
    I can confirm this is indeed a bug. You are absolutely right, since the CORRECTNESS_PROMPT is static, the .format() call in evaluators.py is currently being ignored, which means the evaluator isn't actually seeing the report or the answer.I went ahead and tested the fix (adding the missing placeholders to the prompt string), and everything works perfectly now. Here are my verification results:

    Verification Complete (By Doing it locally) :
    Prompt Formatting Works: The CORRECTNESS_PROMPT.format() call now successfully substitutes all placeholders: {user_question}, {report}, {answer}, and {today}.
    Exact Function Call Works: The specific format call used in eval_correctness() now executes without any KeyError.
    Content Verification: I confirmed the formatted prompt correctly contains the injected data (e.g., "Test question", "Test report content").
    Syntax Check: Both prompts.py and evaluators.py compile without errors.

    Great catch! The fix is definitely to append those missing fields to the prompt definition.

  2. akshan-main commented on Feb 12, 2026

    @akshan-main

    I can look into this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions