project-nomad/admin/app/jobs
chriscrosstalk 68c0a37cab
fix(RAG): anchor continuation-batch initial progress to overall-file frame (#889)
Each continuation batch of a multi-batch ZIM embed runs as a fresh
BullMQ job, so handle() ran the hardcoded `safeUpdateProgress(job, 5)`
even when the file was already 100k articles into a 600k-article ZIM.
The UI gauge briefly dropped to 5% before the per-batch onProgress
callback caught up to the true overall percentage, reading as a
backward jump every time a new batch started.

Compute initialPercent from batchOffset / totalArticles when available,
falling back to 5 for single-batch files (uploaded PDFs, txts) where
totalArticles isn't set. Capped at 99 to leave headroom for the 100%
final-batch marker.

Follow-up to PR #880 (which fixed the 0-100% scaling during a batch
but still had the initial-frame regression).
2026-05-15 23:01:45 -07:00
..
check_service_updates_job.ts fix(queue): singleton QueueService to stop ioredis connection leak 2026-05-13 13:48:21 -07:00
check_update_job.ts fix(queue): singleton QueueService to stop ioredis connection leak 2026-05-13 13:48:21 -07:00
download_model_job.ts fix(queue): singleton QueueService to stop ioredis connection leak 2026-05-13 13:48:21 -07:00
embed_file_job.ts fix(RAG): anchor continuation-batch initial progress to overall-file frame (#889) 2026-05-15 23:01:45 -07:00
run_benchmark_job.ts fix(queue): singleton QueueService to stop ioredis connection leak 2026-05-13 13:48:21 -07:00
run_download_job.ts fix(queue): singleton QueueService to stop ioredis connection leak 2026-05-13 13:48:21 -07:00
run_extract_pmtiles_job.ts fix(queue): singleton QueueService to stop ioredis connection leak 2026-05-13 13:48:21 -07:00