langchain_community.chat_models.azureml_endpoint
.LlamaContentFormatter¶
- class langchain_community.chat_models.azureml_endpoint.LlamaContentFormatter[source]¶
Content formatter for LLaMA.
Attributes
SUPPORTED_ROLES
accepts
The MIME type of the response data returned from the endpoint
content_type
The MIME type of the input data passed to the endpoint
Methods
__init__
()escape_special_characters
(prompt)Escapes any special characters in prompt
format_request_payload
(prompt, model_kwargs)Formats the request according to the chosen api
format_response_payload
(output)Formats response
- __init__()¶
- static escape_special_characters(prompt: str) str ¶
Escapes any special characters in prompt