diff --git a/src/enricher.py b/src/enricher.py index 8c22c7d..ea69ba7 100644 --- a/src/enricher.py +++ b/src/enricher.py @@ -82,6 +82,7 @@ You are an information extractor. Analyze the web page content below and return - "author": author or organization name, or null if not found (string | null) - "tags": list of 3-5 relevant keywords (string[]) - "content_type": one of "article", "documentation", "news", "forum", "code", "video", "other" (string) +- "citation": APA 7th edition citation string for this source (string). Format: Author/Org. (Year, Month Day). Title. Site Name. URL — use "n.d." if date unknown, omit fields that cannot be determined. Title: {title} URL: {url} @@ -110,7 +111,7 @@ def enrich_result(title: str, url: str, snippet: str) -> dict: client = _get_llm_client() req = GenericChatRequest( messages=[UserMessage(content=[TextContent(text=prompt)])], - max_tokens=512, + max_tokens=1024, temperature=0, ) det = ChatDetails( @@ -132,6 +133,7 @@ def enrich_result(title: str, url: str, snippet: str) -> dict: "author": None, "tags": [], "content_type": "other", + "citation": None, "_error": str(exc), }