Commit 96f0096
authored
Use metadata in 'bulk-update-embeddings' (#375)
Why these changes are being introduced:
* With TDA 3.8.0, we can now retrieve record metadata columns in
embeddings read methods. Filtering embeddings by `action="index"`
prevents any attempt to update documents that do not exist
in OpenSearch (`action="delete"`), which results in an API error..
This is important especially with the current state of tim.opensearch.bulk_update,
which will raise a BulkOperationError and cause the 'bulk_update_embeddings'
CLI command to exit early.
This also includes an additional change to also index embeddings
when performing a reindex.
How this addresses that need:
* Filter embeddings by action="index"
* Install latest version of timdex-dataset-api (latest commit)
* Update embeddings in fixtures/test/dataset to use 'embeddings_timestamp"
Side effects of this change:
* None
Relevant ticket(s):
* https://mitlibraries.atlassian.net/browse/USE-2731 parent fc4a958 commit 96f0096
File tree
5 files changed
+55
-31
lines changed- tests
- fixtures/dataset/data/embeddings/year=2025/month=12/day=17
- tim
5 files changed
+55
-31
lines changedSome generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Binary file not shown.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
344 | 344 | | |
345 | 345 | | |
346 | 346 | | |
| 347 | + | |
347 | 348 | | |
348 | 349 | | |
349 | 350 | | |
| 351 | + | |
350 | 352 | | |
351 | 353 | | |
352 | 354 | | |
| |||
362 | 364 | | |
363 | 365 | | |
364 | 366 | | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
365 | 372 | | |
366 | 373 | | |
367 | 374 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
385 | 385 | | |
386 | 386 | | |
387 | 387 | | |
| 388 | + | |
388 | 389 | | |
389 | 390 | | |
390 | 391 | | |
| |||
429 | 430 | | |
430 | 431 | | |
431 | 432 | | |
432 | | - | |
| 433 | + | |
433 | 434 | | |
434 | | - | |
435 | | - | |
436 | | - | |
| 435 | + | |
| 436 | + | |
437 | 437 | | |
438 | 438 | | |
439 | 439 | | |
| |||
454 | 454 | | |
455 | 455 | | |
456 | 456 | | |
457 | | - | |
458 | | - | |
459 | | - | |
| 457 | + | |
460 | 458 | | |
461 | 459 | | |
462 | 460 | | |
| 461 | + | |
463 | 462 | | |
464 | 463 | | |
465 | 464 | | |
| |||
468 | 467 | | |
469 | 468 | | |
470 | 469 | | |
471 | | - | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
472 | 489 | | |
473 | | - | |
| 490 | + | |
474 | 491 | | |
0 commit comments