From 14476bfbd7096ff9134ce191fe077ee3cad97117 Mon Sep 17 00:00:00 2001 From: Viktor Barzin Date: Tue, 16 Jun 2026 20:39:29 +0000 Subject: [PATCH] tripit: mail-ingest extracts with the qwen3-8b text model, not the vision model MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Forwarded schedule-change emails were being parsed by qwen3vl-4b (a 4B *vision* model) for text extraction, which reliably dropped the flight number — so the matcher had no key to link on and a forwarded flight update created a duplicate instead of amending the existing segment. Point the ingest-plans CronJob's text extraction at qwen3-8b (verified live: it emits flight_number + a clean PNR, 3/3 on the failing email) and keep qwen3vl-4b for boarding-pass image attachments (LLM_VISION_MODEL). llama-swap loads each on demand; the GPU swap cost is accepted. Co-Authored-By: Claude Opus 4.8 --- stacks/tripit/main.tf | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/stacks/tripit/main.tf b/stacks/tripit/main.tf index b26beb94..c40b73f9 100644 --- a/stacks/tripit/main.tf +++ b/stacks/tripit/main.tf @@ -550,9 +550,14 @@ locals { suspend = false imap_pw_secret_key = "PLANS_IMAP_PASSWORD" extra_env = { - LLM_MODE = "llamacpp" - LLM_ENDPOINT = "http://llama-swap.llama-cpp.svc.cluster.local:8080" - LLM_MODEL = "qwen3vl-4b" + LLM_MODE = "llamacpp" + LLM_ENDPOINT = "http://llama-swap.llama-cpp.svc.cluster.local:8080" + # Text body extraction uses the 8B text model (reliably emits flight_number); + # boarding-pass image attachments use the 4B vision model. llama-swap loads + # each on demand. Was qwen3vl-4b for both, which dropped flight numbers and + # duplicated schedule-change emails (2026-06-16). + LLM_MODEL = "qwen3-8b" + LLM_VISION_MODEL = "qwen3vl-4b" MAIL_INGEST_ENABLED = "true" IMAP_HOST = "mailserver.mailserver.svc.cluster.local" IMAP_PORT = "993"