Fix test
This commit is contained in:
parent
0f5b9ae208
commit
a57203065a
5 changed files with 8 additions and 7 deletions
|
|
@ -26,7 +26,7 @@ GUIDELINES:
|
|||
- Consider both answers correct if they convey the same essential information
|
||||
- Be tolerant of different levels of detail if the core answer is preserved
|
||||
- Evaluate based on what a person asking this question would need to know
|
||||
/no_think"""
|
||||
"""
|
||||
|
||||
|
||||
class LLMJudgeResponseSchema(BaseModel):
|
||||
|
|
|
|||
|
|
@ -18,5 +18,4 @@ Guidelines:
|
|||
- Stick to the answer, do not ellaborate or provide context unless explicitly asked for it.
|
||||
|
||||
Be concise, and always maintain accuracy over completeness. Prefer short, direct answers that are well-supported by the documents.
|
||||
/no_think
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -29,13 +29,13 @@ class ResearchPlan(BaseModel):
|
|||
class Citation(BaseModel):
|
||||
"""Resolved citation with full metadata for display/visual grounding."""
|
||||
|
||||
document_id: str
|
||||
chunk_id: str
|
||||
document_uri: str
|
||||
document_id: str = ""
|
||||
chunk_id: str = ""
|
||||
document_uri: str = ""
|
||||
document_title: str | None = None
|
||||
page_numbers: list[int] = Field(default_factory=list)
|
||||
headings: list[str] | None = None
|
||||
content: str
|
||||
content: str = ""
|
||||
|
||||
|
||||
class SearchAnswer(BaseModel):
|
||||
|
|
|
|||
|
|
@ -315,6 +315,8 @@ async def test_ask_with_cite(app: HaikuRAGApp, monkeypatch):
|
|||
mock_answer = "Test answer with citations"
|
||||
mock_citations = [
|
||||
Citation(
|
||||
document_id="doc-123",
|
||||
chunk_id="chunk-456",
|
||||
document_uri="test.md",
|
||||
document_title="Test Document",
|
||||
page_numbers=[1],
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ async def test_qa_ollama(qa_corpus: Dataset, temp_db_path):
|
|||
"""Test Ollama QA with LLM judge."""
|
||||
client = HaikuRAG(temp_db_path, create=True)
|
||||
qa = QuestionAnswerAgent(
|
||||
client, ModelConfig(provider="ollama", name="gpt-oss", enable_thinking=False)
|
||||
client, ModelConfig(provider="ollama", name="gpt-oss", enable_thinking=True)
|
||||
)
|
||||
llm_judge = LLMJudge()
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue