This n8n template demonstrates how to automatically process feedback on tasks and procedures using an AI agent. Employees provide feedback after completing a task, which is then analyzed by the AI to suggest improvements to the underlying procedures. Improvements can be to update how to execute a single tasks or to split or merge tasks within a procedure. The management reviews decides whether to implement those improvements.
This makes it easy to close the loop between execution, feedback, and continuous process improvement. Use cases are many:
Procedures
table with general procedure information like to name or description .Procedures steps
table with all the steps associated with a procedure.Tasks
table that contains the actual tasks based on the procedure steps.
Feedback
Improvement suggestions
table to store the suggestions that were made by the AI agent.Set table and field ids
Feedback processing agent
The prompt contains a small instruction to check the feedback and suggest improvements to the procedures. The system message is much more extensive to provide as much details and guidance to the agent as possible. It contains the following sections:
* Role: giving the agent a clear professional perspective
* Goals: allowing the agent to focus on clarity, efficiency and actionable improvements.
* Instructions: guiding the agent to a step-by-step flow
* Output: showing the agent the expected format and details
* Notes: setting guardrails for the agent to make justified and practical suggestions.
The agent uses the following nodes:
* OpenAI Chat Model (Model): the template uses by default the gpt-4.1 model from OpenAI. But you can replace this with any LLM.
* current_procedures (Tool): provides information about all available procedures to the agent
* current_procedure steps (Tool): provides information about every step in the procedures to the agent
* tasks_feedback (Tool): provides the feedback of the employees to the agent.
* Required output schema (Output parser): forces the agent to use a JSON schema that matches the `Improvement suggestions` table structure for the output. This allows to easily add them to the database in the next step.
Create improvement suggestions
/api/database/rows/table/{table_id}/batch/
to insert multiple records at once in the Improvement suggestions
table. The inserted records is the output generated by the AI agent. Check the Baserow API documentation for further details.Get non-processed feedback
Tasks
table that contain feedback but that are not marked as processed yet.Set feedback to processed
Aggregate records for input
items
. This matches perfect with the Baserow API to insert new records in batch.Update tasks to processed feedback
/api/database/rows/table/{table_id}/batch/
to update multiple records at once in the Tasks
table. The updated records will have their processed field set to true. Check the Baserow API documentation for further details.Configure settings and ids
node.tasks_feedback
tool node matches with the ones in your Tasks
table.Get non-processed feedback
node matches with the ones in your Tasks
table.Set feedback to processed
node matches with the ones in your Tasks
table.