Skip to content

Conversation

@abhinavdangeti abhinavdangeti added this to the v2.6.0 milestone Jul 28, 2025
@abhinavdangeti abhinavdangeti changed the title MB-66396: IndexSnapshot API to retrieve highest frequency terms MB-66396: IndexSnapshot APIs for high freq terms + high cardinality centroids Aug 12, 2025
@abhinavdangeti abhinavdangeti force-pushed the mb66396 branch 2 times, most recently from 87e97aa to 9a7378d Compare August 12, 2025 23:14
@abhinavdangeti abhinavdangeti changed the title MB-66396: IndexSnapshot APIs for high freq terms + high cardinality centroids MB-66396: Index APIs for HighestFrequencyTerms and HighestCardinalityCentroids Aug 18, 2025
@abhinavdangeti abhinavdangeti changed the title MB-66396: Index APIs for HighestFrequencyTerms and HighestCardinalityCentroids MB-66396: Index APIs for TermFrequencies and CentroidCardinalities Aug 22, 2025
@abhinavdangeti abhinavdangeti marked this pull request as ready for review August 22, 2025 21:16
return nil
}

func (i *IndexSnapshot) CentroidCardinalities(field string, limit int, descending bool) (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because this function is in snapshot_index_vr.go, the method wouldn't be included in IndexSnapshot if the vectors flag is turned off. So it wouldn't be an implementation of IndexInsightsReader anymore. Calls to TermFrequencies in index_impl.go would then fail because the code checks if the interface is implemented for the reader.

Basically, TermFrequencies would only work if it is compiled with vectors, is this intended?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ya it was intentional - because the insights project is meant for AI applications which will use this alongside vector data. This is just a start though, hoping to add more functions to the interface.

@abhinavdangeti
Copy link
Member Author

Thanks @CascadingRadium for the review so far, will push up a patch reflecting on your comments soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants