-
Notifications
You must be signed in to change notification settings - Fork 236
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 notebook for Messages API usage walkthrough #28
Conversation
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
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. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a great code example and it's super useful! But I feel that it sounds too much like a marketing pitch. Let's update the markdown descriptions to transform it into a tutorial-style notebook. Some suggestions:
re: Title: let's make it clearer and more task-oriented, e.g. "Migrating from OpenAI models to Open Source LLMs"
Instead of "We are excited to introduce", explain in the introduction what this tutorial is about. E.g. "In this tutorial you'll learn how to use Messages API from TGI (available in version X) to smoothly transition from OpenAI models to any open-source LLM without having to rewrite your existing scripts". Later in the notebook, you have a paragraph that actually would be great in the intro: "Messages support in TGI makes Inference Endpoints directly compatible with the OpenAI Chat Completion API. This means that any existing scripts that use OpenAI models via the OpenAI client libraries can be directly swapped out to use any open LLM running on a TGI endpoint!
With this seamless transition, you can immediately take advantage of the numerous benefits offered by open models:
Complete control and transparency over models and data
No more worrying about rate limits
The ability to fully customize systems according to your specific needs
“
Let's remove the quote from Johny Crupi.
The rest is great, please review the text and update the style to technical tutorial in places where it sounds like a marketing pitch.
notebooks/en/index.md
Outdated
@@ -12,6 +12,7 @@ Check out the recently added notebooks: | |||
- [Fine-tuning a Code LLM on Custom Code on a single GPU](fine_tuning_code_llm_on_single_gpu) | |||
- [RAG Evaluation Using Synthetic data and LLM-As-A-Judge](rag_evaluation) | |||
- [Advanced RAG on HuggingFace documentation using LangChain](advanced_rag) | |||
- [From OpenAI to Open LLMs with Messages API on Hugging Face](tgi_messages_api_demo) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since it'll be the latest added notebook, add it at the top of the list, please
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call! c9a853e
@MKhalusova Thanks for the review and feedback! The reason it sounded so "marketing pitchy" is because it was the exact content from the blog post 😄 I just revamped the wording so its more of a tutorial tone and merged the upstream changes. I think this should be good to go after a quick final review from you. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work re-styling the notebook! Let's merge it :)
What does this PR do?
Adds a notebook that demonstrates how to use the new Messages API functionality from TGI with Inference Endpoints + several client libraries (openai, langchain, llamaindex).
Who can review?
@MKhalusova