project-nomad/admin
chriscrosstalk 7472442ae8
fix(kb): keep the collection when a file is indexed after assignment (#1200)
Assigning a collection before indexing lost it silently. The per-row
value still showed, but Manage Collections and the Search in dropdown
stayed empty, because getKnowledgeCollections() facets on the Qdrant
payload while only MySQL had been written.

Five gaps on one path:

updateFileCollection() sets the payload filtered on `source`, which
matches nothing before the file is indexed. It also only persisted to
kb_ingest_state `if (row)`, so a file with no row stored the value
nowhere at all and still returned "Moved to ...".

Six of the seven EmbedFileJob.dispatch sites never pass `collection`,
and none read the existing row, so Index dispatched a job with no
knowledge of the assignment. The ZIM branch of processAndEmbedFile then
dropped `collection` even when the job had one, so ZIM content could
never be tagged at embed time by any path. Batch continuations dropped
it too, which would have tagged only batch 1.

Resolve the effective collection once inside EmbedFileJob.handle rather
than at seven call sites, thread it through the ZIM path into the point
payload, carry it across batch continuations, and make the pre-index
assignment durable with getOrCreate.

Verified end to end on a test appliance: assigned a collection to an
unindexed ZIM, indexed it across multiple batch continuations, and all
6106 chunks carry the tag.
2026-08-04 03:40:01 +00:00
..
app fix(kb): keep the collection when a file is indexed after assignment (#1200) 2026-08-04 03:40:01 +00:00
bin
commands
config
constants
database feat(benchmark): official multi-arch sysbench, resolved digest, platform metadata (#1158) 2026-08-04 03:39:53 +00:00
docs docs: update release notes 2026-08-04 03:39:59 +00:00
inertia fix(kb): stop the collection dropdown being clipped, widen the modal (#1198) 2026-08-04 03:40:00 +00:00
providers
public
resources
scripts
start
tests feat: support gated downloads for self-hosted curated content (#1172) 2026-08-04 03:39:55 +00:00
types feat: support gated downloads for self-hosted curated content (#1172) 2026-08-04 03:39:55 +00:00
util
views
.editorconfig
.env.example
ace.js
adonisrc.ts
eslint.config.js
package-lock.json
package.json
tailwind.config.ts
tsconfig.json
vite.config.ts