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

rebase with master azurechat branch #1

Merged
merged 15 commits into from
Sep 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ yarn-error.log*

# local env files
.env*.local
.env

# typescript
*.tsbuildinfo
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Unleash the Power of Azure Open AI
# Unleash the Power of Azure OpenAI

1. [Introduction](#introduction)
1. [Solution Overview](/docs/1-introduction.md)
Expand All @@ -14,11 +14,11 @@

# Introduction

_Azure Chat Solution Accelerator powered by Azure Open AI Service_
_Azure Chat Solution Accelerator powered by Azure OpenAI Service_

![](/docs/images/intro.png)

_Azure Chat Solution Accelerator powered by Azure Open AI Service_ is a solution accelerator that allows organisations to deploy a private chat tenant in their Azure Subscription, with a familiar user experience and the added capabilities of chatting over your data and files.
_Azure Chat Solution Accelerator powered by Azure OpenAI Service_ is a solution accelerator that allows organisations to deploy a private chat tenant in their Azure Subscription, with a familiar user experience and the added capabilities of chatting over your data and files.

Benefits are:

Expand Down
3 changes: 3 additions & 0 deletions docs/8-extensions.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ As an example you can create an extension that calls Bing Search API to search f

In the example below only the `query` is required as Bing does not require a body parameter.

> [!NOTE]
> As header values specified for an extension often contain secrets (e.g. API keys) Azure Chat stores those values securely in Azure Key Vault. If you are deploying the solution to Azure using azd or the bicep templates the required Key Vault role assignment is automatically created. If you are running the solution locally you will need to manually add the "Key Vault Secrets Officer" role to identy that is running the solution (wh8ch will typically be the user logged into the Azure CLI)

# Bing Search Extension

1. **Name**: `Bing Search`
Expand Down
14 changes: 9 additions & 5 deletions docs/migration.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
# Migration
# Migration 2.1

The new changes merges GPT-4 and GPT-4 Vision models into a single GPT-4o model. This allows multi-modal inputs and generates text as an output. The new model is available within the following [regions](https://learn.microsoft.com/en-us/azure/ai-services/openai/concepts/models#gpt-4-and-gpt-4-turbo-preview-model-availability).

# Migration 2.0

The following changes and services are required to migrate from the old version to the new version.

Refer the `.env.example` file for the latest environment variable changes.

If you previously had Azure Chat running and have pulled the v2 version you will need at minimum to make the following changes:

* Change the "OPENAI_API_KEY" environment setting to "AZURE_OPENAI_API_KEY"
* Add an additional container to your Cosmos DB database called "config" with a partition key of "/userId"
* Add the "AZURE_KEY_VAULT_NAME" environment setting with the name of your Azure Key Vault
* Add the "New Azure Services" settings below if you wish to use these features
- Change the "OPENAI_API_KEY" environment setting to "AZURE_OPENAI_API_KEY"
- Add an additional container to your Cosmos DB database called "config" with a partition key of "/userId"
- Add the "AZURE_KEY_VAULT_NAME" environment setting with the name of your Azure Key Vault
- Add the "New Azure Services" settings below if you wish to use these features

## New Azure Services

Expand Down
35 changes: 9 additions & 26 deletions infra/main.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ param name string
@description('Primary location for all resources')
param location string

// azure open ai -- only regions supporting gpt-35-turbo v1106
// azure open ai -- regions currently support gpt-4o global-standard
@description('Location for the OpenAI resource group')
@allowed(['australiaeast', 'canadaeast', 'francecentral', 'southindia', 'uksouth', 'swedencentral', 'westus'])
@allowed(['australiaeast', 'brazilsouth', 'canadaeast', 'eastus', 'eastus2', 'francecentral', 'germanywestcentral', 'japaneast', 'koreacentral', 'northcentralus', 'norwayeast', 'polandcentral', 'spaincentral', 'southafricanorth', 'southcentralus', 'southindia', 'swedencentral', 'switzerlandnorth', 'uksouth', 'westeurope', 'westus', 'westus3'])
@metadata({
azd: {
type: 'location'
Expand All @@ -20,37 +20,26 @@ param location string
param openAILocation string

param openAISku string = 'S0'
param openAIApiVersion string = '2023-12-01-preview'
param openAIApiVersion string ='2024-08-01-preview'

param chatGptDeploymentCapacity int = 120
param chatGptDeploymentName string = 'chat-gpt-35-turbo'
param chatGptModelName string = 'gpt-35-turbo'
param chatGptModelVersion string = '1106'
param chatGptDeploymentCapacity int = 30
param chatGptDeploymentName string = 'gpt-4o'
param chatGptModelName string = 'gpt-4o'
param chatGptModelVersion string = '2024-05-13'
param embeddingDeploymentName string = 'embedding'
param embeddingDeploymentCapacity int = 120
param embeddingModelName string = 'text-embedding-ada-002'

// DALL-E v3 only supported in Sweden Central for now
// DALL-E v3 only supported in limited regions for now
@description('Location for the OpenAI DALL-E 3 instance resource group')
@allowed(['swedencentral'])
@allowed(['swedencentral', 'eastus', 'australiaeast'])
param dalleLocation string

param dalleDeploymentCapacity int = 1
param dalleDeploymentName string = 'dall-e-3'
param dalleModelName string = 'dall-e-3'
param dalleApiVersion string = '2023-12-01-preview'

// DALL-E v3 only supported in Sweden Central for now
@description('Location for the GPT vision instance resource')
@allowed(['swedencentral','westus',])
param gptvisionLocation string

param gptvisionDeploymentCapacity int = 1
param gptvisionDeploymentName string = 'gpt-4-vision'
param gptvisionModelName string = 'gpt-4'
param gptvisionApiVersion string = '2023-12-01-preview'
param gptvisionModelVersion string = 'vision-preview'

param formRecognizerSkuName string = 'S0'
param searchServiceIndexName string = 'azure-chat'
param searchServiceSkuName string = 'standard'
Expand Down Expand Up @@ -93,12 +82,6 @@ module resources 'resources.bicep' = {
dalleDeploymentName: dalleDeploymentName
dalleModelName: dalleModelName
dalleApiVersion: dalleApiVersion
gptvisionLocation: gptvisionLocation
gptvisionApiVersion: gptvisionApiVersion
gptvisionDeploymentCapacity: gptvisionDeploymentCapacity
gptvisionDeploymentName: gptvisionDeploymentName
gptvisionModelName: gptvisionModelName
gptvisionModelVersion: gptvisionModelVersion
formRecognizerSkuName: formRecognizerSkuName
searchServiceIndexName: searchServiceIndexName
searchServiceSkuName: searchServiceSkuName
Expand Down
Loading
Loading