Fix summarization custom prompt file support and consolidate config lookups#64
Merged
prasjaiswal merged 1 commit intomainfrom Feb 15, 2026
Merged
Conversation
… file support - Add get_site_prompts_config() as single entry point for all prompt config access - Add get_site_prompt_file() helper, used by both decontextualization and summarization - Fix create_summarizer_from_prompt_ref() to search custom prompt files before default XML - Replace inline config lookups in handler.py and aajtak.py with shared helpers Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
prompt_filefrom site config, matching decontextualization behaviorget_site_prompts_config()entry pointget_site_prompt_file()shared by both decontextualization and summarization pathsProblem
When a site configured a custom
prompt_filein config.yaml, decontextualization correctly loaded prompts from that file, but summarization always searched only the defaultquery_analysis.xml— silently ignoring custom summarization prompts.Changes
handler.pyget_site_prompts_config()andget_site_prompt_file(), refactor existing helpers to use themsummarizer.pycreate_summarizer_from_prompt_ref()accepts optionalprompt_file, searches it firstpostQueryProcessing.pyget_site_prompt_file()from handler instead of local duplicateaajtak.pyget_site_prompt_file()instead of inline config lookupTest plan
make checkpasses (ruff, pyright, 252 tests)make dev— tested bothsite: "all"andsite: "aajtak.in"queries successfully🤖 Generated with Claude Code