Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(core): Make Tools Agent the default Agent type, deprecate other agent types #13459

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

Cadiac
Copy link
Contributor

@Cadiac Cadiac commented Feb 24, 2025

Summary

Users have found the Agent type selection to be confusing, and in vast majority of the cases Tools Agent is the only recommended Agent type to use. To simplify the usage of this very popular node other Agent types are going to be deprecated, and on new version 1.8 Agent nodes the dropdown selection for Agent type is no longer displayed, and toolsAgent is used by default.

image

On old Agent node's a deprecation warning is shown.

image

Also added maxIterations options on all Agent node types on pre-1.8 Agent nodes, this was missing from ReAct, PlanAndExecute and SqlAgent.

image

Related Linear tickets, Github issues, and Community forum posts

https://linear.app/n8n/issue/ADO-2779/feature-agent-node-get-rid-of-type-drop-down

Review / Merge checklist

  • PR title and summary are descriptive. (conventions)
  • Docs updated or follow-up ticket created.
  • Tests included.
  • PR Labeled with release/backport (if the PR is an urgent fix that needs to be backported)

@Cadiac Cadiac changed the title feat(core): Make Tools agent the default Agent type, deprecate other Agent types feat(core): Make Tools Agent the default Agent type, deprecate other agent types Feb 24, 2025
Copy link

codecov bot commented Feb 24, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

📢 Thoughts on this report? Let us know!

@n8n-assistant n8n-assistant bot added the n8n team Authored by the n8n team label Feb 24, 2025
mutdmour
mutdmour previously approved these changes Feb 24, 2025
Copy link
Contributor

@mutdmour mutdmour left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. I know e2e tests might fail, so approving to help you get an idea as well.

Copy link

cypress bot commented Feb 24, 2025

n8n    Run #9435

Run Properties:  status check passed Passed #9435  •  git commit 53a97e6820: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 Cadiac 🗃️ e2e/*
Project n8n
Branch Review ado-2779-feature-agent-node-get-rid-of-type-drop-down
Run status status check passed Passed #9435
Run duration 04m 44s
Commit git commit 53a97e6820: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 Cadiac 🗃️ e2e/*
Committer Jaakko Husso
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 3
Tests that did not run due to a developer annotating a test with .skip  Pending 5
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 437
View all changes introduced in this branch ↗︎

Copy link
Contributor

✅ All Cypress E2E specs passed

@@ -96,6 +96,13 @@ export const reActAgentAgentProperties: INodeProperties[] = [
rows: 6,
},
},
{
displayName: 'Max Iterations',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this already used? testing on the test instance and it does not seem to have an effect?

Copy link
Contributor Author

@Cadiac Cadiac Feb 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, you're right. I suppose I had mistakenly assumed the logic where these options was read and passed to the executor was generic and applied to all of these, but it was only on some.

Now actually looking into this it appears that only new place where maxIterations can be supported is ReActAgent, as the other langchain executors used on these other node types (PlanAndExecuteAgent, SqlAgent) don't seem to support it.

I'm removing maxIterations from PlanAndExecuteAgent and SqlAgent and properly passing it on ReActAgent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
n8n team Authored by the n8n team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants