Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to find in specific vector #77

Open
roysG opened this issue Jun 15, 2024 · 0 comments
Open

How to find in specific vector #77

roysG opened this issue Jun 15, 2024 · 0 comments

Comments

@roysG
Copy link

roysG commented Jun 15, 2024

I defined 2 custom vector in collcection, for example:
image and msg

When i try to find the vector in msg, i get error Bad Request.

This is how the code looks:

First i defined the settings vector:

await client.createCollection(collectionName, {
vectors: {
msg:{
size: 384,
distance: 'Cosine',
},
size: 4,
distance: 'Cosine',
},
optimizers_config: {
default_segment_number: 2,
},
replication_factor: 2,
});

Then i tried to search:

const res1 = await client.search(collectionName, {
vector: { "vector": { "vector": [1.0, 2.0, 3.0], "name": "msg" } },
limit: 3,
});

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

No branches or pull requests

1 participant