AI Agent Frameworks / Quiz
CrewAI Tools and Testing Them Cold
A crew is only as reliable as its tools. Learn the @tool decorator, BaseTool, and how to test tool code without paying for a single LLM call.
- Difficulty
- Medium
- Format
- Quiz
- Points
- 150
- Estimate
- 9 min
// MISSION BRIEF
Your Mission
CrewAI agents act through tools: a @tool-decorated function or a BaseTool subclass. Tool bugs masquerade as agent stupidity, so a tester's first move is to peel the tool away from the LLM and test it cold.
Scoring: equal weight per question.
// FIRST CONTACT
Battle teaser
With the decorator form (@tool("Search KB") from crewai.tools), what does the LLM actually see when deciding whether to call it?
- AThe git blame of the file
- BThe function's full source code
- CThe tool name and the function's docstring as its description, so a lazy docstring directly degrades tool selection
- DNothing, tools are invisible to the model
Answers, scoring, hints, and the full battle stay sealed.
// SKILL TAGS
crewaitoolsmockingunit-testingai-agents