Fast-forward-indexes

Latest version: v0.5.1

Safety actively analyzes 681812 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

0.5.1

- `Ranking.interpolate` and `Ranking.__add__` (`+` operator) now treat missing scores in either ranking as zero.

0.5.0

Ranking operations
- Rankings now implement the `+` and `*` operators.
- Rankings can now be normalized via `Ranking.normalize` (min-max normalization).
- Reciprocal rank fusion is now supported via `Ranking.rr_scores`.

Misc
- `Index.__call__` now accepts a `batch_size` argument.

0.4.1

- Fixed a bug where `OnDiskIndex` would not respect the `resize_min_val` argument properly.
- Fixed a bug where `Indexer.from_dicts` would ignore the encoder batch size in some cases.
- Minor updates in the documentation for `Indexer`.

0.4.0

Indexer

- Now supports transferring vectors from one index to another.
- Now supports automatically training a quantizer during indexing.
- The encoder has been made optional.

API changes

- `Indexer.index_dicts` has been renamed to `Indexer.from_dicts`.
- `Indexer` now takes a `batch_size` and an `encoder_batch_size`.
- `Index.__call__`: `early_stopping_intervals` has been renamed to `early_stopping_depths`.
- `OnDiskIndex`: `ds_buffer_size` has been renamed to `max_indexing_size`.
- `OnDiskIndex.to_memory`: `buffer_size` has been renamed to `batch_size`.
- `util.create_coalesced_index`: `buffer_size` has been renamed to `batch_size`.

0.3.1

- Optimized product quantization has been implemented via `fast_forward.quantizer.nanopq.NanoOPQ`.
- `Index.quantizer` property has been added, allowing to attach a quantizer to an empty existing index.
- Some outdated code snippets in the documentation have been fixed.

0.3.0

Index operations
- When calling `Index.add`, the sequences `doc_ids` and `psg_ids` can now contain `None` elements, as long as each vector has at least one ID.
- Indexes (vectors and corresponding IDs) can now be iterated over using `Index.batch_iter` and `Index.__iter__`.

Vector quantization
- Indexes now support vector quantization via the `fast_forward.quantizer.Quantizer` interface.
- `fast_forward.quantizer.nanopq.NanoPQ` implements product quantization based on [nanopq](https://github.com/matsui528/nanopq).

Misc
- The default ranking mode has been changed to `MAXP`.

API changes
- The `dim` argument has been removed from `OnDiskIndex` and `InMemoryIndex`.
- The `dtype` argument has been removed from `OnDiskIndex`.

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.