Перейти к содержимому

Skip Pattern

Это содержимое пока не доступно на вашем языке.

Allow users or agents to skip optional workflow steps when not needed. Useful for optional analysis, reviews, or configuration steps.

[optional-step] → [check-skip] → skip=true → [next-step]
→ skip=false → [process-result]
{
"type": "agent-directive",
"id": "optional-analysis",
"directive": "Perform optional deep analysis. User can skip if not needed by providing skip='yes'.",
"inputSchema": {
"type": "object",
"properties": {
"analysis_result": { "type": "string" },
"skip": { "type": "string", "enum": ["yes"] }
}
},
"connections": { "success": "check-skip" }
}
{
"type": "condition",
"id": "check-skip",
"condition": {
"operator": "eq",
"left": { "contextPath": "skip" },
"right": "yes"
},
"connections": {
"true": "next-step",
"false": "process-analysis"
}
}

For simpler cases:

{
"inputSchema": {
"properties": {
"result": { "type": "string" },
"skipped": { "type": "boolean" }
},
"required": ["skipped"]
}
}

Skip decisions can be made upfront:

{
"id": "collect-preferences",
"directive": "Ask user: do you want detailed analysis?",
"inputSchema": {
"properties": {
"want_detailed_analysis": { "type": "boolean" }
},
"required": ["want_detailed_analysis"]
}
}

Then use condition:

{
"condition": {
"operator": "eq",
"left": { "contextPath": "want_detailed_analysis" },
"right": false
},
"connections": {
"true": "skip-to-summary",
"false": "detailed-analysis"
}
}

From workflow-management-flow.json:

{
"id": "review-existing-workflow",
"directive": "If editing, review the existing workflow structure.\nIf creating new workflow, skip this step.",
"inputSchema": {
"properties": {
"workflow_reviewed": { "type": "string" },
"skip": { "type": "string", "enum": ["yes"] }
}
}
}