Task
class constructor. Each task can be customized with specific tools, response formats, caching options, and validation rules to meet your exact requirements.
Basic Task Creation
Task with Tools
Task with Response Format
Task with Advanced Configuration
Best Practices
- Start Simple: Begin with basic tasks and gradually add complexity
- Clear Descriptions: Write descriptive task descriptions that clearly state the objective
- Tool Selection: Choose appropriate tools for the task requirements
- Error Handling: Use guardrails for tasks that require specific output validation
- Caching Strategy: Enable caching for tasks that might be repeated with similar inputs