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

Auxiliary column support #123

Merged
merged 37 commits into from
Nov 20, 2024
Merged

Auxiliary column support #123

merged 37 commits into from
Nov 20, 2024

Conversation

asg017
Copy link
Owner

@asg017 asg017 commented Oct 15, 2024

References #121 , requires #122 .

Work in progress, still needs more bug fixing, docs, and tests.

create virtual table vec_chunks using vec0(
  chunk_id integer primary key,
  +contents text,
  contents_embeddings float[1024],
);

select chunk_id, contents, distance
from vec_chunks
where contents_embedding match '[...]'
  and user_id = 123
  and k = 5;
/*
┌──────────┬──────────────────────────────────────────────────────────────┬──────────┐
│ chunk_id │                           contents                           │ distance │
├──────────┼──────────────────────────────────────────────────────────────┼──────────┤
│ 20       │ 'Managers are responsible for tracking their team members''  │ 1.0      │
│          │ PTO usage.'                                                  │          │
├──────────┼──────────────────────────────────────────────────────────────┼──────────┤
│ 17       │ 'Part-time employees are eligible for PTO on a pro-rata basi │ 2.0      │
│          │ s.'                                                          │          │
├──────────┼──────────────────────────────────────────────────────────────┼──────────┤
│ 15       │ 'All PTO balances will be displayed on the employee self-ser │ 4.0      │
│          │ vice portal.'                                                │          │
├──────────┼──────────────────────────────────────────────────────────────┼──────────┤
│ 5        │ 'PTO must be used in increments of at least 4 hours.'        │ 14.0     │
├──────────┼──────────────────────────────────────────────────────────────┼──────────┤
│ 4        │ 'Unused PTO can be carried over to the following year, up to │ 15.0     │
│          │  a maximum of 40 hours.'                                     │          │
└──────────┴──────────────────────────────────────────────────────────────┴──────────┘
*/

@asg017 asg017 mentioned this pull request Oct 15, 2024
@asg017 asg017 marked this pull request as ready for review November 20, 2024 05:47
@asg017 asg017 changed the title DRAFT: Auxiliary column support Auxiliary column support Nov 20, 2024
@asg017 asg017 changed the base branch from partition-by to main November 20, 2024 08:02
@asg017
Copy link
Owner Author

asg017 commented Nov 20, 2024

yolo

@asg017 asg017 merged commit 9bfeaa7 into main Nov 20, 2024
17 checks passed
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

Successfully merging this pull request may close these issues.

1 participant