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

Add a RAG via Elasticsearch, Hugging Face models cookbook #124

Merged
merged 8 commits into from
Jun 26, 2024

Conversation

lloydmeta
Copy link
Contributor

@lloydmeta lloydmeta commented Jun 21, 2024

What does this PR do?

I thought it would be useful to provide a cookbook for a RAG backed by Elasticsearch, Hugging Face models, and Gemma.

Users can easily toggle between vectorisation that is offloaded to ES and self-provided (pre)-vectorisation.

Who can review?

Feel free to tag members/contributors who may be interested in your PR.

Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

I thought it would be useful to provide a cookbook for a RAG
backed by Elasticsearch, Huggingface models, and Gemma.

Users can easily toggle between vectorisation that is offloaded
to ES and self-provided (pre)-vectorisation.

This is based on the excellent MongoDB notebook and dataset.

Signed-off-by: lloydmeta <[email protected]>
@lloydmeta lloydmeta changed the title Add an RAG via Elasticsearch, u cookbook Add an RAG via Elasticsearch, Huggingface models cookbook Jun 22, 2024
@lloydmeta lloydmeta changed the title Add an RAG via Elasticsearch, Huggingface models cookbook Add a RAG via Elasticsearch, Huggingface models cookbook Jun 22, 2024
@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

Copy link
Member

@stevhliu stevhliu left a comment

Choose a reason for hiding this comment

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

Nice work! 👏

Signed-off-by: lloydmeta <[email protected]>
@lloydmeta
Copy link
Contributor Author

Thanks for your thorough review @stevhliu 🙇‍♂️

As noted above, the image change requires merging https://huggingface.co/datasets/huggingface/cookbook-images/discussions/20

@lloydmeta lloydmeta requested a review from stevhliu June 25, 2024 01:09
@lloydmeta lloydmeta changed the title Add a RAG via Elasticsearch, Huggingface models cookbook Add a RAG via Elasticsearch, Hugging Face models cookbook Jun 25, 2024
Copy link
Member

@stevhliu stevhliu left a comment

Choose a reason for hiding this comment

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

Just a few more minor changes and then I think we're ready to merge! 🙂

Signed-off-by: lloydmeta <[email protected]>
@lloydmeta lloydmeta requested a review from stevhliu June 26, 2024 03:05
@lloydmeta
Copy link
Contributor Author

Thanks @stevhliu , really appreciate your patience in this review; it's my first Jupyter notebook PR and I'm not used to the UI (e.g. accidentally adding a blank cell 🤦🏻‍♂️) and the way diffs/suggestions are shown.

Copy link
Collaborator

@merveenoyan merveenoyan left a comment

Choose a reason for hiding this comment

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

thanks a lot! left a nit :)

Move the embedding and embedding model-related settings down.

Add some links and info

Signed-off-by: lloydmeta <[email protected]>
* Fix Eland version to avoid breaking changes
* Switch to CPU usage by default

Signed-off-by: lloydmeta <[email protected]>
Signed-off-by: lloydmeta <[email protected]>
Copy link
Member

@stevhliu stevhliu left a comment

Choose a reason for hiding this comment

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

Great work and thanks again for the notebook! 👏

@stevhliu stevhliu merged commit 044ce89 into huggingface:main Jun 26, 2024
1 check 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.

None yet

4 participants