Add extra documentation

This commit is contained in:
Andres Caicedo
2023-04-03 14:10:02 +02:00
parent 8e2074f483
commit 765210f0cd
7 changed files with 18 additions and 3 deletions

View File

@@ -6,6 +6,7 @@ from llm_utils import create_chat_completion
# This is a magic function that can do anything with no-code. See
# https://github.com/Torantulino/AI-Functions for more info.
def call_ai_function(function, args, description, model=cfg.smart_llm_model):
"""Call an AI function with the given args and description."""
# For each arg, if any are None, convert to "None":
args = [str(arg) if arg is not None else "None" for arg in args]
# parse args to comma seperated string