diff --git a/src/modules/autominator/workflows/create-workflow/instructions.md b/src/modules/autominator/workflows/create-workflow/instructions.md
index 3284a80d..3e648889 100644
--- a/src/modules/autominator/workflows/create-workflow/instructions.md
+++ b/src/modules/autominator/workflows/create-workflow/instructions.md
@@ -29,92 +29,107 @@
- Ask Question 1: "What type of automation workflow do you need?"
+ Start by understanding the ACTUAL PROBLEM the user wants to solve, not just technical requirements
+
+ Ask Question 1: "What problem are you trying to solve with this automation?"
+ Encourage detailed explanation: "Describe the current manual process, pain points, and desired outcome."
+ WAIT for user input
+ Store in {{problem_description}}
+
+ Ask Question 2: "What triggers this process? When should the automation run?"
Present numbered options:
- 1. Webhook-based - Receive HTTP requests and process data
- 2. Scheduled - Run on a schedule (cron/interval)
- 3. Event-driven - Trigger from external service events
- 4. Manual - Execute on demand
- 5. Database-driven - Trigger from database changes
- 6. Other - Describe your specific trigger needs
+ 1. When data arrives - Webhook, form submission, API call
+ 2. On a schedule - Every hour, daily, weekly, custom cron
+ 3. When something changes - Database update, file change, service event
+ 4. Manually - On-demand execution
+ 5. Multiple triggers - Combination of above
+ 6. Not sure - Help me decide based on my problem
WAIT for user selection (1-6)
- Store selection in {{workflow_type}}
+ Store selection in {{trigger_type}}
-
- Ask: "Please describe your trigger requirements"
- WAIT for user input
- Store in {{workflow_type}}
+
+ Analyze {{problem_description}} and suggest appropriate trigger
+ Ask: "Based on your problem, I recommend [trigger type]. Does this make sense?"
+ WAIT for confirmation or adjustment
+ Store final trigger in {{trigger_type}}
- Ask Question 2: "What integrations or services will this workflow use?"
- Present numbered options:
- 1. HTTP/REST APIs - Generic API calls
- 2. Databases - PostgreSQL, MySQL, MongoDB, etc.
- 3. Cloud Services - Google Sheets, Slack, Notion, Airtable
- 4. Email - Send/receive emails
- 5. CRM - HubSpot, Salesforce, etc.
- 6. Custom Code - JavaScript/Python logic
- 7. Multiple - Combination of above
- 8. Other - Specify integrations
-
- WAIT for user selection (1-8)
- Store selection in {{integrations}}
+ Ask Question 3: "What data or information does this workflow need to work with?"
+ Examples: "Customer data, order details, form responses, API data, etc."
+ WAIT for user input
+ Store in {{data_requirements}}
-
- Ask: "Please list all integrations needed (comma-separated)"
+ Ask Question 4: "What should happen with this data? What's the desired outcome?"
+ Examples: "Send to Slack, update database, create invoice, notify team, etc."
+ WAIT for user input
+ Store in {{desired_outcome}}
+
+ Ask Question 5: "What services or systems are involved?"
+ Examples: "Slack, Google Sheets, PostgreSQL, HubSpot, custom API, etc."
+ WAIT for user input
+ Store in {{integrations}}
+
+ Ask Question 6: "Are there any conditions or decision points in this process?"
+ Examples: "If amount > $1000, notify manager; If status = 'urgent', send immediately"
+ Present numbered options:
+ 1. No - Straight-through processing
+ 2. Yes - Describe the conditions
+
+ WAIT for user selection (1-2)
+
+ Ask: "Describe the conditions and what should happen in each case"
WAIT for user input
- Store in {{integrations}}
+ Store in {{conditional_logic}}
- Ask Question 3: "How complex is your workflow logic?"
+ Ask Question 7: "How critical is this workflow? What happens if it fails?"
Present numbered options:
- 1. Simple (3-5 nodes) - Linear flow with minimal logic
- 2. Medium (6-10 nodes) - Some conditional logic or branching
- 3. Complex (11-20 nodes) - Multiple branches, loops, or error handling
- 4. Very Complex (20+ nodes) - Advanced logic with parallel processing
+ 1. Low - Can retry manually if needed
+ 2. Medium - Should retry automatically, notify on failure
+ 3. High - Must succeed, need alerts and logging
+ 4. Critical - Business-critical, need comprehensive error handling
WAIT for user selection (1-4)
- Store selection in {{complexity}}
+ Store selection in {{criticality}}
- Ask Question 4: "Do you need error handling and retry logic?"
- Present numbered options:
- 1. No - Simple workflow without error handling
- 2. Basic - Retry failed operations automatically
- 3. Advanced - Custom error handling with notifications
- 4. Comprehensive - Full error workflow with logging and alerts
-
- WAIT for user selection (1-4)
- Store selection in {{error_handling}}
-
- Ask Question 5: "What should the workflow be named?"
+ Ask Question 8: "What should the workflow be named?"
+ Suggest name based on {{problem_description}}
WAIT for user input
Store in {{workflow_name}}
- Ask Question 6: "Where should the workflow file be saved?"
+ Ask Question 9: "Where should the workflow file be saved?"
Present numbered options:
1. Default location - workflows/[workflow-name].json
2. Custom path - Specify your own file path
- 3. Project root - Save in main project directory
- 4. Specific folder - Choose from existing folders
- WAIT for user selection (1-4)
-
+ WAIT for user selection (1-2)
+
Ask for specific path
WAIT for user input
Store final path in {{save_location}}
- Ask Question 7: "Any additional requirements or specific logic needed?"
+ Summarize understanding:
+ - Problem: {{problem_description}}
+ - Trigger: {{trigger_type}}
+ - Data: {{data_requirements}}
+ - Outcome: {{desired_outcome}}
+ - Services: {{integrations}}
+ - Conditions: {{conditional_logic}}
+ - Criticality: {{criticality}}
+
+ Ask: "Does this capture your requirements correctly?"
Present numbered options:
- 1. No - Proceed with current requirements
- 2. Yes - Describe additional requirements
+ 1. Yes - Proceed with workflow creation
+ 2. No - Let me clarify or add details
WAIT for user selection (1-2)
- Ask: "Please describe additional requirements"
+ Ask: "What needs to be clarified or added?"
WAIT for user input
- Store in {{additional_requirements}}
+ Update relevant variables
+ Repeat summary and confirmation
@@ -153,32 +168,70 @@
- Based on gathered requirements, plan the workflow structure:
- 1. Identify trigger node type
- 2. List all action nodes needed
- 3. Identify conditional logic (IF nodes)
- 4. Plan data transformations (Set/Code nodes)
- 5. Design error handling strategy
- 6. Map node connections
+ Design workflow based on the ACTUAL PROBLEM, not just technical specs
- Present the planned structure to user in clear format:
- - Trigger: [trigger type]
- - Nodes: [list of nodes with descriptions]
- - Logic: [conditional branches, loops]
- - Error Handling: [strategy]
+ Analyze the problem and requirements:
+ - Problem to solve: {{problem_description}}
+ - Trigger: {{trigger_type}}
+ - Data needed: {{data_requirements}}
+ - Desired outcome: {{desired_outcome}}
+ - Services: {{integrations}}
+ - Conditions: {{conditional_logic}}
+ - Criticality: {{criticality}}
- Ask: "Does this structure meet your needs?"
+ Design workflow structure that solves the problem:
+ 1. Map trigger to appropriate n8n trigger node
+ 2. Design data acquisition steps (API calls, database queries)
+ 3. Plan data transformations needed for the outcome
+ 4. Implement conditional logic from {{conditional_logic}}
+ 5. Design actions to achieve {{desired_outcome}}
+ 6. Add error handling based on {{criticality}}
+ 7. Plan node connections and data flow
+
+ Present the solution-focused workflow plan:
+ ## Workflow Solution for: {{problem_description}}
+
+ **How it works:**
+ [Explain in plain language how the workflow solves the problem]
+
+ **Workflow Steps:**
+ 1. Trigger: [When/how it starts] - [n8n node type]
+ 2. Get Data: [What data is retrieved] - [n8n nodes]
+ 3. Process: [How data is transformed] - [n8n nodes]
+ 4. Decide: [Conditional logic if any] - [IF/Switch nodes]
+ 5. Act: [Final actions to achieve outcome] - [n8n nodes]
+ 6. Handle Errors: [Error strategy] - [Error handling config]
+
+ **Expected Result:**
+ [Describe what happens when workflow runs successfully]
+
+ Ask: "Does this workflow solve your problem?"
Present numbered options:
- 1. Yes - Proceed with this structure
- 2. No - Adjust the structure
- 3. Add more details - Provide additional requirements
+ 1. Yes - This solves my problem, proceed
+ 2. No - Missing something important
+ 3. Partially - Needs adjustments
+ 4. Explain more - I need clarification
- WAIT for user selection (1-3)
+ WAIT for user selection (1-4)
-
- Ask: "What changes or additions are needed?"
+
+ Ask: "What's missing? What else needs to happen?"
WAIT for user input
- Adjust structure based on feedback
+ Adjust workflow design to include missing elements
+ Repeat this step
+
+
+
+ Ask: "What needs to be adjusted?"
+ WAIT for user input
+ Modify workflow design based on feedback
+ Repeat this step
+
+
+
+ Ask: "Which part needs clarification?"
+ WAIT for user input
+ Provide detailed explanation of that part
Repeat this step
diff --git a/src/modules/autominator/workflows/migrate-workflow/instructions.md b/src/modules/autominator/workflows/migrate-workflow/instructions.md
index 17ffd53d..b427c510 100644
--- a/src/modules/autominator/workflows/migrate-workflow/instructions.md
+++ b/src/modules/autominator/workflows/migrate-workflow/instructions.md
@@ -29,7 +29,14 @@
- Ask Question 1: "Which platform are you migrating from?"
+ Understand the BUSINESS PURPOSE of the workflow being migrated, not just technical details
+
+ Ask Question 1: "What does this workflow do? What problem does it solve?"
+ Encourage business context: "Describe the business process, not just the technical steps"
+ WAIT for user input
+ Store in {{business_purpose}}
+
+ Ask Question 2: "Which platform are you migrating from?"
Present numbered options:
1. Zapier - Migrate Zapier Zaps to n8n
2. Make (Integromat) - Migrate Make scenarios to n8n
@@ -47,66 +54,59 @@
Store in {{source_platform}}
- Ask Question 2: "How will you provide the workflow to migrate?"
+ Ask Question 3: "Why are you migrating to n8n?"
+ Examples: "Cost savings", "More flexibility", "Self-hosting", "Better integrations"
+ WAIT for user input
+ Store in {{migration_reason}}
+
+ Ask Question 4: "How will you provide the workflow details?"
Present numbered options:
- 1. Describe it - Explain what the workflow does
+ 1. Describe the process - Explain what happens step by step
2. Provide export file - Upload/paste workflow export file
3. Provide screenshots - Share workflow screenshots
- 4. Provide documentation - Share workflow documentation
+ 4. Combination - Multiple sources
WAIT for user selection (1-4)
-
- Ask: "Please describe what the workflow does (trigger, actions, logic)"
+
+ Ask: "Describe the workflow step by step:"
+ - What triggers it?
+ - What data does it process?
+ - What actions does it take?
+ - What's the final outcome?
WAIT for user input
Store in {{workflow_description}}
-
+
Ask: "Please provide the workflow export file path or paste the content"
WAIT for user input
Store in {{workflow_file}} or {{workflow_content}}
-
- Ask: "Please share the workflow screenshots and describe the flow"
+
+ Ask: "Please share the workflow screenshots and describe what each part does"
WAIT for user input
- Store in {{workflow_description}}
+ Store in {{workflow_screenshots}}
-
- Ask: "Please provide the workflow documentation"
- WAIT for user input
- Store in {{workflow_description}}
-
-
- Ask Question 3: "What is the trigger for this workflow?"
- Present numbered options:
- 1. Webhook/HTTP Request - Triggered by incoming HTTP requests
- 2. Schedule/Cron - Runs on a schedule
- 3. Form Submission - Triggered by form submissions
- 4. Database Change - Triggered by database events
- 5. Email - Triggered by incoming emails
- 6. Service Event - Triggered by external service (Slack, Google Sheets, etc.)
- 7. Not sure - Will determine from workflow details
-
- WAIT for user selection (1-7)
- Store selection in {{trigger_type}}
-
- Ask Question 4: "What integrations/services does this workflow use?"
- Ask: "Please list all services (e.g., Slack, Google Sheets, HubSpot, etc.)"
+ Ask Question 5: "What services/integrations does this workflow connect to?"
+ Ask: "List all services (e.g., Slack, Google Sheets, HubSpot, custom APIs, etc.)"
WAIT for user input
Store in {{integrations_used}}
- Ask Question 5: "How complex is the workflow?"
+ Ask Question 6: "Are there any pain points or issues with the current workflow?"
+ Examples: "Slow execution", "Unreliable", "Missing features", "Hard to maintain"
Present numbered options:
- 1. Simple - Linear flow with 3-5 steps
- 2. Medium - Some conditional logic, 6-10 steps
- 3. Complex - Multiple branches, loops, 11-20 steps
- 4. Very Complex - Advanced logic, 20+ steps
+ 1. No - Works fine, just migrating platform
+ 2. Yes - Describe the issues
- WAIT for user selection (1-4)
- Store selection in {{complexity}}
+ WAIT for user selection (1-2)
+
+ Ask: "What issues should we fix during migration?"
+ WAIT for user input
+ Store in {{issues_to_fix}}
+
Ask Question 6: "What should the migrated workflow be named?"
WAIT for user input
diff --git a/src/modules/autominator/workflows/modify-workflow/instructions.md b/src/modules/autominator/workflows/modify-workflow/instructions.md
index 5f086d95..9fcc2e8a 100644
--- a/src/modules/autominator/workflows/modify-workflow/instructions.md
+++ b/src/modules/autominator/workflows/modify-workflow/instructions.md
@@ -29,6 +29,8 @@
+ Understand WHY the user wants to modify the workflow, not just WHAT to change
+
Ask Question 1: "Which workflow file do you want to modify?"
Present numbered options:
1. Provide file path - Specify exact path to workflow JSON
@@ -57,39 +59,43 @@
Store temp file path in {{workflow_file}}
- Ask Question 2: "What type of modification do you need?"
- Present numbered options:
- 1. Add new nodes - Add functionality to existing workflow
- 2. Modify existing nodes - Change node parameters or configuration
- 3. Remove nodes - Delete nodes from workflow
- 4. Change connections - Modify how nodes are connected
- 5. Update error handling - Add or modify retry/error logic
- 6. Optimize workflow - Improve performance or structure
- 7. Multiple changes - Combination of above
-
- WAIT for user selection (1-7)
- Store selection in {{modification_type}}
-
- Ask Question 3: "Please describe the changes you want to make"
+ Ask Question 2: "What problem are you trying to solve by modifying this workflow?"
+ Examples: "It's not handling errors properly", "Need to add Slack notifications", "Missing data validation"
WAIT for user input
- Store in {{changes_description}}
+ Store in {{problem_to_solve}}
-
- Ask: "What nodes do you want to add? (describe functionality)"
- WAIT for user input
- Store in {{nodes_to_add}}
-
+ Ask Question 3: "What's currently not working or missing?"
+ Encourage specific details about the issue or gap
+ WAIT for user input
+ Store in {{current_issue}}
-
- Ask: "Which nodes do you want to modify? (provide node names or descriptions)"
- WAIT for user input
- Store in {{nodes_to_modify}}
-
+ Ask Question 4: "What should the workflow do after these changes?"
+ Focus on the desired behavior and outcome
+ WAIT for user input
+ Store in {{desired_behavior}}
-
- Ask: "Which nodes do you want to remove? (provide node names)"
+ Ask Question 5: "Are there any specific nodes, integrations, or logic you want to change?"
+ Examples: "Add a Slack node after approval", "Change the IF condition to check status", "Remove the delay node"
+ WAIT for user input
+ Store in {{specific_changes}}
+
+ Summarize understanding:
+ - Problem: {{problem_to_solve}}
+ - Current Issue: {{current_issue}}
+ - Desired Behavior: {{desired_behavior}}
+ - Specific Changes: {{specific_changes}}
+
+ Ask: "Does this capture what you need?"
+ Present numbered options:
+ 1. Yes - Proceed with modifications
+ 2. No - Let me clarify
+
+ WAIT for user selection (1-2)
+
+ Ask: "What needs clarification?"
WAIT for user input
- Store in {{nodes_to_remove}}
+ Update relevant variables
+ Repeat summary and confirmation
diff --git a/src/modules/autominator/workflows/optimize-workflow/instructions.md b/src/modules/autominator/workflows/optimize-workflow/instructions.md
index b8823d11..caadb25a 100644
--- a/src/modules/autominator/workflows/optimize-workflow/instructions.md
+++ b/src/modules/autominator/workflows/optimize-workflow/instructions.md
@@ -29,6 +29,8 @@
+ Understand the REAL PROBLEMS the user is experiencing, not just generic optimization goals
+
Ask Question 1: "Which workflow do you want to optimize?"
Present numbered options:
1. Provide file path - Specify exact path to workflow JSON
@@ -57,30 +59,50 @@
Store temp file path in {{workflow_file}}
- Ask Question 2: "What aspects do you want to optimize?"
+ Ask Question 2: "What problems are you experiencing with this workflow?"
+ Examples: "Takes too long to run", "Fails frequently", "Hard to understand", "Doesn't handle errors well"
+ WAIT for user input
+ Store in {{problems_experienced}}
+
+ Ask Question 3: "What's the business impact of these problems?"
+ Examples: "Delays customer responses", "Wastes team time", "Causes data issues", "Costs money"
+ WAIT for user input
+ Store in {{business_impact}}
+
+ Ask Question 4: "What would 'better' look like for this workflow?"
+ Focus on desired outcomes: "Faster execution", "More reliable", "Easier to maintain", "Better error recovery"
+ WAIT for user input
+ Store in {{desired_improvements}}
+
+ Ask Question 5: "Are there specific areas you want me to focus on?"
Present numbered options (can select multiple):
- 1. Performance - Improve execution speed and efficiency
- 2. Error Handling - Add or improve error handling and retries
- 3. Code Quality - Improve node configuration and data transformations
- 4. Structure - Improve workflow organization and readability
- 5. Best Practices - Apply n8n best practices and patterns
- 6. Security - Improve credential handling and data security
- 7. All - Comprehensive optimization review
+ 1. Performance - Speed and efficiency
+ 2. Reliability - Error handling and retries
+ 3. Maintainability - Code quality and structure
+ 4. Security - Credential and data handling
+ 5. All - Comprehensive review
+ 6. Let you decide - Analyze and recommend
- WAIT for user selection (1-7 or multiple)
+ WAIT for user selection (1-6 or multiple)
Store selections in {{optimization_focus}}
- Ask Question 3: "Are there specific issues or pain points?"
+ Summarize understanding:
+ - Problems: {{problems_experienced}}
+ - Business Impact: {{business_impact}}
+ - Desired Improvements: {{desired_improvements}}
+ - Focus Areas: {{optimization_focus}}
+
+ Ask: "Does this capture your optimization needs?"
Present numbered options:
- 1. No - Just general optimization
- 2. Yes - Describe specific issues
+ 1. Yes - Proceed with analysis
+ 2. No - Let me clarify
WAIT for user selection (1-2)
-
- Ask: "Please describe the issues (slow execution, errors, etc.)"
+ Ask: "What needs clarification?"
WAIT for user input
- Store in {{specific_issues}}
+ Update relevant variables
+ Repeat summary and confirmation