Skip to main content
This guide outlines recommended practices for creating effective and maintainable workflow agents.

Task Design

Naming Conventions

Do:
Don’t:

Task Organization

  1. Logical Grouping
  2. Clear Dependencies
    • Keep dependencies minimal
    • Avoid complex chains
    • Document connection purposes

Input/Output Configuration

Input Parameters

  1. Clear Naming
  2. Type Selection
    • Use simplest type possible
    • Consider data flow requirements
    • Document format requirements
  3. Validation Rules

Output Parameters

  1. Structured Output
  2. Error Handling
    • Include error information
    • Provide status indicators
    • Add validation messages

Task-Specific Best Practices

AI Tasks

  1. Clear Instructions
  2. Output Structure
    • Define clear categories
    • Include confidence scores
    • Structure for easy processing

Human Tasks

  1. Clear Decision Points
  2. Assignment Rules

App Tasks

  1. Tool Configuration
  2. Error Handling

Coder Tasks

  1. Code Artifact Management

Error Handling

Global Error Policies

Task-Level Error Handling

Performance Optimization

1. Task Efficiency

  • Minimize dependencies
  • Optimize data transfer
  • Use appropriate task types

2. Resource Management

  • Configure timeouts
  • Set memory limits
  • Monitor execution time

Security Best Practices

1. Data Handling

  • Minimize sensitive data
  • Use secure parameters
  • Implement data masking

2. Access Control

  • Proper assignment rules
  • Role-based access
  • Audit logging

Testing Guidelines

1. Task Testing

2. Workflow Testing

  • Test complete flows
  • Validate error handling
  • Check performance

Maintenance

1. Documentation

  • Clear descriptions
  • Updated configurations
  • Change history
  • Usage examples

2. Monitoring

  • Track execution time
  • Monitor error rates
  • Review usage patterns

Common Pitfalls to Avoid

  1. Over-complexity
    • Too many dependencies
    • Unnecessary tasks
    • Complex logic
  2. Poor Error Handling
    • Missing error cases
    • Unclear error messages
    • No recovery path
  3. Insufficient Validation
    • Missing input validation
    • Weak type checking
    • Incomplete error checks