With semantic search, there is no binary attribute which says whether a record matches or not (unlike in keyword search). Instead every record in the dataset has a "degree of semantic closeness" to the query. So the record with Amazon is still ranked for the query, since it exists in the dataset and matches the provided filter of
num_employees > 100
.
To remove "far away" matches from semantic search, you need to use the
distance_threshold
parameter inside vector query to set a cutoff:
https://typesense.org/docs/27.1/api/vector-search.html#distance-threshold