feat: chatbot CDT lookup — SRP quad, 4-digit auto-prefix, quad field to Selenium

- parseSrpCode: recognize "D4341 UL" / "4341 LR" etc., store quadrant in quad field
- matchOne: auto-prefix D for 4-digit inputs like "0120" → D0120
- LLM prompt: keep SRP code and quadrant together as one procedureName entry
- CdtMatch / CdtResult: add quad field, thread through matchedCodes action data
- claim-form.tsx: include quad in chatbot_claim_prefill type and spread to service line
- selenium_claimSubmitWorker.py: pass quad to fill_service_line, select quadrant
  dropdown by index (UR=1, UL=2, LL=3, LR=4) matching MassHealth form structure

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Gitead
2026-06-11 22:14:50 -04:00
co-authored by Claude Sonnet 4.6
parent 6cfca0d015
commit 831f67b093
9 changed files with 81 additions and 26 deletions
@@ -527,7 +527,7 @@ export function ClaimForm({
if (!raw) return;
try {
const { codes, serviceDate, renderingProvider } = JSON.parse(raw) as {
codes: { code: string; description: string; toothNumber?: string; toothSurface?: string }[];
codes: { code: string; description: string; toothNumber?: string; toothSurface?: string; quad?: string }[];
serviceDate?: string;
renderingProvider?: string | null;
};
@@ -553,6 +553,7 @@ export function ClaimForm({
procedureDate: date,
...(c.toothNumber ? { toothNumber: c.toothNumber } : {}),
...(c.toothSurface ? { toothSurface: c.toothSurface } : {}),
...(c.quad ? { quad: c.quad } : {}),
};
}
});