Documentation
¶
Index ¶
- type Client
- func (c *Client) BatchUpdate(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.BatchUpdateResponse, error)
- func (c *Client) ClearPayload(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.ClearPayloadResponse, error)
- func (c *Client) CountPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.CountPointsResponse, error)
- func (c *Client) DeletePayload(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.DeletePayloadResponse, error)
- func (c *Client) DeletePoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.DeletePointsResponse, error)
- func (c *Client) DeleteVectors(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.DeleteVectorsResponse, error)
- func (c *Client) DiscoverBatchPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.DiscoverBatchPointsResponse, error)
- func (c *Client) DiscoverPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.DiscoverPointsResponse, error)
- func (c *Client) GetPoint(ctx context.Context, collectionName string, id *hookdeckgosdk.ExtendedPointId) (*hookdeckgosdk.GetPointResponse, error)
- func (c *Client) GetPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.GetPointsResponse, error)
- func (c *Client) OverwritePayload(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.OverwritePayloadResponse, error)
- func (c *Client) RecommendBatchPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.RecommendBatchPointsResponse, error)
- func (c *Client) RecommendPointGroups(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.RecommendPointGroupsResponse, error)
- func (c *Client) RecommendPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.RecommendPointsResponse, error)
- func (c *Client) ScrollPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.ScrollPointsResponse, error)
- func (c *Client) SearchBatchPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.SearchBatchPointsResponse, error)
- func (c *Client) SearchPointGroups(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.SearchPointGroupsResponse, error)
- func (c *Client) SearchPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.SearchPointsResponse, error)
- func (c *Client) SetPayload(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.SetPayloadResponse, error)
- func (c *Client) UpdateVectors(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.UpdateVectorsResponse, error)
- func (c *Client) UpsertPoints(ctx context.Context, collectionName string, ...) (*hookdeckgosdk.UpsertPointsResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(opts ...core.ClientOption) *Client
func (*Client) BatchUpdate ¶
func (c *Client) BatchUpdate(ctx context.Context, collectionName string, request *hookdeckgosdk.UpdateOperations) (*hookdeckgosdk.BatchUpdateResponse, error)
Apply a series of update operations for points, vectors and payloads
Name of the collection to apply operations on
func (*Client) ClearPayload ¶
func (c *Client) ClearPayload(ctx context.Context, collectionName string, request *hookdeckgosdk.ClearPayloadRequest) (*hookdeckgosdk.ClearPayloadResponse, error)
Remove all payload for specified points
Name of the collection to clear payload from
func (*Client) CountPoints ¶
func (c *Client) CountPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.CountRequest) (*hookdeckgosdk.CountPointsResponse, error)
Count points which matches given filtering condition
Name of the collection to count in
func (*Client) DeletePayload ¶
func (c *Client) DeletePayload(ctx context.Context, collectionName string, request *hookdeckgosdk.DeletePayloadRequest) (*hookdeckgosdk.DeletePayloadResponse, error)
Delete specified key payload for points
Name of the collection to delete from
func (*Client) DeletePoints ¶
func (c *Client) DeletePoints(ctx context.Context, collectionName string, request *hookdeckgosdk.DeletePointsRequest) (*hookdeckgosdk.DeletePointsResponse, error)
Delete points
Name of the collection to delete from
func (*Client) DeleteVectors ¶
func (c *Client) DeleteVectors(ctx context.Context, collectionName string, request *hookdeckgosdk.DeleteVectorsRequest) (*hookdeckgosdk.DeleteVectorsResponse, error)
Delete named vectors from the given points.
Name of the collection to delete from
func (*Client) DiscoverBatchPoints ¶
func (c *Client) DiscoverBatchPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.DiscoverRequestBatch) (*hookdeckgosdk.DiscoverBatchPointsResponse, error)
Look for points based on target and/or positive and negative example pairs, in batch.
Name of the collection to search in
func (*Client) DiscoverPoints ¶
func (c *Client) DiscoverPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.DiscoverPointsRequest) (*hookdeckgosdk.DiscoverPointsResponse, error)
Use context and a target to find the most similar points to the target, constrained by the context. When using only the context (without a target), a special search - called context search - is performed where pairs of points are used to generate a loss that guides the search towards the zone where most positive examples overlap. This means that the score minimizes the scenario of finding a point closer to a negative than to a positive part of a pair. Since the score of a context relates to loss, the maximum score a point can get is 0.0, and it becomes normal that many points can have a score of 0.0. When using target (with or without context), the score behaves a little different: The integer part of the score represents the rank with respect to the context, while the decimal part of the score relates to the distance to the target. The context part of the score for each pair is calculated +1 if the point is closer to a positive than to a negative part of a pair, and -1 otherwise.
Name of the collection to search in
func (*Client) GetPoint ¶
func (c *Client) GetPoint(ctx context.Context, collectionName string, id *hookdeckgosdk.ExtendedPointId) (*hookdeckgosdk.GetPointResponse, error)
Retrieve full information of single point by id
Name of the collection to retrieve from Id of the point
func (*Client) GetPoints ¶
func (c *Client) GetPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.PointRequest) (*hookdeckgosdk.GetPointsResponse, error)
Retrieve multiple points by specified IDs
Name of the collection to retrieve from
func (*Client) OverwritePayload ¶
func (c *Client) OverwritePayload(ctx context.Context, collectionName string, request *hookdeckgosdk.OverwritePayloadRequest) (*hookdeckgosdk.OverwritePayloadResponse, error)
Replace full payload of points with new one
Name of the collection to set from
func (*Client) RecommendBatchPoints ¶
func (c *Client) RecommendBatchPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.RecommendRequestBatch) (*hookdeckgosdk.RecommendBatchPointsResponse, error)
Look for the points which are closer to stored positive examples and at the same time further to negative examples.
Name of the collection to search in
func (*Client) RecommendPointGroups ¶
func (c *Client) RecommendPointGroups(ctx context.Context, collectionName string, request *hookdeckgosdk.RecommendGroupsRequest) (*hookdeckgosdk.RecommendPointGroupsResponse, error)
Look for the points which are closer to stored positive examples and at the same time further to negative examples, grouped by a given payload field.
Name of the collection to search in
func (*Client) RecommendPoints ¶
func (c *Client) RecommendPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.RecommendPointsRequest) (*hookdeckgosdk.RecommendPointsResponse, error)
Look for the points which are closer to stored positive examples and at the same time further to negative examples.
Name of the collection to search in
func (*Client) ScrollPoints ¶
func (c *Client) ScrollPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.ScrollRequest) (*hookdeckgosdk.ScrollPointsResponse, error)
Scroll request - paginate over all points which matches given filtering condition
Name of the collection to retrieve from
func (*Client) SearchBatchPoints ¶
func (c *Client) SearchBatchPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.SearchRequestBatch) (*hookdeckgosdk.SearchBatchPointsResponse, error)
Retrieve by batch the closest points based on vector similarity and given filtering conditions
Name of the collection to search in
func (*Client) SearchPointGroups ¶
func (c *Client) SearchPointGroups(ctx context.Context, collectionName string, request *hookdeckgosdk.SearchGroupsRequest) (*hookdeckgosdk.SearchPointGroupsResponse, error)
Retrieve closest points based on vector similarity and given filtering conditions, grouped by a given payload field
Name of the collection to search in
func (*Client) SearchPoints ¶
func (c *Client) SearchPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.SearchPointsRequest) (*hookdeckgosdk.SearchPointsResponse, error)
Retrieve closest points based on vector similarity and given filtering conditions
Name of the collection to search in
func (*Client) SetPayload ¶
func (c *Client) SetPayload(ctx context.Context, collectionName string, request *hookdeckgosdk.SetPayloadRequest) (*hookdeckgosdk.SetPayloadResponse, error)
Set payload values for points
Name of the collection to set from
func (*Client) UpdateVectors ¶
func (c *Client) UpdateVectors(ctx context.Context, collectionName string, request *hookdeckgosdk.UpdateVectorsRequest) (*hookdeckgosdk.UpdateVectorsResponse, error)
Update specified named vectors on points, keep unspecified vectors intact.
Name of the collection to update from
func (*Client) UpsertPoints ¶
func (c *Client) UpsertPoints(ctx context.Context, collectionName string, request *hookdeckgosdk.UpsertPointsRequest) (*hookdeckgosdk.UpsertPointsResponse, error)
Perform insert + updates on points. If point with given ID already exists - it will be overwritten.
Name of the collection to update from