Update split reimb dates condition
This commit is contained in:
@@ -656,11 +656,7 @@ def split_reimb_dates(one_to_n_results: list, filename: str) -> list:
|
|||||||
record["REIMB_TERMINATION_DT"] = None
|
record["REIMB_TERMINATION_DT"] = None
|
||||||
|
|
||||||
# Check if this record has valid REIMB_DATES
|
# Check if this record has valid REIMB_DATES
|
||||||
if (
|
if not string_utils.is_empty(record.get("REIMB_DATES")):
|
||||||
"REIMB_DATES" in record
|
|
||||||
and record["REIMB_DATES"] is not None
|
|
||||||
and str(record["REIMB_DATES"]).strip() != ""
|
|
||||||
):
|
|
||||||
records_to_process.append((i, record))
|
records_to_process.append((i, record))
|
||||||
|
|
||||||
if not records_to_process:
|
if not records_to_process:
|
||||||
@@ -679,13 +675,6 @@ def split_reimb_dates(one_to_n_results: list, filename: str) -> list:
|
|||||||
llm_answer_final = prompt_calls.prompt_split_reimb_dates(
|
llm_answer_final = prompt_calls.prompt_split_reimb_dates(
|
||||||
date_range, filename
|
date_range, filename
|
||||||
)
|
)
|
||||||
# Debug: print raw parsed LLM output
|
|
||||||
print(f"DEBUG split_reimb_dates - Index {index}:")
|
|
||||||
print(f" Input date_range: {date_range}")
|
|
||||||
print(f" Parsed LLM output: {llm_answer_final} (type: {type(llm_answer_final)})")
|
|
||||||
if isinstance(llm_answer_final, dict):
|
|
||||||
print(f" start_date: {llm_answer_final.get('start_date')}")
|
|
||||||
print(f" end_date: {llm_answer_final.get('end_date')}")
|
|
||||||
# Update the specific record with parsed dates
|
# Update the specific record with parsed dates
|
||||||
if llm_answer_final and isinstance(llm_answer_final, dict):
|
if llm_answer_final and isinstance(llm_answer_final, dict):
|
||||||
if "start_date" in llm_answer_final:
|
if "start_date" in llm_answer_final:
|
||||||
|
|||||||
Reference in New Issue
Block a user