Skip to content

Commit

Permalink
Fix(Indexing): Improve error reporting for missing data during vector…
Browse files Browse the repository at this point in the history
… searches (#60)

Description: If the vector parameter in a similar_to function call is a
variable that evaluates to NULL then we report it as a parsing (syntax)
error.

The fix, instead of reporting a parsing error,  returns an empty result.

Closes: HYP-302

---------

Co-authored-by: Bill Province <billprovince@gmail.com>
  • Loading branch information
2 people authored and harshil-goel committed Apr 17, 2024
1 parent 93c5596 commit db980de
Show file tree
Hide file tree
Showing 2 changed files with 605 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# simple user product GraphQL API - v0.4

type Product {
id: String! @id
description: String
title: String
imageUrl: String
product_vector: [Float] @hm_embedding
}

type Purchase @lambdaOnMutate(add: true){
user: User @hasInverse(field: "purchase_history")
product: Product
date: DateTime @search(by: [day])
}

type User {
email: String! @id
purchase_history: [Purchase]
user_vector: [Float] @hm_embedding
}
Loading

0 comments on commit db980de

Please sign in to comment.