From dcec3f4b7aa3d3164f87779add1285e0dbc137d0 Mon Sep 17 00:00:00 2001 From: Praneel Panchigar Date: Fri, 23 Jan 2026 21:53:07 +0000 Subject: [PATCH] Merged in bugfix/preserve_lob_relationship_llm_values (pull request #846) Bugfix/preserve lob relationship llm values * Relationship values changes * Fix: Preserve LLM-determined LOB relationship values - Prevent fill_na_mapping from overwriting LLM-determined 'Inclusive' relationships - Only set 'Exclusive' when relationship field is empty/NA (preserves LLM values) - Default to 'Exclusive' when PROGRAM/PRODUCT is NA/blank (LLM bypassed cases) - Condensed redundant conditional logic for better maintainability * Changed LOB Relationship prompt to more strictly enforce an output format * Merge remote-tracking branch 'origin/main' into bugfix/preserve_lob_relationship_llm_values Approved-by: Katon Minhas --- fieldExtraction/src/prompts/prompt_templates.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fieldExtraction/src/prompts/prompt_templates.py b/fieldExtraction/src/prompts/prompt_templates.py index 026ba19..322184f 100644 --- a/fieldExtraction/src/prompts/prompt_templates.py +++ b/fieldExtraction/src/prompts/prompt_templates.py @@ -1419,7 +1419,7 @@ Here is the Exhibit to be analyzed: [OUTPUT FORMAT - REQUIRED] You MUST format your response with pipe delimiters. Example format: "Based on the analysis... |Inclusive|" or "The relationship is... |Exclusive|" -Your final answer MUST be enclosed in pipe delimiters: |Inclusive| or |Exclusive| +Your final answer MUST be enclosed in pipe delimiters: |Inclusive| or |Exclusive| AND you must make sure that the pipe delimiters are only used around the terms Inclusive or Exclusive. """