fix: Qwen3.5 /nothink 모드 + json_mode 파라미터 추가

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Hyungi Ahn
2026-03-26 13:33:23 +09:00
parent a77477140b
commit 948be1624f
2 changed files with 16 additions and 5 deletions

View File

@@ -10,7 +10,7 @@ import sys
from pathlib import Path
sys.path.insert(0, str(Path(__file__).parent.parent / "scripts"))
from pkm_utils import ollama_generate, PROJECT_ROOT
from pkm_utils import llm_generate, PROJECT_ROOT
PROMPT_TEMPLATE = (PROJECT_ROOT / "scripts" / "prompts" / "classify_document.txt").read_text()
@@ -54,7 +54,7 @@ def run_classify_test(doc: dict) -> dict:
prompt = PROMPT_TEMPLATE.replace("{document_text}", doc["text"])
try:
response = ollama_generate(prompt)
response = llm_generate(prompt, json_mode=True)
result = json.loads(response)
db_match = result.get("domain_db") == doc["expected_db"]