Skip to content

Commit

Permalink
Update speech feature environment variable name
Browse files Browse the repository at this point in the history
  • Loading branch information
thivy committed Nov 15, 2023
1 parent 59b9088 commit 808c840
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion docs/3-run-locally.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ Clone this repository locally or fork to your Github account. Run all of the the

# Enabled must be set to "true" any other value will disable the feature

PUBLIC_NEXT_SPEECH_ENABLED=true
PUBLIC_SPEECH_ENABLED=true
AZURE_SPEECH_REGION=<region, e.g. australiaeast>
AZURE_SPEECH_KEY=

Expand Down
2 changes: 1 addition & 1 deletion docs/7-environment-variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Below are the required environment variables, to be added to the Azure Portal or
| `AZURE_SEARCH_INDEX_NAME` | | The index name with [vector search](https://learn.microsoft.com/en-us/azure/search/vector-search-overview) enabled |
| `AZURE_SEARCH_API_VERSION` | `2023-07-01-Preview` | API version which supports vector search `2023-07-01-Preview` |
| `AZURE_DOCUMENT_INTELLIGENCE_ENDPOINT` | `https://NAME.api.cognitive.microsoft.com/` | Endpoint url of the Azure document intelligence. The REGION is specific to your Azure resource location |
| `PUBLIC_NEXT_SPEECH_ENABLED` | Y | Whether speech should be enabled (microphone button appears). Must be "true" to enable, any other value (or blank) will disable. |
| `PUBLIC_SPEECH_ENABLED` | Y | Whether speech should be enabled (microphone button appears). Must be "true" to enable, any other value (or blank) will disable. |
| `AZURE_SPEECH_REGION` | australiaeast | Region of your Azure Speech service |
| `AZURE_SPEECH_KEY` | | API Key of Azure Speech service |
| |
2 changes: 1 addition & 1 deletion src/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -50,4 +50,4 @@ AZURE_SPEECH_REGION=
AZURE_SPEECH_KEY=

# Enabled must be set to "true" any other value will disable the feature
PUBLIC_NEXT_SPEECH_ENABLED=true
PUBLIC_SPEECH_ENABLED=true
4 changes: 2 additions & 2 deletions src/app/change-log/update.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ Below are the updates for the Azure Chat Solution accelerator

## 🎙️ Speech

Ability to use Azure Speech in conversations. This feature is not enabled by default. To enable this feature, you must set the environment variable `PUBLIC_NEXT_SPEECH_ENABLED=true` along with the Azure Speech subscription key and region.
Ability to use Azure Speech in conversations. This feature is not enabled by default. To enable this feature, you must set the environment variable `PUBLIC_SPEECH_ENABLED=true` along with the Azure Speech subscription key and region.

```
PUBLIC_NEXT_SPEECH_ENABLED=true
PUBLIC_SPEECH_ENABLED=true
AZURE_SPEECH_REGION="REGION"
AZURE_SPEECH_KEY="1234...."
```
Expand Down
2 changes: 1 addition & 1 deletion src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export default function RootLayout({
<html lang="en" className="h-full overflow-hidden">
<body className={cn(inter.className, "flex w-full h-full")}>
<GlobalConfigProvider
config={{ speechEnabled: process.env.PUBLIC_NEXT_SPEECH_ENABLED }}
config={{ speechEnabled: process.env.PUBLIC_SPEECH_ENABLED }}
>
<Providers>
<ThemeProvider attribute="class" defaultTheme="system" enableSystem>
Expand Down
2 changes: 1 addition & 1 deletion src/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const azureEnvVars = [
"ADMIN_EMAIL_ADDRESS",
"AZURE_SPEECH_REGION",
"AZURE_SPEECH_KEY",
"PUBLIC_PUBLIC_NEXT_SPEECH_ENABLED",
"PUBLIC_PUBLIC_SPEECH_ENABLED",
] as const;

type RequiredServerEnvKeys = (typeof azureEnvVars)[number];
Expand Down

0 comments on commit 808c840

Please sign in to comment.