-
Notifications
You must be signed in to change notification settings - Fork 156
support customized message endpoint and addressing comments #3810
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
support customized message endpoint and addressing comments #3810
Conversation
Signed-off-by: zane-neo <[email protected]>
Signed-off-by: zane-neo <[email protected]>
Signed-off-by: zane-neo <[email protected]>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3810 +/- ##
============================================
- Coverage 78.20% 77.98% -0.22%
- Complexity 7162 7314 +152
============================================
Files 631 655 +24
Lines 32248 32998 +750
Branches 3666 3708 +42
============================================
+ Hits 25219 25733 +514
- Misses 5465 5677 +212
- Partials 1564 1588 +24
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Signed-off-by: zane-neo <[email protected]>
Signed-off-by: zane-neo <[email protected]>
Signed-off-by: zane-neo <[email protected]>
@@ -79,14 +81,17 @@ public static McpTool parse(XContentParser parser) throws IOException { | |||
case TYPE_FIELD: | |||
type = parser.text(); | |||
break; | |||
case NAME_FIELD: | |||
name = parser.text(); | |||
break; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let add this in the test? it should be quite easy.
@@ -375,7 +375,17 @@ List<String> jacocoExclusions = [ | |||
'org.opensearch.ml.action.tasks.CancelBatchJobTransportAction', | |||
'org.opensearch.ml.jobs.MLBatchTaskUpdateExtension', | |||
'org.opensearch.ml.jobs.MLBatchTaskUpdateJobRunner', | |||
'org.opensearch.ml.action.agents.TransportRegisterAgentAction' | |||
'org.opensearch.ml.action.agents.TransportRegisterAgentAction', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Please create an issue about improving test coverage for these classes
- Please add this issue as a todo in the code.
Thanks. We need to be mindful to increase this exclusion list more and more.
if (ssePrefix) { | ||
result = String.format(Locale.ROOT, "/sse/message?sessionId=%s", sessionId); | ||
} else { | ||
result = String.format(Locale.ROOT, "/message?sessionId=%s", sessionId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add test?
.collect(Collectors.toSet()); | ||
if (!unrecognizedTools.isEmpty()) { | ||
exception.addValidationError(String.format(Locale.ROOT, "Unrecognized tool in request: {}", unrecognizedTools)); | ||
exception.addValidationError(String.format(Locale.ROOT, "Unrecognized tool in request: %s", unrecognizedTools)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be quite easy to add a test on this.
Approving this PR for now just to unblock other PRs. But Please address these comments in another PR. Thanks. |
* support customized message endpoint and addressing comments Signed-off-by: zane-neo <[email protected]> * fix UT failures Signed-off-by: zane-neo <[email protected]> * add files to jacoco exception Signed-off-by: zane-neo <[email protected]> * fix tool name issue and optimize register tool api Signed-off-by: zane-neo <[email protected]> * fix schema not parsed correctly issue and NPE when parameters is null Signed-off-by: zane-neo <[email protected]> * fix failure UT Signed-off-by: zane-neo <[email protected]> --------- Signed-off-by: zane-neo <[email protected]> (cherry picked from commit 887c90a)
…3817) * support customized message endpoint and addressing comments * fix UT failures * add files to jacoco exception * fix tool name issue and optimize register tool api * fix schema not parsed correctly issue and NPE when parameters is null * fix failure UT --------- (cherry picked from commit 887c90a) Signed-off-by: zane-neo <[email protected]> Co-authored-by: zane-neo <[email protected]>
Sure, will create issue to track on the UT coverage. |
* [BUG] Agent Framework: Handle model response when toolUse is not accompanied by text (#3755) * fix: handle model response when toolUse is not accompanied by text Signed-off-by: Pavan Yekbote <[email protected]> * feat: add test case for parseLLMOutput Signed-off-by: Pavan Yekbote <[email protected]> --------- Signed-off-by: Pavan Yekbote <[email protected]> * [BUG] Allow user to control react agent max_interations value to prevent empty response (#3756) * fix: expose max_iteration for react Signed-off-by: Pavan Yekbote <[email protected]> * fix: defaults for agent execution and differentiate between step and step result Signed-off-by: Pavan Yekbote <[email protected]> * fix: return react agent id in agent response to expose more details Signed-off-by: Pavan Yekbote <[email protected]> * spotless Signed-off-by: Pavan Yekbote <[email protected]> * fix: remove test prompt from react system prompt Signed-off-by: Pavan Yekbote <[email protected]> * refactor: rename parameters exposed to user to executor Signed-off-by: Pavan Yekbote <[email protected]> * fix: give user complete control over planner system prompt Signed-off-by: Pavan Yekbote <[email protected]> --------- Signed-off-by: Pavan Yekbote <[email protected]> * Clean up JSM from MCP (#3773) Signed-off-by: rithin-pullela-aws <[email protected]> * [Bug] ListTools call does not return tool attributes (#3785) * initial commit for MCP server in OpenSearch (#3781) * initial commit for MCP server in OpenSearch Signed-off-by: zane-neo <[email protected]> * Make change to support register or remove tools across cluster Signed-off-by: zane-neo <[email protected]> * format code Signed-off-by: zane-neo <[email protected]> * fix UT failure caused by code change Signed-off-by: zane-neo <[email protected]> * format code Signed-off-by: zane-neo <[email protected]> * format code Signed-off-by: zane-neo <[email protected]> * add license header Signed-off-by: zane-neo <[email protected]> * fix notifications initialized not respond issue Signed-off-by: zane-neo <[email protected]> * fix minor issues and add UTs Signed-off-by: zane-neo <[email protected]> * Add more UTs Signed-off-by: zane-neo <[email protected]> --------- Signed-off-by: zane-neo <[email protected]> * Remove beta1 qualifier (#3794) (#3795) (cherry picked from commit 3f503f1) Signed-off-by: Peter Zhu <[email protected]> Co-authored-by: Peter Zhu <[email protected]> * [AUTO] Increment version to 3.1.0-SNAPSHOT (#3789) * Increment version to 3.1.0-SNAPSHOT Signed-off-by: opensearch-ci-bot <[email protected]> * Update build.gradle Signed-off-by: Peter Zhu <[email protected]> --------- Signed-off-by: opensearch-ci-bot <[email protected]> Signed-off-by: Peter Zhu <[email protected]> Co-authored-by: opensearch-ci-bot <[email protected]> Co-authored-by: Peter Zhu <[email protected]> * add release note for 3.0 (#3792) Signed-off-by: Mingshi Liu <[email protected]> * support MCP session management (#3803) * support MCP session management Signed-off-by: zane-neo <[email protected]> * Addressing comments Signed-off-by: zane-neo <[email protected]> * add feature flag for mcp server and renaming mcp connector feature flag Signed-off-by: zane-neo <[email protected]> * Address critical comments in #3781 Signed-off-by: zane-neo <[email protected]> --------- Signed-off-by: zane-neo <[email protected]> * upgrade http client to version align with core (#3809) * upgrade http client to versoin align with core Signed-off-by: zane-neo <[email protected]> * upgrade httpclient-h2 to correct versiono Signed-off-by: zane-neo <[email protected]> * use placeholder approach Signed-off-by: zane-neo <[email protected]> --------- Signed-off-by: zane-neo <[email protected]> * support customized message endpoint and addressing comments (#3810) * support customized message endpoint and addressing comments Signed-off-by: zane-neo <[email protected]> * fix UT failures Signed-off-by: zane-neo <[email protected]> * add files to jacoco exception Signed-off-by: zane-neo <[email protected]> * fix tool name issue and optimize register tool api Signed-off-by: zane-neo <[email protected]> * fix schema not parsed correctly issue and NPE when parameters is null Signed-off-by: zane-neo <[email protected]> * fix failure UT Signed-off-by: zane-neo <[email protected]> --------- Signed-off-by: zane-neo <[email protected]> * excluding circuit breaker for Agent (#3814) Signed-off-by: Dhrubo Saha <[email protected]> * change release note (#3811) * change release note Signed-off-by: zane-neo <[email protected]> * Update opensearch-ml-common.release-notes-3.0.0.0.md * Update opensearch-ml-common.release-notes-3.0.0.0.md * Update opensearch-ml-common.release-notes-3.0.0.0.md --------- Signed-off-by: zane-neo <[email protected]> Co-authored-by: Peter Zhu <[email protected]> * Downgrade MCP version to 0.9 (#3821) Signed-off-by: rithin-pullela-aws <[email protected]> * remove libs folder (#3824) Signed-off-by: Yaliang Wu <[email protected]> * add more logging to deploy/undeploy flows for better debugging (#3825) * add more logging to deploy/undeploy flows for better debugging Signed-off-by: Bhavana Goud Ramaram <[email protected]> * Fix python client not able to connect to MCP server issue (#3822) Signed-off-by: zane-neo <[email protected]> Co-authored-by: Dhrubo Saha <[email protected]> * exclude trusted connector check for hidden model (#3838) Signed-off-by: Dhrubo Saha <[email protected]> * adding tenantId to the connector executor when this is inline connector (#3837) * adding tenantId to the connector executor when this is inline connector Signed-off-by: Dhrubo Saha <[email protected]> * added more unit tests Signed-off-by: Dhrubo Saha <[email protected]> --------- Signed-off-by: Dhrubo Saha <[email protected]> --------- Signed-off-by: Pavan Yekbote <[email protected]> Signed-off-by: rithin-pullela-aws <[email protected]> Signed-off-by: zane-neo <[email protected]> Signed-off-by: Peter Zhu <[email protected]> Signed-off-by: opensearch-ci-bot <[email protected]> Signed-off-by: Mingshi Liu <[email protected]> Signed-off-by: Dhrubo Saha <[email protected]> Signed-off-by: Yaliang Wu <[email protected]> Signed-off-by: Bhavana Goud Ramaram <[email protected]> Co-authored-by: Pavan Yekbote <[email protected]> Co-authored-by: Rithin Pullela <[email protected]> Co-authored-by: zane-neo <[email protected]> Co-authored-by: opensearch-trigger-bot[bot] <98922864+opensearch-trigger-bot[bot]@users.noreply.github.com> Co-authored-by: Peter Zhu <[email protected]> Co-authored-by: opensearch-ci-bot <[email protected]> Co-authored-by: Mingshi Liu <[email protected]> Co-authored-by: Yaliang Wu <[email protected]> Co-authored-by: Bhavana Goud Ramaram <[email protected]>
Description
support customized message endpoint and addressing comments
Related Issues
Resolves #[Issue number to be closed when this PR is merged]
Check List
--signoff
.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.