Skip to content

Conversation

mingshl
Copy link
Collaborator

@mingshl mingshl commented Aug 20, 2025

Description

Add tutorial for agentic search

Related Issues

Resolves #[Issue number to be closed when this PR is merged]

Check List

  • New functionality includes testing.
  • New functionality has been documented.
  • API changes companion pull request created.
  • Commits are signed per the DCO using --signoff.
  • Public documentation issue/PR created.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@mingshl mingshl marked this pull request as ready for review August 20, 2025 19:58
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 19:59 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 19:59 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 19:59 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 19:59 — with GitHub Actions Inactive
dhrubo-os
dhrubo-os previously approved these changes Aug 20, 2025
@dhrubo-os
Copy link
Collaborator

Approved without reviewing to unblock.

Zhangxunmt
Zhangxunmt previously approved these changes Aug 20, 2025
This is an experimental feature and is not recommended for use in a production environment. For updates on the progress of the feature or if you want to leave feedback, join the discussion on the [OpenSearch forum](https://forum.opensearch.org/).
{: .warning}

Agentic Search is a new query type proposed in OpenSearch that triggers an agent-driven workflow for query understanding, planning and execution. Instead of hand-crafting DSL, you supply a natural language question and an agent id; the agent executes a Query Planning Toolwith index/mapping introspection, and guide LLMs to produce OpenSearch DSL and run it through agentic query clause and return the search hits based on it.
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit:
add space at Toolwith
In this part an agent-driven workflow for query understanding, looks like we are suggesting we give an explanation to the query, maybe reword a little?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

added space for formatting, and query understanding is terminology in search, check this https://en.wikipedia.org/wiki/Query_understanding

"request_processors": [
{
"agentic_query_translator": {
"agent_id": "your_agent_id"
Copy link
Collaborator

@Zhangxunmt Zhangxunmt Aug 20, 2025

Choose a reason for hiding this comment

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

If this processor takes a model_id and implements the tools logics inside the processor, so we can get rid of the agent steps 4 and 5? We can implement a default agent inside this processor to simplify?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

we don't have default agent for now, but we will consider about it

Signed-off-by: Mingshi Liu <[email protected]>
@mingshl mingshl dismissed stale reviews from Zhangxunmt and dhrubo-os via e8c11ab August 20, 2025 20:58
Zhangxunmt
Zhangxunmt previously approved these changes Aug 20, 2025
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 20:59 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 20:59 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 20:59 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 20:59 — with GitHub Actions Inactive
Signed-off-by: Mingshi Liu <[email protected]>
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 21:01 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 21:01 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 21:01 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 21:01 — with GitHub Actions Inactive
@@ -0,0 +1,685 @@
---
layout: default
title: Agentic search with a llmGenerated query type
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can we tune the title ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I would try to open new PR for remaining comments, let's merge for unblocking the release blog.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

changed the title in the new PR #4128

please move the discussion to the following PR , thanks

@mingshl mingshl merged commit 6059afb into opensearch-project:main Aug 20, 2025
9 checks passed
Copy link

codecov bot commented Aug 20, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 81.65%. Comparing base (984b13a) to head (798a936).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##               main    #4127   +/-   ##
=========================================
  Coverage     81.64%   81.65%           
  Complexity     8830     8830           
=========================================
  Files           761      761           
  Lines         38099    38099           
  Branches       4250     4250           
=========================================
+ Hits          31107    31110    +3     
+ Misses         5166     5163    -3     
  Partials       1826     1826           
Flag Coverage Δ
ml-commons 81.65% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 22:05 — with GitHub Actions Inactive
@mingshl mingshl temporarily deployed to ml-commons-cicd-env August 20, 2025 22:05 — with GitHub Actions Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants