MCPcopy Create free account

hub / github.com/AtakanTekparmak/agento / functions

Functions44 in github.com/AtakanTekparmak/agento

↓ 6 callersFunctionprocess_results
Process the results of a function call session to remove the history from the results and remove any list of ChatMessages from the variables.
agento/engine.py:87
↓ 5 callersFunctionexecute_python_code
Execute Python code with given functions and context variables, and return the results of function calls and variables defined in the code.
agento/engine.py:5
↓ 4 callersFunctionload_system_prompt
Loads the system prompt from the specified file.
agento/utils.py:60
↓ 3 callersFunctionAgent
Function to create an agent. The process() function is the main function that is called to process the user query and/or history. The p
agento/agent.py:12
↓ 3 callersFunctioncreate_functions_schema
Creates the functions schema for the prompt.
agento/utils.py:32
↓ 3 callersFunctionextract_python_code
Extracts Python code from the given content. Args: content (str): The content to extract Python code from. Returns: Tup
agento/utils.py:14
↓ 3 callersFunctionformat_agent_name
Format the agent name into snake case. Args: agent_name (str): The name of the agent. Returns: str: The formatted agent
agento/utils.py:142
↓ 2 callersFunctionchat
Get a chat completion from the specified provider. Args: messages (List[ChatMessage]): The messages to send to the client. m
agento/client.py:19
↓ 2 callersFunctioncreate_transfer_function
Create the transfer functions. Used for an agent with a team to transfer the task to the next agent. Args: team
agento/agent.py:41
↓ 2 callersFunctionis_list_of_chat_messages
Check if the object is a list of ChatMessages or is a tuple of (str, list[ChatMessage]). Args: obj (Any): The object to
agento/engine.py:98
↓ 2 callersFunctionprint_history
Prints the chat history in a nice and readable format using Rich. Args: history (List[ChatMessage]): The chat history to print.
agento/utils.py:107
↓ 1 callersFunctionadd_messages_to_history
Add messages to the history. This method is used to add the messages from a sub-agent to the history of the main agent. Args:
agento/client.py:48
↓ 1 callersFunctioninit_or_update_history
If the history is empty, create a new history with the system prompt. If the history is not empty, update the history with the user q
agento/agent.py:84
↓ 1 callersFunctionmake_wrapper
(func_name, func)
agento/engine.py:48
↓ 1 callersFunctionreplace_context_variables
(content: str)
agento/utils.py:76
↓ 1 callersFunctionreplace_functions_schema
(content: str)
agento/utils.py:70
↓ 1 callersFunctionreplace_instructions
(content: str)
agento/utils.py:73
↓ 1 callersFunctionreplace_prompt_beginning
(content: str)
agento/utils.py:79
Functionadd
(a, b)
tests/test_engine.py:14
Functioneat_apples
Eat a certain quantity of apples. Args: apples (List[str]): A list of apples. quantity (int): The quantity of apples to eat.
multi_agent_example.py:17
Functioneat_apples
Eat a certain quantity of apples. Args: apples (List[str]): A list of apples. quantity (int): The quantity of apples to eat.
single_agent_example.py:17
Functionget_apples
Get a certain quantity of apples. Args: quantity (int): The quantity of apples to get. Returns: List[str]: A list of ap
multi_agent_example.py:5
Functionget_apples
Get a certain quantity of apples. Args: quantity (int): The quantity of apples to get. Returns: List[str]: A list of ap
single_agent_example.py:5
Functiongreet
(name)
tests/test_engine.py:35
Functionmock_system_prompt_file
(tmp_path)
tests/test_utils.py:33
Functionmultiply
(a, b)
tests/test_engine.py:17
Functionprocess
Process the user query and update the history using agent: {name}. The process is as follows: 1. The history is i
agento/agent.py:127
Functionsell_apples
Sell all the apples provided. Args: apples (List[str]): A list of apples. Returns: str: The money earned from selling t
multi_agent_example.py:30
Functionsell_apples
Sell all the apples provided. Args: apples (List[str]): A list of apples. Returns: str: The money earned from selling t
single_agent_example.py:30
Functiontest_create_functions_schema
()
tests/test_utils.py:17
Functiontest_execute_python_code_basic
Test the basic execution of Python code.
tests/test_engine.py:5
Functiontest_execute_python_code_with_context_variables
Test the execution of Python code with context variables.
tests/test_engine.py:25
Functiontest_execute_python_code_with_functions
Test the execution of Python code with functions.
tests/test_engine.py:12
Functiontest_execute_python_code_with_functions_and_context
Test the execution of Python code with functions and context variables.
tests/test_engine.py:33
Functiontest_extract_python_code
()
tests/test_utils.py:4
Functiontest_function
This is a test function.
tests/test_utils.py:18
Functiontest_load_system_prompt
(mock_system_prompt_file)
tests/test_utils.py:41
Functiontest_process_results_basic
Test the processing of results without chat messages or history.
tests/test_engine.py:44
Functiontest_process_results_with_chat_messages
Test the processing of results with chat messages.
tests/test_engine.py:65
Functiontest_process_results_with_history
Test the processing of results with history.
tests/test_engine.py:81
Functiontest_process_results_with_invalid_input
Test the processing of results with invalid input.
tests/test_engine.py:96
Functiontest_process_results_with_transfer_to_agent
Test the processing of results with a transfer to agent.
tests/test_engine.py:54
Functiontransfer_to_agent
Transfer the task to the agent with the given name and return the agent's response. Args: task
agento/agent.py:61
Functionwrapper
(*args, **kwargs)
agento/engine.py:49