SYMBOL INDEX (249 symbols across 30 files) FILE: agents/common/core.py class Suitability (line 3) | class Suitability(str, Enum): FILE: agents/protocol_db/main.py function main (line 27) | def main(): function add_protocol (line 41) | def add_protocol(): function get_protocol (line 70) | def get_protocol(): function get_metadata (line 86) | def get_metadata(): function trigger_share (line 107) | def trigger_share(): function load_config (line 121) | def load_config(): function load_memory (line 134) | def load_memory(): function save_memory (line 152) | def save_memory(): function init (line 163) | def init(): FILE: agents/server/config.py function get_additional_info (line 19) | def get_additional_info(): function add_mongo_database (line 22) | def add_mongo_database(external_name, schema): function add_mongo_tools (line 38) | def add_mongo_tools(server_name): function add_sql_database (line 90) | def add_sql_database(table_schemas, server_name): function add_sql_tools (line 131) | def add_sql_tools(name_mappings): function prepare_mock_tool (line 154) | def prepare_mock_tool(tool_schema, internal_name, schema_name): function prepare_external_tool (line 182) | def prepare_external_tool(tool_schema, internal_name, external_server_na... function load_config (line 229) | def load_config(server_name): FILE: agents/server/main.py function call_implementation (line 40) | def call_implementation(protocol_hash, query): function handle_query_suitable (line 55) | def handle_query_suitable(protocol_hash, query): function handle_negotiation (line 71) | def handle_negotiation(raw_query): function handle_query (line 92) | def handle_query(protocol_hash, protocol_sources, query): function main (line 148) | def main(): function wellknown (line 168) | def wellknown(): function register_negotiated_protocol (line 176) | def register_negotiated_protocol(): function requires_negotiation (line 207) | def requires_negotiation(): function init (line 213) | def init(): FILE: agents/server/memory.py function load_memory (line 10) | def load_memory(): function save_memory (line 25) | def save_memory(): function register_new_protocol (line 33) | def register_new_protocol(protocol_hash, protocol_source, protocol_docum... function has_implementation (line 44) | def has_implementation(protocol_hash): function get_num_conversations (line 50) | def get_num_conversations(protocol_hash): function increment_num_conversations (line 56) | def increment_num_conversations(protocol_hash): function add_routine (line 60) | def add_routine(protocol_id, implementation): FILE: agents/user/config.py function get_protocol_db_url (line 10) | def get_protocol_db_url(): function load_standard_config (line 13) | def load_standard_config(user_name): function load_helper_config (line 35) | def load_helper_config(master_server_name): function load_config (line 59) | def load_config(user_name): function get_task (line 66) | def get_task(): FILE: agents/user/main.py function call_using_implementation (line 39) | def call_using_implementation(task_type, task_schema, protocol_id, task_... function main (line 77) | def main(): function run_task (line 100) | def run_task(task_type, task_data, target_server): function run_random_task (line 151) | def run_random_task(): function custom_run (line 157) | def custom_run(): function init (line 175) | def init(): FILE: agents/user/memory.py function load_memory (line 17) | def load_memory(): function save_memory (line 36) | def save_memory(): function get_num_protocol_uses (line 45) | def get_num_protocol_uses(protocol_id): function increment_num_protocol_uses (line 51) | def increment_num_protocol_uses(protocol_id): function get_num_conversations (line 56) | def get_num_conversations(task_type, target_node): function increment_num_conversations (line 65) | def increment_num_conversations(task_type, target_node): function add_routine (line 75) | def add_routine(task_type, protocol_id, implementation): FILE: agents/user/protocol_management.py function query_protocols (line 18) | def query_protocols(target_node): function has_implementation (line 27) | def has_implementation(task_type, protocol_id): function is_adequate (line 36) | def is_adequate(task_type, protocol_id): function is_categorized (line 45) | def is_categorized(task_type, protocol_id): function get_an_adequate_protocol (line 54) | def get_an_adequate_protocol(task_type, eligible_protocols): function categorize_protocol (line 84) | def categorize_protocol(protocol_id, task_type): function prefilter_protocols (line 100) | def prefilter_protocols(protocol_ids, task_type): function register_new_protocol (line 129) | def register_new_protocol(protocol_id, source, protocol_data): function submit_protocol_to_public_db (line 144) | def submit_protocol_to_public_db(protocol_id, protocol_data): function negotiate_protocol (line 158) | def negotiate_protocol(task_type, target_node): function decide_protocol (line 182) | def decide_protocol(task_type, target_node, num_conversations_for_protoc... FILE: compute_costs.py function main (line 14) | def main(): FILE: generate_screenplay.py function generate_discrete_power_law (line 14) | def generate_discrete_power_law(num_values, alpha, min_value, total): function main (line 34) | def main(): FILE: mocks/mock_tasks.py function _random_date (line 4) | def _random_date(): function _random_date_range (line 9) | def _random_date_range(): function queryWeather (line 15) | def queryWeather(): function bookRoom (line 20) | def bookRoom(): function suggestRestaurant (line 27) | def suggestRestaurant(): function rentSki (line 32) | def rentSki(): function currentWeather (line 38) | def currentWeather(): function menu (line 41) | def menu(): function openingTimes (line 44) | def openingTimes(): function bookTable (line 50) | def bookTable(): function orderEverything (line 58) | def orderEverything(): function _get_movie_date (line 63) | def _get_movie_date(): function availableMovies (line 66) | def availableMovies(): function buyTickets (line 73) | def buyTickets(): function callTaxi (line 81) | def callTaxi(): function getTraffic (line 89) | def getTraffic(): FILE: mocks/mock_tools.py function weather (line 4) | def weather(location, date): function currentDate (line 28) | def currentDate(): function getMenu (line 102) | def getMenu(cuisineType): function dayOfTheWeek (line 107) | def dayOfTheWeek(date): function sendDriver (line 113) | def sendDriver(restaurant, address): function trafficInfo (line 118) | def trafficInfo(date, location): function getAvailableTaxi (line 125) | def getAvailableTaxi(time): function assignTaxi (line 138) | def assignTaxi(taxiId, time, address): FILE: models/openai_model.py class OpenAIModel (line 12) | class OpenAIModel(): method __init__ (line 13) | def __init__(self, api_key, model="gpt-3.5-turbo"): method chat (line 17) | def chat(self, messages): FILE: orchestrator.py function create_id_to_url_mappings (line 22) | def create_id_to_url_mappings(config): function launch_instance (line 52) | def launch_instance(tmux_server, instance_type, model_type, agent_id, ba... function run_query (line 67) | def run_query(query_id, user_id, user_url, target, task, data): function process_task (line 82) | def process_task(worker_id, task): function worker (line 86) | def worker(worker_id, task_queue, result_list): function fifo_task_processor (line 96) | def fifo_task_processor(task_list, num_workers): function run_asynchronous (line 115) | def run_asynchronous(actions): function main (line 118) | def main(): FILE: specialized_toolformers/negotiator.py function chat (line 46) | def chat(message, conversation_id, target_node): function negotiate_protocol_for_task (line 61) | def negotiate_protocol_for_task(task_schema, target_node): function create_negotiation_conversation (line 110) | def create_negotiation_conversation(tools, additional_info): function handle_negotiation_for_tools (line 129) | def handle_negotiation_for_tools(message, conversation_id, tools, additi... FILE: specialized_toolformers/programmer.py function write_routine_for_task (line 65) | def write_routine_for_task(task_schema, protocol_document): function write_routine_for_tools (line 90) | def write_routine_for_tools(tools, protocol_document, additional_info): FILE: specialized_toolformers/protocol_checker.py function check_protocol_for_task (line 19) | def check_protocol_for_task(protocol_document, task_schema): function filter_protocols_for_task (line 34) | def filter_protocols_for_task(protocol_metadatas, task_schema): function check_protocol_for_tools (line 96) | def check_protocol_for_tools(protocol_document, tools): FILE: specialized_toolformers/querier.py function construct_query_description (line 24) | def construct_query_description(protocol_document, task_schema, task_data): function parse_and_handle_query (line 48) | def parse_and_handle_query(query, target_node, protocol_id, source): function get_output_parameters (line 58) | def get_output_parameters(task_schema): function handle_conversation (line 70) | def handle_conversation(prompt, message, target_node, protocol_id, sourc... function send_query_with_protocol (line 146) | def send_query_with_protocol(task_schema, task_data, target_node, protoc... function send_query_without_protocol (line 154) | def send_query_without_protocol(task_schema, task_data, target_node): FILE: specialized_toolformers/responder.py function reply_with_protocol_document (line 26) | def reply_with_protocol_document(query, protocol_document, tools, additi... function reply_to_nl_query (line 53) | def reply_to_nl_query(query, tools, additional_info): function reply_to_query (line 74) | def reply_to_query(query, protocol_id, tools, additional_info): FILE: toolformers/base.py class Parameter (line 12) | class Parameter: method __init__ (line 13) | def __init__(self, name, description, required): method as_openai_info (line 18) | def as_openai_info(self): method as_standard_api (line 21) | def as_standard_api(self): class StringParameter (line 24) | class StringParameter(Parameter): method __init__ (line 25) | def __init__(self, name, description, required): method as_openai_info (line 28) | def as_openai_info(self): method as_standard_api (line 35) | def as_standard_api(self): method as_natural_language (line 43) | def as_natural_language(self): method as_documented_python (line 46) | def as_documented_python(self): method as_gemini_tool (line 49) | def as_gemini_tool(self): method from_standard_api (line 56) | def from_standard_api(api_info): class EnumParameter (line 59) | class EnumParameter(Parameter): method __init__ (line 60) | def __init__(self, name, description, values, required): method as_openai_info (line 64) | def as_openai_info(self): method as_standard_api (line 71) | def as_standard_api(self): method as_natural_language (line 80) | def as_natural_language(self): method as_documented_python (line 83) | def as_documented_python(self): method as_gemini_tool (line 86) | def as_gemini_tool(self): method from_standard_api (line 94) | def from_standard_api(api_info): class NumberParameter (line 97) | class NumberParameter(Parameter): method __init__ (line 98) | def __init__(self, name, description, required): method as_openai_info (line 101) | def as_openai_info(self): method as_standard_api (line 107) | def as_standard_api(self): method as_natural_language (line 115) | def as_natural_language(self): method as_documented_python (line 118) | def as_documented_python(self): method as_gemini_tool (line 121) | def as_gemini_tool(self): class ArrayParameter (line 127) | class ArrayParameter(Parameter): method __init__ (line 128) | def __init__(self, name, description, required, item_schema): method as_openai_info (line 132) | def as_openai_info(self): method as_standard_api (line 139) | def as_standard_api(self): method as_natural_language (line 148) | def as_natural_language(self): method as_documented_python (line 151) | def as_documented_python(self): method as_gemini_tool (line 154) | def as_gemini_tool(self): function parameter_from_openai_api (line 161) | def parameter_from_openai_api(parameter_name, schema, required): class Tool (line 173) | class Tool: method __init__ (line 174) | def __init__(self, name, description, parameters, function, output_sch... method call_tool_for_toolformer (line 181) | def call_tool_for_toolformer(self, *args, **kwargs): method as_openai_info (line 192) | def as_openai_info(self): method as_gemini_tool (line 206) | def as_gemini_tool(self) -> CallableFunctionDeclaration: method as_llama_schema (line 222) | def as_llama_schema(self): method as_natural_language (line 235) | def as_natural_language(self): method as_standard_api (line 251) | def as_standard_api(self): method as_documented_python (line 258) | def as_documented_python(self): method as_executable_function (line 272) | def as_executable_function(self): method from_standard_api (line 283) | def from_standard_api(api_info): # TODO: Drop? function send_usage_to_db (line 295) | def send_usage_to_db(usage, time_start, time_end, agent, category, model): class Conversation (line 312) | class Conversation(ABC): method chat (line 314) | def chat(self, message, role='user', print_output=True): class Toolformer (line 317) | class Toolformer(ABC): method new_conversation (line 319) | def new_conversation(self, category=None) -> Conversation: FILE: toolformers/camel.py class CamelConversation (line 15) | class CamelConversation(Conversation): method __init__ (line 16) | def __init__(self, toolformer, agent, category=None): method chat (line 21) | def chat(self, message, role='user', print_output=True): class CamelToolformer (line 48) | class CamelToolformer(Toolformer): method __init__ (line 49) | def __init__(self, model_platform, model_type, model_config_dict, syst... method name (line 58) | def name(self): method new_conversation (line 64) | def new_conversation(self, category=None) -> Conversation: function make_openai_toolformer (line 79) | def make_openai_toolformer(model_type_internal, system_prompt, tools : L... FILE: toolformers/gemini.py class GeminiConversation (line 15) | class GeminiConversation(Conversation): method __init__ (line 16) | def __init__(self, model_name, chat_agent : ChatSession, category=None): method chat (line 21) | def chat(self, message, role='user', print_output=True): class GeminiToolformer (line 79) | class GeminiToolformer(Toolformer): method __init__ (line 80) | def __init__(self, model_name, system_prompt, tools): method new_conversation (line 85) | def new_conversation(self, category=None) -> Conversation: function make_gemini_toolformer (line 98) | def make_gemini_toolformer(model_name, system_prompt, tools : List[Tool]): FILE: toolformers/llama/api_gateway.py class APIGateway (line 31) | class APIGateway: method load_llm (line 33) | def load_llm( FILE: toolformers/llama/function_calling.py class FunctionCallingLlm (line 56) | class FunctionCallingLlm: method __init__ (line 61) | def __init__( method execute (line 119) | def execute(self, invoked_tools: List[dict]) -> tuple[bool, List[str]]: method json_finder (line 154) | def json_finder(self, input_string: str) -> Optional[str]: method msgs_to_llama3_str (line 203) | def msgs_to_llama3_str(self, msgs: list) -> str: method msgs_to_sncloud (line 230) | def msgs_to_sncloud(self, msgs: list) -> list: method function_call_llm (line 251) | def function_call_llm(self, query: str, max_it: int = 5, debug: bool =... FILE: toolformers/llama/llama.py class LlamaConversation (line 8) | class LlamaConversation(Conversation): method __init__ (line 9) | def __init__(self, model_name, function_calling_llm : FunctionCallingL... method chat (line 14) | def chat(self, message, role='user', print_output=True): class LlamaToolformer (line 34) | class LlamaToolformer(Toolformer): method __init__ (line 35) | def __init__(self, model_name: str, system_prompt: str, tools: List[To... method new_conversation (line 39) | def new_conversation(self, category=None) -> LlamaConversation: function make_llama_toolformer (line 42) | def make_llama_toolformer(model_name, system_prompt: str, tools: List[To... FILE: toolformers/llama/sambanova_langchain.py class SSEndpointHandler (line 19) | class SSEndpointHandler: method __init__ (line 26) | def __init__(self, host_url: str, api_base_uri: str): method _process_response (line 37) | def _process_response(self, response: requests.Response) -> Dict: method _process_streaming_response (line 63) | def _process_streaming_response( method _get_full_url (line 100) | def _get_full_url(self, path: str) -> str: method nlp_predict (line 110) | def nlp_predict( method nlp_predict_stream (line 157) | def nlp_predict_stream( class SambaStudio (line 211) | class SambaStudio(LLM): class Config (line 271) | class Config: method is_lc_serializable (line 277) | def is_lc_serializable(cls) -> bool: method _identifying_params (line 281) | def _identifying_params(self) -> Dict[str, Any]: method _llm_type (line 286) | def _llm_type(self) -> str: method validate_environment (line 291) | def validate_environment(cls, values: Dict) -> Dict: method _get_tuning_params (line 309) | def _get_tuning_params(self, stop: Optional[List[str]]) -> str: method _handle_nlp_predict (line 335) | def _handle_nlp_predict(self, sdk: SSEndpointHandler, prompt: Union[Li... method _handle_completion_requests (line 378) | def _handle_completion_requests(self, prompt: Union[List[str], str], s... method _handle_nlp_predict_stream (line 396) | def _handle_nlp_predict_stream( method _stream (line 448) | def _stream( method _handle_stream_request (line 478) | def _handle_stream_request( method _call (line 504) | def _call( class SambaNovaCloud (line 531) | class SambaNovaCloud(LLM): class Config (line 583) | class Config: method is_lc_serializable (line 589) | def is_lc_serializable(cls) -> bool: method _identifying_params (line 593) | def _identifying_params(self) -> Dict[str, Any]: method invoke (line 604) | def invoke( method _llm_type (line 644) | def _llm_type(self) -> str: method validate_environment (line 649) | def validate_environment(cls, values: Dict) -> Dict: method _handle_nlp_predict_stream (line 657) | def _handle_nlp_predict_stream( method _stream (line 753) | def _stream( method _handle_stream_request (line 778) | def _handle_stream_request( method _call (line 804) | def _call( FILE: toolformers/llama/utils.py function usage_tracker (line 6) | def usage_tracker(): function get_total_usage (line 15) | def get_total_usage(): function append_to_usage_tracker (line 30) | def append_to_usage_tracker(usage): FILE: toolformers/unified.py function make_toolformer (line 8) | def make_toolformer(model_type_internal, system_prompt, tools): function make_default_toolformer (line 18) | def make_default_toolformer(system_prompt, tools): FILE: utils.py function compute_hash (line 13) | def compute_hash(s): function save_protocol_document (line 23) | def save_protocol_document(base_folder, protocol_id, protocol_document): function load_protocol_document (line 35) | def load_protocol_document(base_folder, protocol_id): function execute_routine (line 46) | def execute_routine(base_folder, protocol_id, task_data, tools): function save_routine (line 67) | def save_routine(base_folder, protocol_id, routine): function extract (line 80) | def extract(text, start_tag, end_tag): function download_and_verify_protocol (line 89) | def download_and_verify_protocol(protocol_hash, protocol_source): function send_raw_query (line 115) | def send_raw_query(text, protocol_id, target_node, source): function use_query_id (line 127) | def use_query_id(query_id): function get_query_id (line 138) | def get_query_id(): function shared_config (line 143) | def shared_config(key, fallback='no_fallback'): function serialize_gemini_data (line 155) | def serialize_gemini_data(output):