python-docs-samples icon indicating copy to clipboard operation
python-docs-samples copied to clipboard

feat: (Gen AI) Update the `document_retrieval` sample for embeddings

Open Valeriy-Burlaka opened this issue 1 year ago • 1 comments

Description

Updates the sample for the "Get text embeddings for a snippet of text" section of the embeddings page:

  • Fix the Example response
  • Provide more clear and idiomatic example of using the Vertex SDK
  • Show alternative ways to provide the input for the get_embeddings method.

Checklist

  • [x] I have followed Sample Guidelines from AUTHORING_GUIDE.MD
  • [ ] README is updated to include all relevant information
  • [x] Tests pass: nox -s py-3.8 && nox -s py-3.11
  • [x] Lint pass: nox -s lint
  • [ ] These samples need a new API enabled in testing projects to pass (let us know which ones)
  • [ ] These samples need a new/updated env vars in testing projects set to pass (let us know which ones)
  • [ ] This sample adds a new sample directory, and I updated the CODEOWNERS file with the codeowners for this sample
  • [ ] This sample adds a new Product API, and I updated the Blunderbuss issue/PR auto-assigner with the codeowners for this sample
  • [x] Please merge this PR for me once it is approved

Valeriy-Burlaka avatar Oct 04 '24 20:10 Valeriy-Burlaka

@msampathkumar, following the review comments to this PR, I can't decide if you deem these fixes helpful or not. If you believe that everything is OK with the sample in its current state, I can simply close this PR. Thanks!

Valeriy-Burlaka avatar Oct 14 '24 12:10 Valeriy-Burlaka

Hi @Valeriy-Burlaka Thank you for your work on this. For now, marking this request as closed.

msampathkumar avatar Nov 07 '24 14:11 msampathkumar