KEMBAR78
Add nicer error message for agents without tools by jkornblum-nv · Pull Request #146 · NVIDIA/NeMo-Agent-Toolkit · GitHub
Skip to content

Conversation

@jkornblum-nv
Copy link
Contributor

Description

Adds a check for empty tools being used in agent configs. If we don't find any tools, raises an exception with the name of the llm in question to make debugging easier. Sample output:

aiq run --config_file workflow.yaml --input foo.msg
[...]
ValueError: No tools specified for ReAct Agent 'email_extraction_llm'
Error: No tools specified for ReAct Agent 'email_extraction_llm'

Closes #145

By Submitting this PR I confirm:

  • I am familiar with the Contributing Guidelines.
  • We require that all contributors "sign-off" on their commits. This certifies that the contribution is your original work, or you have rights to submit it under the same license, or a compatible license.
    • Any contribution which contains commits that are not Signed-Off will not be accepted.
  • When the PR is ready for review, new or existing tests cover these changes.
  • When the PR is ready for review, the documentation is up to date with these changes.

@jkornblum-nv jkornblum-nv requested a review from a team as a code owner April 24, 2025 22:13
@copy-pr-bot
Copy link

copy-pr-bot bot commented Apr 24, 2025

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

Signed-off-by: Jesse Kornblum <jkornblum@nvidia.com>
@yczhang-nv yczhang-nv added improvement Improvement to existing functionality non-breaking Non-breaking change labels Apr 24, 2025
@jkornblum-nv jkornblum-nv reopened this Apr 24, 2025
@jkornblum-nv
Copy link
Contributor Author

/merge

1 similar comment
@yczhang-nv
Copy link
Contributor

/merge

@rapids-bot rapids-bot bot merged commit eef6933 into NVIDIA:develop Apr 24, 2025
3 checks passed
yczhang-nv pushed a commit to yczhang-nv/NeMo-Agent-Toolkit that referenced this pull request May 8, 2025
Adds a check for empty tools being used in agent configs. If we don't find any tools, raises an exception with the name of the llm in question to make debugging easier. Sample output:

```
aiq run --config_file workflow.yaml --input foo.msg
[...]
ValueError: No tools specified for ReAct Agent 'email_extraction_llm'
Error: No tools specified for ReAct Agent 'email_extraction_llm'
```

Closes NVIDIA#145

## By Submitting this PR I confirm:
- I am familiar with the [Contributing Guidelines](https://github.com/NVIDIA/AgentIQ/blob/develop/docs/source/advanced/contributing.md).
- We require that all contributors "sign-off" on their commits. This certifies that the contribution is your original work, or you have rights to submit it under the same license, or a compatible license.
  - Any contribution which contains commits that are not Signed-Off will not be accepted.
- When the PR is ready for review, new or existing tests cover these changes.
- When the PR is ready for review, the documentation is up to date with these changes.

Authors:
  - Jesse Kornblum (https://github.com/jkornblum-nv)

Approvers:
  - Yuchen Zhang (https://github.com/yczhang-nv)

URL: NVIDIA#146
Signed-off-by: Yuchen Zhang <134643420+yczhang-nv@users.noreply.github.com>
AnuradhaKaruppiah pushed a commit to AnuradhaKaruppiah/oss-agentiq that referenced this pull request Aug 4, 2025
Adds a check for empty tools being used in agent configs. If we don't find any tools, raises an exception with the name of the llm in question to make debugging easier. Sample output:

```
aiq run --config_file workflow.yaml --input foo.msg
[...]
ValueError: No tools specified for ReAct Agent 'email_extraction_llm'
Error: No tools specified for ReAct Agent 'email_extraction_llm'
```

Closes NVIDIA#145 

## By Submitting this PR I confirm:
- I am familiar with the [Contributing Guidelines](https://github.com/NVIDIA/AgentIQ/blob/develop/docs/source/advanced/contributing.md).
- We require that all contributors "sign-off" on their commits. This certifies that the contribution is your original work, or you have rights to submit it under the same license, or a compatible license.
  - Any contribution which contains commits that are not Signed-Off will not be accepted.
- When the PR is ready for review, new or existing tests cover these changes.
- When the PR is ready for review, the documentation is up to date with these changes.

Authors:
  - Jesse Kornblum (https://github.com/jkornblum-nv)

Approvers:
  - Yuchen Zhang (https://github.com/yczhang-nv)

URL: NVIDIA#146
scheckerNV pushed a commit to scheckerNV/aiq-factory-reset that referenced this pull request Aug 22, 2025
Adds a check for empty tools being used in agent configs. If we don't find any tools, raises an exception with the name of the llm in question to make debugging easier. Sample output:

```
aiq run --config_file workflow.yaml --input foo.msg
[...]
ValueError: No tools specified for ReAct Agent 'email_extraction_llm'
Error: No tools specified for ReAct Agent 'email_extraction_llm'
```

Closes NVIDIA#145 

## By Submitting this PR I confirm:
- I am familiar with the [Contributing Guidelines](https://github.com/NVIDIA/AgentIQ/blob/develop/docs/source/advanced/contributing.md).
- We require that all contributors "sign-off" on their commits. This certifies that the contribution is your original work, or you have rights to submit it under the same license, or a compatible license.
  - Any contribution which contains commits that are not Signed-Off will not be accepted.
- When the PR is ready for review, new or existing tests cover these changes.
- When the PR is ready for review, the documentation is up to date with these changes.

Authors:
  - Jesse Kornblum (https://github.com/jkornblum-nv)

Approvers:
  - Yuchen Zhang (https://github.com/yczhang-nv)

URL: NVIDIA#146
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

improvement Improvement to existing functionality non-breaking Non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG]: Agents without tools generate confusing error message

2 participants