“Установка n8n с mCP для мощной AI автоматизации”

Ниже приведён полный текст, который вы предоставили:

————————————————–

hey everyone welcome back today I’m
going to show you how to install NN
using Docker completely free and then
take it to the next level by
supercharging AI agents with mCP model
context protocol imagine this your AI
instantly connects to any tool or API no
messy HTTP requests no endless API docks
just pure automation magic that’s
exactly what mCP does it standardizes
tool execution making automation faster
smarter and 10x easier here’s what
you’ll master in just a few minutes
install n8n locally using Docker so you
can use it completely free set up mCP in
n8n to unlock powerful AI automation
enable AI Define and execute the best
tool dynamically no hard coding needed
automate web searches and web scraping
effortlessly using mCP and here’s the
kicker stick around till the end because
I’ll be revealing a secret automation
trick that even experienced AI Engineers
don’t know yet smash that like button
subscribe and turn on the Bell icon so
you never miss an automation hack before
we set up NN let’s quickly understand
what Docker is and why it’s a
GameChanger for automation think of
Docker as a virtual container system for
apps instead of installing software
directly on your computer Docker lets
you run applications in isolated
self-contained environments called
containers this means no messy and
installations no dependency conflicts
and no worrying about breaking your
system with Docker we can run NN in a
lightweight portable and secure
environment making it super easy to set
up and manage now that we know why
Docker is amazing let’s install Docker
desktop go to the official Docker
website download the version for your
operating system Windows or Mac run the
installer and follow the simple onscreen
instructions once installed open Docker
desktop and make sure it’s running
before moving forward now that we have
Docker desktop running let’s pull down
the N image and set up our AI automation
environment in Docker desktop go to the
search box at the top Type n and select
the official Nan image from the list
click download to pull the latest na
image wait for the download to complete
it may take a few moments depending on
your internet speed now that we have the
image let’s create a new container next
go to the images tab in Docker desktop
find the N image and click the Run
button now let’s configure it before we
start give your container a meaningful
name let’s call it NN container we need
to specify a port so we can access n via
a browser set it to
5678 or any other number you prefer so
we can access NN on that port to ensure
that our workflows and user settings are
saved we need to configure a volume in
the volume section set the host path to
a local folder where you want to store
n’s data for the container path set it
to this
path since we want to use AI agents with
mCP in NN we need to update the
environment variables we will need to
add this variable set the value to true
to enable Community nodes as tools
inside n
once everything is set up click the Run
button to start the container give it a
few seconds to initialize now let’s
check if it’s working open your browser
and go to Local Host on the port we just
set up you should now see the NN signup
screen let’s create an account fill in
all the necessary details including your
username email and password follow the
instructions to set up a new account
now click on this button to start a new
workflow awesome n8n is now fully set up
and ready to use next let’s install mCP
servers inside NN this will allow our AI
agents to interact seamlessly with
external tools and data sources navigate
to the setting section go to the
community nodes
tab here let’s search for n8n nodes and
mCP then click install and wait for the
installation to complete once installed
you’ll have access to mCP
functionalities within your
workflows return to the workflow section
and name your
workflow let’s say mCP server
agent okay next to initiate our workflow
based on user chat input We’ll add a
chat trigger
node all right now we’re going to add an
AI agent node to the workflow after
receiving the user’s chat message this
node enables the agent to utilize
external tools and apis to perform
actions and retrieve information now
let’s configure the AI agent node to use
the open AI chat model to use the model
you should create a new credential here
Ure you have an open AI account and have
generated an API key from the open AI
website here then input your open AI API
key into the noes credentials and hit
save button
we leave the desired model as GPT 40
mini to allow our agent to retain
conversational context we’ll incorporate
a simple memory node so let’s add the
simple memory node to the workflow and
connect it appropriately now let’s
Empower our AI agent by integrating
model context protocol servers providing
it with robust tools for complex tasks
first of all We’ll add the mCP client to
see how it works there’s a list of
actions here let’s try using this action
to list the available tools next we need
to add credentials to connect to the mCP
server here we’re using the command line
to integrate an mCP server with MPX in
the command field the arguments will
include the mCP server name to explore
available mCP servers we’ll visit their
GitHub page where we can see all the
server tools available for our workflow
for this example example we’ll use the
brave search server which allows us to
search for businesses restaurants and
services with detailed information to
use this mCP Brave server we need an API
key from the brave search API so let’s
create a new account to obtain the key
and copy it for later
use next we’ll add the mCP server name
to the argument field and input the
brave API key
all right finally we need to update the
environment with the brave API
key fill in the brave API key we just
copied after hitting save we specify the
action list tools for the operation now
we can test this node to retrieve the
available Brave tools we have two Brave
tools here along with their capabilities
awesome now that we know how to use the
mCP node in NN let’s add an mCP server
as a tool for the AI agent we’ll remove
the current mCP example click the plus
icon to add a new node for the agent and
select the mCP client to fetch a list of
Brave tools make sure to choose the
credentials we just created finally we
add another mCP node to allow the agent
to execute the tools
configure the AI agent to utilize the
tools retrieved from the brave search
mCP server set the operation to execute
tool and specify the tool name obtained
from the previous mCP nodes tools
configure the tool parameters as needed
or allow the model to Define them
automatically before running the
workflow let’s define a system message
to guide the AI agent in its role such
as you are a helpful assistant utilizing
Brave search to perform web queries
alternatively you can use our system
message next ensure all nodes are
properly connected to facilitate smooth
data flow and execution within the
workflow once everything is set we’re
ready to test the workflow open the chat
box and send a message asking the agent
about restaurants or
cafes monitor the workflow execution to
make sure the AI agent interacts with
the mCP server as expected let’s dive
into how our AI agent processes user
inputs initially the agent captures both
the user’s message and the predefined
system instructions storing them in the
simple memory node this ensures context
is maintained throughout the interaction
the stored messages are then forwarded
to the open AI chat model node here the
AI interprets the user’s request and
determines that utilizing the brave
Search tool is the optimal approach to
fulfill the task the AI agent the mCP
client node to interface with the brave
search mCP server it performs the
necessary search operations based on the
user’s query after obtaining the search
results the Open aai chat model
processes the data transforming it into
a coherent and informative response
tailored for the user finally the AI
agent delivers the human readable
information back to the user effectively
completing the workflow Awesome by
integrating mCP servers like Brave
search into our n8n workflows we’ve
empowered our AI agents to perform
complex tasks efficiently providing
users with accurate and timely
information stay tuned for more
tutorials on enhancing your automation
workflows if you found this guide
helpful like subscribe and hit the
notification Bell to stay updated with
the latest automation tips see you in
the next
[Music]
video what

————————————————–

Если вам потребуется дополнительная информация или помощь с разбором отдельных частей, дайте знать!

Отправить комментарий