Spaces:
Runtime error
Runtime error
Upload tool_definitions.py
Browse files- tool_definitions.py +25 -0
tool_definitions.py
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#tools/tool_definitions.py
|
| 2 |
+
|
| 3 |
+
TOOL_TIPS = {
|
| 4 |
+
"WebSearchTool": "π Search the web using DuckDuckGo, Brave, or SerpAPI.",
|
| 5 |
+
"VisitWebpageTool": "π Fetch and convert a webpage into readable markdown.",
|
| 6 |
+
"PythonTool": "π Execute Python code securely in a sandboxed environment.",
|
| 7 |
+
"PythonInterpreterTool": "π§ͺ A stateful Python interpreter with retained execution context.",
|
| 8 |
+
"TerminalTool": "π» Run shell commands. Use with caution.",
|
| 9 |
+
"FileTool": "ποΈ Read, write, and manipulate local files for your agent.",
|
| 10 |
+
"ImageTool": "πΌοΈ Handle image input/output β caption, generate, or analyze.",
|
| 11 |
+
"FinalAnswerTool": "β
Marks the final agent response to stop processing.",
|
| 12 |
+
"UserInputTool": "π€ Allows dynamic user prompts mid-task.",
|
| 13 |
+
"LangChainTool": "π Wrap LangChain tools like SerpAPI, SQL Toolkit, Wolfram Alpha.",
|
| 14 |
+
"HFModelDownloadsTool": "π Fetch most downloaded HF models for a given task.",
|
| 15 |
+
"ApiWebSearchTool": "π°οΈ Search APIs like Bing or Google for fresh results.",
|
| 16 |
+
"Tool.from_hub()": "π¦ Load external tools from Hugging Face Hub repos.",
|
| 17 |
+
"Tool.from_space()": "π§ͺ Import Gradio Spaces as tools.",
|
| 18 |
+
"Tool.from_mcp()": "π§ Load tools dynamically from registered MCP servers.",
|
| 19 |
+
"Tool.from_langchain()": "𧬠Convert LangChain tool definitions into SmolAgent-compatible formats.",
|
| 20 |
+
"Tool.from_gradio()": "ποΈ Wrap Gradio interfaces as callable tools.",
|
| 21 |
+
"ToolCollection.from_mcp()": "π Fetch and register toolsets from Glama, Smithery, and other MCP providers."
|
| 22 |
+
}
|
| 23 |
+
|
| 24 |
+
|
| 25 |
+
β
This file gives you tooltip metadata for dynamic dropdowns, tool help panels, and config-driven rendering. You can link this file to model_config.json, or expand to include categories, icons, or flags like streaming=True.
|