refactor: updates to advanced rag agent by sjrl · Pull Request #3934 · deepset-ai/haystack-core-integrations · GitHub
Skip to content

refactor: updates to advanced rag agent - #3934

Merged
sjrl merged 6 commits into
mainfrom
agent-pack/advanced-rag-agent-and-tools
Sep 9, 2026
Merged

sjrl merged 6 commits into
mainfrom
agent-pack/advanced-rag-agent-and-tools

Conversation

@sjrl

@sjrl sjrl commented Sep 9, 2026 •

Copy link
Copy Markdown
Contributor

Related Issues

Proposed Changes:

Contains just the changes to the existing advanced rag agent that I made while working on the harness optimization agent. These changes expose more of the advanced rag agent's configuration in the yaml file which I'm using as the reference for the optimizer agent to make changes to.

These changes expose more settings like the tools and their descriptions in the yaml file and add tracing support to the backup answer hook.

How did you test it?

New and existing tests.

Notes for the reviewer

Checklist

@sjrl sjrl self-assigned this Sep 9, 2026
@github-actions github-actions Bot added integration:agent-pack type:documentation Improvements or additions to documentation labels Sep 9, 2026
@github-actions

github-actions Bot commented Sep 9, 2026 •

Copy link
Copy Markdown
Contributor

Comment on lines 143 to 149
tools: list[Tool | Toolset] = [
DocumentStoreToolset(document_store, max_fetched_docs=max_fetched_docs),
ListMetadataFieldsTool(document_store),
GetMetadataFieldValuesTool(document_store),
GetMetadataFieldRangeTool(document_store),
FetchDocumentsByFilterTool(document_store, max_docs=max_fetched_docs),
retrieval_tool,
]

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The store tools are listed individually rather than bundled in a DocumentStoreToolset, so that each tool is present in the yaml config: its name, its description, and its own limits are then reachable, and a tool can be dropped by removing one entry.

Comment on lines +90 to +92

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Add internal tracing support for tracking token usage of the chat generator run inside the back up answer hook

@sjrl
sjrl marked this pull request as ready for review September 9, 2026 06:44
@sjrl
sjrl requested a review from a team as a code owner September 9, 2026 06:44
@sjrl
sjrl requested review from julian-risch and removed request for a team September 9, 2026 06:44

@julian-risch julian-risch left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks very good to me!

@sjrl
sjrl merged commit 6198b39 into main Sep 9, 2026
20 of 21 checks passed
@sjrl
sjrl deleted the agent-pack/advanced-rag-agent-and-tools branch September 9, 2026 09:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

integration:agent-pack type:documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants