-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added ML execute, get, search agent APIs.
Signed-off-by: Nathalie Jonathan <nathhjo@amazon.com>
- Loading branch information
1 parent
639fd57
commit 7158456
Showing
5 changed files
with
301 additions
and
3 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
$schema: ../../../../../json_schemas/test_story.schema.yaml | ||
|
||
description: Test the retrieval of agent information. | ||
version: '>= 2.13' | ||
prologues: | ||
- path: /_plugins/_ml/agents/_register | ||
id: register_agent | ||
method: POST | ||
request: | ||
payload: | ||
name: Test_Agent_For_RAG | ||
type: flow | ||
description: this is a test agent | ||
tools: | ||
- type: VectorDBTool | ||
parameters: | ||
model_id: YOUR_TEXT_EMBEDDING_MODEL_ID | ||
index: my_test_data | ||
embedding_field: embedding | ||
source_field: | ||
- text | ||
input: test_question | ||
- type: MLModelTool | ||
description: A general tool to answer any question | ||
parameters: | ||
model_id: YOUR_LLM_MODEL_ID | ||
output: | ||
test_agent_id: payload.agent_id | ||
epilogues: | ||
- path: /_plugins/_ml/agents/{agent_id} | ||
method: DELETE | ||
status: [200, 404] | ||
parameters: | ||
agent_id: ${register_agent.test_agent_id} | ||
chapters: | ||
- synopsis: Get agent information. | ||
method: GET | ||
path: /_plugins/_ml/agents/{agent_id} | ||
parameters: | ||
agent_id: ${register_agent.test_agent_id} | ||
response: | ||
status: 200 |
Oops, something went wrong.