You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the Router cannot determine an appropriate route for the given context, it will route to the **error path** instead of arbitrarily selecting a route. This happens when:
107
+
108
+
- The context doesn't clearly match any of the defined route descriptions
109
+
- The AI determines that none of the available routes are appropriate
110
+
105
111
## Best Practices
106
112
107
113
-**Write clear route descriptions**: Each route description should clearly explain when that route should be selected. Be specific about the criteria.
108
114
-**Make routes mutually exclusive**: When possible, ensure route descriptions don't overlap to prevent ambiguous routing decisions.
109
-
-**Include an error/fallback route**: Add a catch-all route for unexpected inputs that don't match other routes.
115
+
-**Connect an error path**: Handle cases where no route matches by connecting an error handler for graceful fallback behavior.
110
116
-**Use descriptive route titles**: Route titles appear in the workflow canvas, so make them meaningful for readability.
111
117
-**Test with diverse inputs**: Ensure the Router handles various input types, edge cases, and unexpected content.
112
118
-**Monitor routing performance**: Review routing decisions regularly and refine route descriptions based on actual usage patterns.
0 commit comments