TOOL_XML_EXAMPLES = { "computer_use_tool": '\n \n 100\n 200\n \n \n\n\n \n 100\n 200\n left\n 1\n \n \n\n\n \n -3\n \n \n\n\n \n Hello World!\n \n \n\n\n \n enter\n \n \n\n\n \n 1.5\n \n \n\n\n \n left\n \n \n\n\n \n left\n \n \n\n\n \n 500\n 50\n \n \n\n\n \n ctrl+a\n \n ', "data_providers_tool": '\n\n\n\n\nlinkedin\n\n\n\n\n \n \n \n \n linkedin\n person\n {"link": "https://www.linkedin.com/in/johndoe/"}\n \n ', "expand_msg_tool": '\n \n \n ecde3a4c-c7dc-4776-ae5c-8209517c5576\n \n \n\n \n \n \n f47ac10b-58cc-4372-a567-0e02b2c3d479\n \n \n\n \n \n \n 550e8400-e29b-41d4-a716-446655440000\n \n ', "mcp_tool_wrapper": '\n \n mcp_exa_web_search_exa\n {"query": "latest developments in AI", "num_results": 10}\n \n ', "message_tool": '\n \n I\'m planning to bake the chocolate cake for your birthday party. The recipe mentions "rich frosting" but doesn\'t specify what type. Could you clarify your preferences? For example:\n1. Would you prefer buttercream or cream cheese frosting?\n2. Do you want any specific flavor added to the frosting (vanilla, coffee, etc.)?\n3. Should I add any decorative toppings like sprinkles or fruit?\n4. Do you have any dietary restrictions I should be aware of?\n\nThis information will help me make sure the cake meets your expectations for the celebration.\n recipes/chocolate_cake.txt,photos/cake_examples.jpg\n \n \n\n\n \n I\'ve encountered a CAPTCHA verification on the page. Please:\n1. Solve the CAPTCHA puzzle\n2. Let me know once you\'ve completed it\n3. I\'ll then continue with the automated process\n\nIf you encounter any issues or need to take additional steps, please let me know.\n \n \n\n\n \n \n ', "sb_browser_tool": '\n \n https://example.com\n \n \n\n\n \n \n \n\n\n \n 5\n \n \n\n\n \n 2\n \n \n\n\n \n 2\n Hello, world!\n \n \n\n\n \n Enter\n \n \n\n\n \n 1\n \n \n\n\n \n 1\n \n \n\n\n \n 500\n \n \n\n\n \n 500\n \n \n\n\n \n Contact Us\n \n \n\n\n \n 2\n \n \n\n\n \n 2\n Option 1\n \n \n\n\n \n #draggable\n #droppable\n \n \n\n\n \n 100\n 200\n \n ', "sb_deploy_tool": '\n\n \n \n my-site\n website\n \n ', "sb_expose_tool": '\n \n \n 8000\n \n \n\n \n \n \n 3000\n \n \n\n \n \n \n 5173\n \n ', "sb_files_tool": '\n \n src/main.py\n \n # This is the file content\n def main():\n print("Hello, World!")\n \n if __name__ == "__main__":\n main()\n \n \n \n\n\n \n src/main.py\n text to replace (must appear exactly once in the file)\n replacement text that will be inserted instead\n \n \n\n\n \n src/main.py\n \n This completely replaces the entire file content.\n Use when making major changes to a file or when the changes\n are too extensive for str-replace.\n All previous content will be lost and replaced with this text.\n \n \n \n\n\n \n src/main.py\n \n ', "sb_shell_tool": '\n \n npm run dev\n dev_server\n \n \n\n \n \n \n npm run build\n frontend\n build_process\n \n \n\n \n \n \n npm install\n true\n 300\n \n \n\n\n \n dev_server\n \n \n \n \n \n \n build_process\n true\n \n \n\n\n \n dev_server\n \n \n\n\n \n \n ', "sb_vision_tool": '\n \n \n docs/diagram.png\n \n ', "update_agent_tool": '\n \n Research Assistant\n An AI assistant specialized in conducting research and providing comprehensive analysis\n You are a research assistant with expertise in gathering, analyzing, and synthesizing information. Your approach is thorough and methodical...\n {"web_search": {"enabled": true, "description": "Search the web for information"}, "sb_files": {"enabled": true, "description": "Read and write files"}}\n 🔬\n #4F46E5\n \n \n\n\n \n \n \n\n\n \n linear\n 5\n \n \n\n\n \n exa\n \n \n\n\n \n exa\n Exa Search\n ["search", "find_similar"]\n {"exaApiKey": "user-api-key"}\n \n \n\n\n \n AI & Search\n \n \n\n\n \n exa\n {"exaApiKey": "user-api-key"}\n \n ', "web_search_tool": '\n \n what is Kortix AI and what are they building?\n 20\n \n \n \n \n \n \n latest AI research on transformer models\n 20\n \n \n\n\n \n https://www.kortix.ai/,https://github.com/kortix-ai/suna\n \n ', } def get_tool_xml_example(tool_id: str) -> str: if tool_id in TOOL_XML_EXAMPLES: return TOOL_XML_EXAMPLES[tool_id] if tool_id not in TOOL_XML_EXAMPLES and '_' in tool_id: return f'\n \n value1\n value2\n \n ' return "" def get_tools_xml_examples(tool_ids: list) -> str: examples = [] for tool_id in tool_ids: example = get_tool_xml_example(tool_id) if example: examples.append(f"## {tool_id.replace('_', ' ').title()}") examples.append(example) examples.append("") return "\n".join(examples) def get_all_available_tools() -> list: return list(TOOL_XML_EXAMPLES.keys())