Hugging Face Launches OpenAI-Compatible Messages API
Key point
Hugging Face has launched a Messages API compatible with the OpenAI API to support transitions to open LLMs.
Details
Hugging Face has introduced the Messages API, compatible with OpenAI's Chat Completion API, in Text Generation Inference (TGI) and Inference Endpoints.
With this update, developers can keep using their existing OpenAI client libraries or tools like LangChain and LlamaIndex without modification, while easily swapping out the model from OpenAI to open source LLMs such as Mixtral or Llama 2.
Key points:
- Scope of support: Supported from TGI version 1.4.0 onward, and available in both dedicated and serverless environments of Inference Endpoints.
- Limitations: Function Calling is not currently supported, and it only works with models that have
chat_templatedefined in their tokenizer configuration.
This summary was generated automatically by AI. Check the original for the author's claims and context. Copyright belongs to the original author.
Our guide explains how the AI works. Report summary errors, attribution issues, or removal requests via Contact.