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

More MessageDB improvements, including timestamp constraints in getting chatlog (messages since timestamp) #67

Merged
merged 6 commits into from
Jan 21, 2024

Conversation

uogbuji
Copy link
Collaborator

@uogbuji uogbuji commented Jan 15, 2024

Implement pgvector_message.get_chatlog(), with support for date constraint & limit, while deprecating pgvector_message.get_table(). Tidy up embedding tests with more use of fixtures & teardown.

…rint & limit, while depecating pgvector_message.get_table(). Tidy up embedding tests with more use of fixtures & teardown
@uogbuji uogbuji requested a review from choccccy January 15, 2024 03:58
@uogbuji
Copy link
Collaborator Author

uogbuji commented Jan 15, 2024

Probably good to merge to main. @choccccy while you review, notice my SQL schema mods. I removed the ON CONFLICT clause in this case. It's OK in theory for multiple identical chat log entries to be added, though of course that's unrealistic for actual real-world chat media. I didn't look at any other uses of ON CONFLICT, but I shall when I get a chance.

@uogbuji uogbuji mentioned this pull request Jan 21, 2024
3 tasks
history_key: UUID
) -> list[asyncpg.Record]:
history_key: UUID | str,
since: datetime | None = None,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

huh, the since arg is cool

@uogbuji uogbuji merged commit c25f6d6 into main Jan 21, 2024
2 checks passed
@choccccy choccccy deleted the messages-since branch January 22, 2024 18:55
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.

2 participants