feat: hf chat completion plugin support #3
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
support for the HF API integration https://huggingface.co/docs/api-inference/en/tasks/chat-completion?code=curl and completes #4
AI-Generated Summary
PR Summary
Overview of Changes
Avast, me hearties! We've hoisted the sails and charted a course through the sea of code, making noteworthy changes and additions to our sturdy ship, the
burpferenceAPI adapters. With an eye on the horizon, we've added support for HuggingFace API, refined how we cast our request and response handling across the broadside of existing API adapters, and included updates to our treasure map (configs and documentation) to ensure that any soul, be they a seasoned sea dog or a landlubber, can make use of our arsenal of tools for code review and inference.Key Modifications
HuggingFaceAPIAdapter, setting it up to prepare requests and handle responses for the HuggingFace Serveless Inference API. This includes handling parameters such asmax_length,temperature,top_p, andrepetition_penalty.bigcode/starcodermodel. A new JSON file for the HuggingFace configuration has also been committed to the repository, making it a breeze to configure for those wishing to employ HuggingFace for their code reviewing needs.Potential Impact
burpferencefor developers and researchers, allowing for a broader range of API services to be used, specifically adding the capability to integrate with HuggingFace's inference API.This summary was generated with ❤️ by rigging