Skip to content

Commit 7ddcdfb

Browse files
authored
rename env variables (Azure#37646)
### Packages impacted by this PR ### Issues associated with this PR ### Describe the problem that is addressed by this PR ### rename env varibales AZURE_AI_PROJECT_ENDPOINT to FOUNDRY_PROJECT_ENDPOINT MODEL_DEPLOYMENT_NAME to FOUNDRY_MODEL_NAME AZURE_AI_AGENT_NAME to FOUNDRY_AGENT_NAME AZURE_AI_MODEL_DEPLOYMENT_NAME to FOUNDRY_MODEL_NAME AZURE_AI_CHAT_MODEL_DEPLOYMENT_NAME to MEMORY_STORE_CHAT_MODEL_DEPLOYMENT_NAME AZURE_AI_EMBEDDING_MODEL_DEPLOYMENT_NAME to MEMORY_STORE_EMBEDDING_MODEL_DEPLOYMENT_NAME ### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen? ### Are there test cases added in this PR? _(If not, why?)_ ### Provide a list of related PRs _(if any)_ ### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_ ### Checklists - [ ] Added impacted package name to the issue description - [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_ - [ ] Added a changelog (if necessary)
1 parent 24c5d3a commit 7ddcdfb

File tree

412 files changed

+1027
-1014
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

412 files changed

+1027
-1014
lines changed

sdk/ai/ai-projects/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ The client library uses version `v1` of the Microsoft Foundry [data plane REST A
3737
[Product documentation](https://aka.ms/azsdk/azure-ai-projects-v2/product-doc)
3838
| [Samples](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/ai/ai-projects/samples)
3939
| [Package (npm)](https://www.npmjs.com/package/@azure/ai-projects)
40-
| [API reference documentation](https://learn.microsoft.com/javascript/api/overview/azure/ai-projects-readme?view=azure-node-preview)
40+
| [API reference documentation](https://learn.microsoft.com/javascript/api/overview/azure/ai-projects-readme?view=azure-node-latest)
4141
| [SDK source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/ai/ai-projects)
4242

4343
## Table of contents
@@ -78,7 +78,7 @@ The client library uses version `v1` of the Microsoft Foundry [data plane REST A
7878
- [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule)
7979
- An [Azure subscription][azure_sub].
8080
- A [project in Microsoft Foundry](https://learn.microsoft.com/azure/ai-studio/how-to/create-projects).
81-
- The project endpoint URL of the form `https://your-ai-services-account-name.services.ai.azure.com/api/projects/your-project-name`. It can be found in your Microsoft Foundry Project overview page. Below we will assume the environment variable `AZURE_AI_PROJECT_ENDPOINT` was defined to hold this value.
81+
- The project endpoint URL of the form `https://your-ai-services-account-name.services.ai.azure.com/api/projects/your-project-name`. It can be found in your Microsoft Foundry Project overview page. Below we will assume the environment variable `FOUNDRY_PROJECT_ENDPOINT` was defined to hold this value.
8282

8383
### Authorization
8484

@@ -100,13 +100,13 @@ npm install @azure/ai-projects dotenv
100100

101101
Entra ID is the only authentication method supported at the moment by the client.
102102

103-
To construct an `AIProjectsClient`, the `projectEndpoint` can be fetched from [projectEndpoint][ai_project_client_endpoint]. Below we will assume the environment variable `AZURE_AI_PROJECT_ENDPOINT` was defined to hold this value:
103+
To construct an `AIProjectsClient`, the `projectEndpoint` can be fetched from [projectEndpoint][ai_project_client_endpoint]. Below we will assume the environment variable `FOUNDRY_PROJECT_ENDPOINT` was defined to hold this value:
104104

105105
```ts snippet:setup
106106
import { AIProjectClient } from "@azure/ai-projects";
107107
import { DefaultAzureCredential } from "@azure/identity";
108108

109-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint string>";
109+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint string>";
110110
project = new AIProjectClient(projectEndpoint, new DefaultAzureCredential());
111111
```
112112

@@ -533,7 +533,7 @@ The `embeddingModelDeployment` is the name of the model used to create vector em
533533
```ts snippet:agent-memory-search
534534
const memoryStoreName = "AgentMemoryStore";
535535
const embeddingModelDeployment =
536-
process.env["AZURE_AI_EMBEDDING_MODEL_DEPLOYMENT_NAME"] || "<embedding model>";
536+
process.env["MEMORY_STORE_EMBEDDING_MODEL_DEPLOYMENT_NAME"] || "<embedding model>";
537537
const scope = "user_123";
538538
const memoryStore = await project.beta.memoryStores.create(
539539
memoryStoreName,

sdk/ai/ai-projects/sample.env

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
AZURE_AI_PROJECT_ENDPOINT="<project connection string from Microsoft Foundry>"
2-
AZURE_AI_CHAT_MODEL_DEPLOYMENT_NAME="<memory chat model deployment name>"
3-
AZURE_AI_EMBEDDING_MODEL_DEPLOYMENT_NAME="<memory embedding model deployment name>"
4-
MODEL_DEPLOYMENT_NAME="<model deployment name>"
1+
FOUNDRY_PROJECT_ENDPOINT="<project connection string from Microsoft Foundry>"
2+
FOUNDRY_PROJECT_DEFAULT_ENDPOINT="<default project connection string from Microsoft Foundry>"
3+
FOUNDRY_MODEL_NAME="<model deployment name>"
4+
FOUNDRY_AGENT_NAME="<agent name>"
55
MODEL_API_KEY="<model api key>"
66
MODEL_ENDPOINT="<model endpoint url>"
77
MODEL_PUBLISHER="<model publisher name>"

sdk/ai/ai-projects/samples-dev/agents/agentBasic.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ import { DefaultAzureCredential } from "@azure/identity";
1515
import { AIProjectClient } from "@azure/ai-projects";
1616
import "dotenv/config";
1717

18-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint>";
19-
const deploymentName = process.env["MODEL_DEPLOYMENT_NAME"] || "<model deployment name>";
18+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint>";
19+
const deploymentName = process.env["FOUNDRY_MODEL_NAME"] || "<model deployment name>";
2020

2121
export async function main(): Promise<void> {
2222
// Create AI Project client

sdk/ai/ai-projects/samples-dev/agents/agentBasicWithDefaultProject.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ import { DefaultAzureCredential } from "@azure/identity";
1515
import { AIProjectClient } from "@azure/ai-projects";
1616
import "dotenv/config";
1717

18-
const projectEndpoint = process.env["AZURE_AI_PROJECT_DEFAULT_ENDPOINT"] || "<project endpoint>";
19-
const deploymentName = process.env["MODEL_DEPLOYMENT_NAME"] || "<model deployment name>";
18+
const projectEndpoint = process.env["FOUNDRY_PROJECT_DEFAULT_ENDPOINT"] || "<project endpoint>";
19+
const deploymentName = process.env["FOUNDRY_MODEL_NAME"] || "<model deployment name>";
2020

2121
export async function main(): Promise<void> {
2222
// Create AI Project client

sdk/ai/ai-projects/samples-dev/agents/agentCodeInterpreter.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ import { DefaultAzureCredential } from "@azure/identity";
1515
import { AIProjectClient } from "@azure/ai-projects";
1616
import "dotenv/config";
1717

18-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint>";
19-
const deploymentName = process.env["MODEL_DEPLOYMENT_NAME"] || "<model deployment name>";
18+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint>";
19+
const deploymentName = process.env["FOUNDRY_MODEL_NAME"] || "<model deployment name>";
2020

2121
export async function main(): Promise<void> {
2222
// Create AI Project client

sdk/ai/ai-projects/samples-dev/agents/agentConversationCurd.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import { AIProjectClient } from "@azure/ai-projects";
1414

1515
import "dotenv/config";
1616

17-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint>";
17+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint>";
1818

1919
async function main(): Promise<void> {
2020
const project = new AIProjectClient(projectEndpoint, new DefaultAzureCredential());

sdk/ai/ai-projects/samples-dev/agents/agentCurd.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ import { DefaultAzureCredential } from "@azure/identity";
1212
import { AIProjectClient } from "@azure/ai-projects";
1313
import "dotenv/config";
1414

15-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint>";
16-
const deploymentName = process.env["MODEL_DEPLOYMENT_NAME"] || "<model deployment name>";
15+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint>";
16+
const deploymentName = process.env["FOUNDRY_MODEL_NAME"] || "<model deployment name>";
1717

1818
async function main(): Promise<void> {
1919
const credential = new DefaultAzureCredential();

sdk/ai/ai-projects/samples-dev/agents/agentFunctionTool.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ import { DefaultAzureCredential } from "@azure/identity";
1616
import { AIProjectClient } from "@azure/ai-projects";
1717
import "dotenv/config";
1818

19-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint>";
20-
const deploymentName = process.env["MODEL_DEPLOYMENT_NAME"] || "<model deployment name>";
19+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint>";
20+
const deploymentName = process.env["FOUNDRY_MODEL_NAME"] || "<model deployment name>";
2121

2222
/**
2323
* Define a function tool for the model to use

sdk/ai/ai-projects/samples-dev/agents/agentStreamEvents.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ import { DefaultAzureCredential } from "@azure/identity";
1414
import { AIProjectClient } from "@azure/ai-projects";
1515
import "dotenv/config";
1616

17-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint>";
18-
const deploymentName = process.env["MODEL_DEPLOYMENT_NAME"] || "<model deployment name>";
17+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint>";
18+
const deploymentName = process.env["FOUNDRY_MODEL_NAME"] || "<model deployment name>";
1919

2020
export async function main(): Promise<void> {
2121
// Create AI Project client

sdk/ai/ai-projects/samples-dev/agents/agentStructureOutput.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ import { DefaultAzureCredential } from "@azure/identity";
2121
import { AIProjectClient } from "@azure/ai-projects";
2222
import "dotenv/config";
2323

24-
const projectEndpoint = process.env["AZURE_AI_PROJECT_ENDPOINT"] || "<project endpoint>";
25-
const deploymentName = process.env["MODEL_DEPLOYMENT_NAME"] || "<model deployment name>";
24+
const projectEndpoint = process.env["FOUNDRY_PROJECT_ENDPOINT"] || "<project endpoint>";
25+
const deploymentName = process.env["FOUNDRY_MODEL_NAME"] || "<model deployment name>";
2626

2727
export async function main(): Promise<void> {
2828
// Create AI Project client

0 commit comments

Comments
 (0)