azure-search-openai-demo icon indicating copy to clipboard operation
azure-search-openai-demo copied to clipboard

Adding support for Azure OpenAI Deployment Types (Global Standard, Standard, Provisioned)

Open zedhaque opened this issue 1 year ago • 5 comments

Purpose

This PR add support for Azure OpenAI Deployment Types: Global Standard, Standard, and Provisioned. The default deployment type remains Standard.

Does this introduce a breaking change?

When developers merge from main and run the server, azd up, or azd deploy, will this produce an error? If you're not sure, try it out on an old environment.

[ ] Yes
[X] No

Does this require changes to learn.microsoft.com docs?

This repository is referenced by this tutorial which includes deployment, settings and usage instructions. If text or screenshot need to change in the tutorial, check the box below and notify the tutorial author. A Microsoft employee can do this for you if you're an external contributor.

[ ] Yes
[X ] No

Type of change

[ ] Bugfix
[X ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Documentation content changes
[ ] Other... Please describe:

Code quality checklist

See CONTRIBUTING.md for more details.

  • [ ] The current tests all pass (python -m pytest).
  • [ ] I added tests that prove my fix is effective or that my feature works
  • [ ] I ran python -m pytest --cov to verify 100% coverage of added lines
  • [ ] I ran python -m mypy to check for type errors
  • [ ] I either used the pre-commit hooks or ran ruff and black manually on my code.

zedhaque avatar Oct 02 '24 20:10 zedhaque

Check Broken URLs

We have automatically detected the following broken URLs in your files. Review and fix the paths to resolve this issue.

Check the file paths and associated broken URLs inside them. For more details, check our Contributing Guide.

File Full Path Issues
README.md
#LinkLine Number
1https://stackoverflow.com/questions/35569042/ssl-certificate-verify-failed-with-python3/43855394#43855394262
samples/chat/README.md
#LinkLine Number
1https://stackoverflow.com/questions/35569042/ssl-certificate-verify-failed-with-python3/43855394#43855394265

github-actions[bot] avatar Oct 02 '24 20:10 github-actions[bot]

FYI - docs for deployment types :

https://learn.microsoft.com/en-us/azure/ai-services/openai/how-to/deployment-types

zedhaque avatar Oct 02 '24 20:10 zedhaque

Thanks Zed! We actually are hoping to be able to default to GlobalStandard in the future, so this helps set us up for that. What about adding the sku name for the embedding deployment and vision deployment as well? I would think that if you need GlobalStandard for one, you'd need it for the others?

pamelafox avatar Oct 02 '24 22:10 pamelafox

Cool :) I will update the PR and add the embedding Sku Name later today.

zedhaque avatar Oct 02 '24 22:10 zedhaque

@pamelafox - I wanted to check if it’s alright to make the following variables are configurable together with the Sku Name fix? e.g. from main.bicep

param gpt4vModelName string = 'gpt-4o'
param gpt4vDeploymentName string = 'gpt-4o'
param gpt4vModelVersion string = '2024-05-13'
param gpt4vDeploymentCapacity int = 10

zedhaque avatar Oct 03 '24 22:10 zedhaque

@zedhaque Yes please make those configurable as well.

pamelafox avatar Oct 04 '24 16:10 pamelafox

@pamelafox - Please re-review. I have updated the files and added the GPT-4 vision parameters, with the previous values set as default. This can be changed just let me know. Thanks.

zedhaque avatar Oct 10 '24 04:10 zedhaque

I did an "azd up" from this branch on an existing environment, and that went fine, so it looks like this doesn't introduce any backwards incompatibility issues. I'll merge once CI completes. Thanks @zedhaque !

pamelafox avatar Oct 12 '24 00:10 pamelafox

Is there any documentation on how to deploy a provisioned GPT-4(o) Model after this merge? Is it possible to do the deploy in germanywestcentral? Thanks. :)

alenfrey avatar Oct 15 '24 09:10 alenfrey

If I am not mistaken it’s “ProvisionedManaged” so as per doc (https://github.com/Azure-Samples/azure-search-openai-demo/blob/main/docs/deploy_features.md#using-gpt-4) it will be

azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_SKU ProvisionedManaged

zedhaque avatar Oct 15 '24 09:10 zedhaque

Thank you so much, I had overlooked that while researching!

alenfrey avatar Oct 15 '24 09:10 alenfrey