You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Adds explicit documentation clarifying that after creating a tool or retrieval search, it must be manually registered in the agent's tools list inside agent.py. This step was previously undocumented, causing confusion when newly created tools did not appear to work.
Added "Registering with an Agent" subsection under the Tools section in docs/agents-tools.md, with a callout note and code example showing the required import and tools = [...] pattern
Added "Registering Retrieval Tools with an Agent" subsection under the Retrieval Tools section in docs/agents-tools.md with the same pattern
Updated the Retrieval Tools Important prerequisite list to include agent registration as step 5
Updated the Content Workflow to split "Connect to Agent" into two explicit steps: creating the retrieval tool class and registering it in agent.py
Updated Table of Contents in docs/agents-tools.md to include the new subsections
Added a callout note at the top of the "Adding Tools" section in docs/getting-started.md explaining that tool definition and agent registration are two distinct required steps
Testing Done
Tested manually
Checklist
I have performed a self-review of my code
I have made corresponding changes to the documentation
My changes generate no new warnings
New and existing unit tests pass locally with my changes
Duplication with existing "Using in Agents" section
agents-tools.md already has a "Using in Agents" subsection under "Connecting to Retrievals" that shows the same pattern (from .searches import ProductDocsSearch / tools = [ProductDocsSearch()]). After merging, there would be two sections explaining the same thing ~40 lines apart, which is a maintenance risk — if one gets updated without the other, they'll contradict each other. I'd suggest unifying into a single canonical location.
Inconsistent import path in the example
The new example uses from ..tools import WeatherTool (double dot), but other places in the same file use from .tools import (single dot). Also, WeatherTool only exists as a standalone example in the previous section — it's not something the reader would have in agents/tools.py. This breaks the narrative flow. I'd suggest using tools from the getting-started guide or clarifying the assumption.
Agree with Virginia's feedback on migrations
The inline makemigrations/migrate block in the reference section gives the impression it must be done immediately after each registration. I'd suggest replacing it with a reference to the Content Workflow, where steps 8 and 9 are already properly separated.
Minor:
The SupportAgent example is missing required attributes (temperature, max_responses, initial_message, etc.) — a # ... other required attributes omitted for brevity would help prevent anyone from copying it as a complete template.
Both TOC entries show as "Registering with an Agent", making them indistinguishable — I'd suggest differentiating the second one as "Registering Retrieval Tools".
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
documentationImprovements or additions to documentation
3 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds explicit documentation clarifying that after creating a tool or retrieval search, it must be manually registered in the agent's
toolslist insideagent.py. This step was previously undocumented, causing confusion when newly created tools did not appear to work.Type of Change
Related Issues
Fixes #23
Changes Made
docs/agents-tools.md, with a callout note and code example showing the required import andtools = [...]patterndocs/agents-tools.mdwith the same patternImportantprerequisite list to include agent registration as step 5agent.pydocs/agents-tools.mdto include the new subsectionsdocs/getting-started.mdexplaining that tool definition and agent registration are two distinct required stepsTesting Done
Checklist