AutomationMart
Home/Browse/AI agent that updates its own rules to modify behavior
n8n

AI agent that updates its own rules to modify behavior

n8nn8n13 modulesv1.0
agentaggregatechatTriggergoogleSheetsgoogleSheetsToollmChatAnthropicmemoryBufferWindowmergepostgrespostgresTool

Video walkthrough Summary of agent This agent can write and rewrite its own rules, allowing you to mold its behavior. It receives rules from a database as system instructions and has tools to create, edit, or delete them. This is a great baseline for new agent builds. You can tell it things like "Next time, use present tense when talking about this subject" and it will use a tool to save this as a rule, then receive that instruction in all fut

At a glance

AI agent that updates its own rules to modify behavior is a ready-made n8n workflow you import as a workflow JSON file — no build required. It connects agent, aggregate, chatTrigger, googleSheets. It's free to download. Follow the 5-step import below to go live in minutes.

Platform
n8n
Connects
agent, aggregate, chatTrigger, googleSheets, googleSheetsTool, lmChatAnthropic
Modules
13
Price
Free
Version
v1.0
AI agent that updates its own rules to modify behavior workflow diagram

About this workflow

Video walkthrough Summary of agent This agent can write and rewrite its own rules, allowing you to mold its behavior. It receives rules from a database as system instructions and has tools to create, edit, or delete them. This is a great baseline for new agent builds. You can tell it things like "Next time, use present tense when talking about this subject" and it will use a tool to save this as a rule, then receive that instruction in all future iterations. How to start using it Option 1: With a Postgres database (e.g., Supabase) 1. Supabase Schema: Create a table (e.g., agentrules) with the following columns: id: bigint (Primary Key, auto-incrementing) createdat: timestamp with time zone (Default: now()) ruletext: text agent: text 2. Workflow Updates: Update the Postgres credentials in the "Get rules from database," "Insert rule into database," and "Execute query on rule database" nodes. Update the agent value (currently 'TestAgent') in the "Get rules from database" and "Insert rule into database" nodes if you want a different agent name. Update the Anthropic API credentials. Option 2: With Google Sheets 1. Google Sheet Setup: Create a Google Sheet with columns for ruletext and agent. 2. Workflow Updates: Example Google Sheets nodes are included. You will need to: Connect your Google Sheets credentials. Select your Google Sheet (with ruletext and agent columns) in all relevant Google Sheets nodes. Replace the existing Postgres nodes ("Get rules from database", "Insert rule into database", "Execute query on rule database") with the configured Google Sheets nodes. Update the agent value (currently 'TestAgent') in the Google Sheets nodes if you want a different agent name. Update the Anthropic API credentials. Agent Instructions: Update the agent's system message and remove the database schema section as it is no longer relevant

n8n

How to import this n8n workflow

  1. 1

    Download the workflow JSON file after purchase.

  2. 2

    Open n8n → click the menu → Import from File.

  3. 3

    Select the downloaded JSON and import.

  4. 4

    Set up credentials for each node that requires them.

  5. 5

    Click Execute Workflow to test, then activate.

Setup guide

Setup guide included

Purchase to unlock the full step-by-step guide

Related N8n workflows

Automate personalized email campaigns with Google Docs, Sheets and SMTP

Emailing Using Google Sheet, Google Docs, and SMTP Automate personalized email campaigns using a Google Sheets contact list, a Google Docs template, and SMTP delivery. How It Works - Google Docs is used as the email template with variables: {{firstname}}, {{lastname}}, {{company}}, {{email}}. - Google Sheet contains your list of recipients (one per row). - For each contact, the workflow merges personal data into the Google Docs template. - Email is sent to each recipient via SMTP (batch size: 1)

Free

AI-powered research assistant for platform questions with GPT-4o and MCP

Description This workflow empowers you to effortlessly get answers to your n8n platform questions through an AI-powered assistant. Simply send your query, and the assistant will search documentation, forum posts, and example workflows to provide comprehensive, accurate responses tailored to your specific needs. > Note: This workflow uses community nodes (n8n-nodes-mcp.mcpClientTool) and will only work on self-hosted n8n instances. You'll need to install the required community nodes

Free

LinkedIn talent pipeline: AI-powered candidate search & ranking with GPT-4o

The Ultimate AI Recruiting Solution for Finding Perfect Candidates with GPT-4o Are you tired of manually sifting through hundreds of LinkedIn profiles to find the right talent? Say goodbye to inefficient recruiting processes and embrace the power of AI-driven candidate selection. Our AI Candidate Ranking Flow automates the entire process from job description to ranked candidate lists, saving you countless hours while delivering superior results. 💼 Key Features & Benefits - Automatic Candidate Di

Free

Generate & enrich LinkedIn leads with Apollo.io, LinkedIn API, Mail.so & GPT-3.5

Note: Now includes an Apify alternative for Rapid API (Some users can't create new accounts on Rapid API, so I have added an alternative for you. But immediately you are able to get access to Rapid API, please use that option, it returns more detailed data). Scroll to bottom for APify setup guide This n8n workflow automates LinkedIn lead generation, enrichment, and activity analysis using Apollo.io, RapidAPI, Google Sheets and Mail.so. Perfect for sales teams, f

Free

Generate AI videos and carousels with Blotato for Instagram and TikTok

Generate AI videos and carousels with Blotato and publish to Instagram & TikTok 📄 Documentation: Notion Guide Who is this for? This workflow is designed for content creators, marketers, solopreneurs, and automation enthusiasts who want to generate and publi

Free

Extract personal data with self-hosted LLM Mistral NeMo

This workflow shows how to use a self-hosted Large Language Model (LLM) with n8n's LangChain integration to extract personal information from user input. This is particularly useful for enterprise environments where data privacy is crucial, as it allows sensitive information to be processed locally. 📖 For a detailed explanation and more insights on using open-source LLMs with n8n, take a look at our comprehensive guide on open-source LLMs. 🔑 Key Features 1. Local LLM - Connect Ollama to run Mis

Free

Effortless email management with AI-powered summarization & review

How it Works This workflow automates the handling of incoming emails, summarizes their content, generates appropriate responses using a retrieval-augmented generation (RAG) approach, and obtains approval or suggestions before sending replies. Below is an explanation of its functionality divided into two main sections: 1. Email Handling and Summarization: - The process begins with the Email Trigger (IMAP) node which listens for new emails in a specified inbox. - Once an email is received, the M

Free

Automate sales for digital products & SaaS with AI (GPT-4o)

Skyrocket Your Sales Outreach with AI-Powered Automation! Tired of manually finding leads, collecting emails, and sending messages that get ignored? Let AI do the heavy lifting. Introducing AI-Powered Cold Outreach Engine, an n8n workflow that automates prospecting, email discovery, and personalized outreach, designed for digital products, SaaS, and online services. 🚀 How It Works 1️⃣ Smart Prospecting - Enter your product name, description, and link. - The AI searches Google Maps for busin

Free

Reviews

No reviews yet

Be the first to buy and share your experience.

Leave a review

Sign in to share your experience with this workflow.

Log in to review
Free
No ratings yet

Create a free account to purchase workflows.

  • JSON blueprint — instant download
  • Setup guide PDF included
  • 5 downloads · valid 30 days
  • Works with n8n

Need help setting this up?

Book a 3-hour live setup session with an Agility consultant.

₹2,499/ session
3 hrs · video call
  • Configure live on Google Meet / Zoom
  • Free follow-up if workflow has defects
  • Platform expert assigned to you
Book installation session
Free