weaviate / typescript-client

Official Weaviate TypeScript Client
https://www.npmjs.com/package/weaviate-ts-client
BSD 3-Clause "New" or "Revised" License
57 stars 21 forks source link

Hybrid search is missing target vectors #113

Closed joshdschneider closed 3 months ago

joshdschneider commented 3 months ago

I'm unable to pass target vectors in a hybrid search query. Here's an example:

const result = await client.graphql
  .get()
  .withClassName('WineReviewNV')
  .withHybrid({
    query: 'a sweet German white wine',
    targetVectors: ['title_country'],
  })
  .withLimit(2)
  .withFields('title review_body country')
  .do();

console.log(JSON.stringify(result, null, 2));

It looks like it's missing from the GraphQLHybrid class. I'll go ahead and open a PR to fix.