Skip to content
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

adding blue print doc for cohere multi-modal model #3229

Merged
merged 3 commits into from
Nov 19, 2024

Conversation

dhrubo-os
Copy link
Collaborator

Description

[ adding blue print doc for cohere multi-modal model]

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.

Signed-off-by: Dhrubo Saha <[email protected]>
@@ -0,0 +1,324 @@
### Cohere Embedding Connector Blueprint:

This blueprint will show you how to connect a Cohere multi-modal embedding model to your Opensearch cluster, including creating a k-nn index and your own Embedding pipeline. You will require a Cohere API key to create a connector.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Opensearch -> OpenSearch

"url": "https://api.cohere.ai/v1/embed",
"headers": {
"Authorization": "Bearer ${credential.cohere_key}",
"Request-Source": "unspecified:opensearch"
Copy link
Collaborator

Choose a reason for hiding this comment

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

is Request-Source required?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

yup

POST /_plugins/_ml/models/<MODEL_ID>/_deploy
```

This will once again spawn a task to deploy your Model, with a response that will look like:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Model -> model. lower case

GET /_plugins/_ml/tasks/<TASK_ID>
```

Once this is complete, your Model is deployed and ready!
Copy link
Collaborator

Choose a reason for hiding this comment

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

Model -> model


##### 1e. Test model

You can try this request to test that the Model behaves correctly:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Model -> model

Signed-off-by: Dhrubo Saha <[email protected]>
mingshl
mingshl previously approved these changes Nov 19, 2024
"id": {
"type": "text"
},
"passage_embedding": {
Copy link
Collaborator

Choose a reason for hiding this comment

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

How about changing to image_embedding ?

And passage_text -> image_base64

Signed-off-by: Dhrubo Saha <[email protected]>
@dhrubo-os dhrubo-os temporarily deployed to ml-commons-cicd-env November 19, 2024 17:59 — with GitHub Actions Inactive
@mingshl
Copy link
Collaborator

mingshl commented Nov 19, 2024

reran the bwc tests twice and still failing. can you look into it please?

@dhrubo-os
Copy link
Collaborator Author

reran the bwc tests twice and still failing. can you look into it please?

That's flaky. One BWC test is passing now. And this changes doesn't have any relation with the BWC test.

@mingshl
Copy link
Collaborator

mingshl commented Nov 19, 2024

approved, but please create issue for the flaky test to track them or once it's merged, we cannot track the log

@dhrubo-os dhrubo-os merged commit de301b7 into opensearch-project:2.x Nov 19, 2024
7 of 13 checks passed
@opensearch-trigger-bot
Copy link
Contributor

The backport to feature/multi_tenancy failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-feature/multi_tenancy feature/multi_tenancy
# Navigate to the new working tree
cd .worktrees/backport-feature/multi_tenancy
# Create a new branch
git switch --create backport/backport-3229-to-feature/multi_tenancy
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 de301b739b2bdc590cfbdb28682a0b53c5988cdb
# Push it to GitHub
git push --set-upstream origin backport/backport-3229-to-feature/multi_tenancy
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-feature/multi_tenancy

Then, create a pull request where the base branch is feature/multi_tenancy and the compare/head branch is backport/backport-3229-to-feature/multi_tenancy.

opensearch-trigger-bot bot pushed a commit that referenced this pull request Nov 19, 2024
* adding blue print doc

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comments

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comment

Signed-off-by: Dhrubo Saha <[email protected]>

---------

Signed-off-by: Dhrubo Saha <[email protected]>
(cherry picked from commit de301b7)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Nov 19, 2024
* adding blue print doc

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comments

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comment

Signed-off-by: Dhrubo Saha <[email protected]>

---------

Signed-off-by: Dhrubo Saha <[email protected]>
(cherry picked from commit de301b7)
dhrubo-os added a commit that referenced this pull request Nov 19, 2024
* adding blue print doc

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comments

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comment

Signed-off-by: Dhrubo Saha <[email protected]>

---------

Signed-off-by: Dhrubo Saha <[email protected]>
(cherry picked from commit de301b7)

Co-authored-by: Dhrubo Saha <[email protected]>
dhrubo-os added a commit that referenced this pull request Nov 19, 2024
* adding blue print doc

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comments

Signed-off-by: Dhrubo Saha <[email protected]>

* addressed comment

Signed-off-by: Dhrubo Saha <[email protected]>

---------

Signed-off-by: Dhrubo Saha <[email protected]>
(cherry picked from commit de301b7)

Co-authored-by: Dhrubo Saha <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants