Skip to content

Commit

Permalink
Deprecate annoy (#5541)
Browse files Browse the repository at this point in the history
  • Loading branch information
kellen authored Jan 16, 2025
1 parent e88e454 commit 97797ea
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,7 @@ package object annoy {
* @param dim
* Number of dimensions in vectors used to build the Annoy index
*/
@deprecated("Use voyager instead", "0.14.11")
@experimental
def annoySideInput(path: String, metric: AnnoyMetric, dim: Int): SideInput[AnnoyReader] = {
val uri = AnnoyUri(path, self.options)
Expand Down Expand Up @@ -175,6 +176,7 @@ package object annoy {
* @return
* A singleton SCollection containing the [[AnnoyUri]] of the saved files
*/
@deprecated("Use voyager instead", "0.14.11")
@experimental
def asAnnoy(path: String, metric: AnnoyMetric, dim: Int, nTrees: Int): SCollection[AnnoyUri] = {
val uri = AnnoyUri(path, self.context.options)
Expand Down Expand Up @@ -217,6 +219,7 @@ package object annoy {
* @return
* A singleton SCollection containing the [[AnnoyUri]] of the saved files
*/
@deprecated("Use voyager instead", "0.14.11")
@experimental
def asAnnoy(metric: AnnoyMetric, dim: Int, nTrees: Int): SCollection[AnnoyUri] = {
val uuid = UUID.randomUUID()
Expand All @@ -242,6 +245,7 @@ package object annoy {
* @return
* SideInput[AnnoyReader]
*/
@deprecated("Use voyager instead", "0.14.11")
@experimental
def asAnnoySideInput(metric: AnnoyMetric, dim: Int, nTrees: Int): SideInput[AnnoyReader] =
self.asAnnoy(metric, dim, nTrees).asAnnoySideInput(metric, dim)
Expand All @@ -261,6 +265,7 @@ package object annoy {
* @return
* SideInput[AnnoyReader]
*/
@deprecated("Use voyager instead", "0.14.11")
@experimental
def asAnnoySideInput(metric: AnnoyMetric, dim: Int): SideInput[AnnoyReader] = {
val view = self.applyInternal(View.asSingleton())
Expand Down
2 changes: 2 additions & 0 deletions site/src/main/paradox/extras/Annoy.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Annoy

** Deprecated since Scio 0.14.11 **

Scio integrates with Spotify's [Annoy](https://github.com/spotify/annoy), an approximate nearest neighbors library, via [annoy-java](https://github.com/spotify/annoy-java) and [annoy4s](https://github.com/annoy4s/annoy4s).

## Write
Expand Down

0 comments on commit 97797ea

Please sign in to comment.