Skip to content

Commit ac3f87c

Browse files
Merge pull request #94 from Priyanka-Microsoft/update-quota-check-script
chore: update quota check script
2 parents 31f60ec + 33aadf2 commit ac3f87c

File tree

2 files changed

+13
-9
lines changed

2 files changed

+13
-9
lines changed

docs/quota_check.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ az login
1010

1111
## 📌 Default Models & Capacities:
1212
```
13-
gpt-4o:30, gpt-4o-mini:30, gpt-4:30, text-embedding-ada-002:80
13+
gpt-4o:150, gpt-4o-mini:150, gpt-4:150, text-embedding-3-small:100
1414
```
1515
## 📌 Default Regions:
1616
```
17-
eastus, uksouth, eastus2, northcentralus, swedencentral, westus, westus2, southcentralus, canadacentral
17+
eastus, uksouth, eastus2, northcentralus, swedencentral, westus, westus2, southcentralus, canadacentral, australiaeast, japaneast, norwayeast
1818
```
1919
## Usage Scenarios:
2020
- No parameters passed → Default models and capacities will be checked in default regions.
@@ -36,19 +36,23 @@ eastus, uksouth, eastus2, northcentralus, swedencentral, westus, westus2, southc
3636
```
3737
✔️ Check specific model(s) in default regions:
3838
```
39-
./quota_check.sh --models gpt-4o:30,text-embedding-ada-002:80
39+
./quota_check.sh --models gpt-4o:150,text-embedding-3-small:100
4040
```
4141
✔️ Check default models in specific region(s):
4242
```
4343
./quota_check.sh --regions eastus,westus
4444
```
4545
✔️ Passing Both models and regions:
4646
```
47-
./quota_check.sh --models gpt-4o:30 --regions eastus,westus2
47+
./quota_check.sh --models gpt-4o:150 --regions eastus,westus2
4848
```
4949
✔️ All parameters combined:
5050
```
51-
./quota_check.sh --models gpt-4:30,text-embedding-ada-002:80 --regions eastus,westus --verbose
51+
./quota_check.sh --models gpt-4:150,text-embedding-3-small:100 --regions eastus,westus --verbose
52+
```
53+
✔️ Multiple models with single region:
54+
```
55+
./quota_check.sh --models gpt-4:150,text-embedding-3-small:100 --regions eastus2 --verbose
5256
```
5357

5458
## **Sample Output**

scripts/quota_check.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ log_verbose() {
4747
}
4848

4949
# Default Models and Capacities (Comma-separated in "model:capacity" format)
50-
DEFAULT_MODEL_CAPACITY="gpt-4o:30,gpt-4o-mini:30,gpt-4:30,text-embedding-ada-002:80"
50+
DEFAULT_MODEL_CAPACITY="gpt-4o:150,gpt-4o-mini:150,gpt-4:150,text-embedding-3-small:100"
5151

5252
# Convert the comma-separated string into an array
5353
IFS=',' read -r -a MODEL_CAPACITY_PAIRS <<< "$DEFAULT_MODEL_CAPACITY"
@@ -93,7 +93,7 @@ az account set --subscription "$AZURE_SUBSCRIPTION_ID"
9393
echo "🎯 Active Subscription: $(az account show --query '[name, id]' --output tsv)"
9494

9595
# Default Regions to check (Comma-separated, now configurable)
96-
DEFAULT_REGIONS="eastus,uksouth,eastus2,northcentralus,swedencentral,westus,westus2,southcentralus,canadacentral"
96+
DEFAULT_REGIONS="eastus,uksouth,eastus2,australiaeast,norwayeast,japaneast,northcentralus,swedencentral,westus,westus2,southcentralus,canadacentral"
9797
IFS=',' read -r -a DEFAULT_REGION_ARRAY <<< "$DEFAULT_REGIONS"
9898

9999
# Read parameters (if any)
@@ -165,7 +165,7 @@ for REGION in "${REGIONS[@]}"; do
165165
FOUND=false
166166
INSUFFICIENT_QUOTA=false
167167

168-
if [ "$MODEL_NAME" = "text-embedding-ada-002" ]; then
168+
if [ "$MODEL_NAME" = "text-embedding-3-small" ]; then
169169
MODEL_TYPES=("openai.standard.$MODEL_NAME")
170170
else
171171
MODEL_TYPES=("openai.standard.$MODEL_NAME" "openai.globalstandard.$MODEL_NAME")
@@ -203,7 +203,7 @@ for REGION in "${REGIONS[@]}"; do
203203

204204
if [ "$AVAILABLE" -ge "$REQUIRED_CAPACITY" ]; then
205205
FOUND=true
206-
if [ "$MODEL_NAME" = "text-embedding-ada-002" ]; then
206+
if [ "$MODEL_NAME" = "text-embedding-3-small" ]; then
207207
TEXT_EMBEDDING_AVAILABLE=true
208208
fi
209209
AT_LEAST_ONE_MODEL_AVAILABLE=true

0 commit comments

Comments
 (0)