mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 10:44:24 +00:00
Docstring
This commit is contained in:
parent
8d01f91056
commit
d0fe1a8906
1 changed files with 3 additions and 2 deletions
|
@ -1802,10 +1802,11 @@ def create_tokenizer(json: str):
|
|||
tokenizer = Tokenizer.from_str(json)
|
||||
return {"type": "huggingface_tokenizer", "tokenizer": tokenizer}
|
||||
|
||||
# Based on https://github.com/forestwanglin/openai-java/blob/main/jtokkit/src/main/java/xyz/felh/openai/jtokkit/utils/TikTokenUtils.java
|
||||
|
||||
|
||||
def _format_function_definitions(tools):
|
||||
"""Formats tool definitions in the format that OpenAI appears to use.
|
||||
Based on https://github.com/forestwanglin/openai-java/blob/main/jtokkit/src/main/java/xyz/felh/openai/jtokkit/utils/TikTokenUtils.java
|
||||
"""
|
||||
lines = []
|
||||
lines.append("namespace functions {")
|
||||
lines.append("")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue