Skip to content

Commit 76b98cf

Browse files
committed
Switch to gpt-41-mini with evaluations
1 parent 6be648a commit 76b98cf

19 files changed

+383
-93
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ This template, the application code and configuration it contains, has been buil
5151

5252
[📺 Watch a video overview of the app.](https://youtu.be/3acB0OWmLvM)
5353

54-
This sample demonstrates a few approaches for creating ChatGPT-like experiences over your own data using the Retrieval Augmented Generation pattern. It uses Azure OpenAI Service to access a GPT model (gpt-4o-mini), and Azure AI Search for data indexing and retrieval.
54+
This sample demonstrates a few approaches for creating ChatGPT-like experiences over your own data using the Retrieval Augmented Generation pattern. It uses Azure OpenAI Service to access a GPT model (gpt-4.1-mini), and Azure AI Search for data indexing and retrieval.
5555

5656
The repo includes sample data so it's ready to try end to end. In this sample application we use a fictitious company called Contoso Electronics, and the experience allows its employees to ask questions about the benefits, internal policies, as well as job descriptions and roles.
5757

docs/agentic_retrieval.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ See the agentic retrieval documentation.
2424

2525
2. **(Optional) Set the agentic retrieval model**
2626

27-
You can configure which model agentic retrieval uses. By default, gpt-4o-mini is used
27+
You can configure which model agentic retrieval uses. By default, gpt-4o-mini is used.
2828

2929
For gpt-4o:
3030

docs/deploy_existing.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ You should set these values before running `azd up`. Once you've set them, retur
2626
1. Run `azd env set AZURE_OPENAI_SERVICE {Name of existing OpenAI service}`
2727
1. Run `azd env set AZURE_OPENAI_RESOURCE_GROUP {Name of existing resource group that OpenAI service is provisioned to}`
2828
1. Run `azd env set AZURE_OPENAI_LOCATION {Location of existing OpenAI service}`
29-
1. Run `azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT {Name of existing chat deployment}`. Only needed if your chat deployment name is not the default 'gpt-4o-mini'.
30-
1. Run `azd env set AZURE_OPENAI_CHATGPT_MODEL {Model name of existing chat deployment}`. Only needed if your chat model is not the default 'gpt-4o-mini'.
29+
1. Run `azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT {Name of existing chat deployment}`. Only needed if your chat deployment name is not the default 'gpt-4.1-mini'.
30+
1. Run `azd env set AZURE_OPENAI_CHATGPT_MODEL {Model name of existing chat deployment}`. Only needed if your chat model is not the default 'gpt-4.1-mini'.
3131
1. Run `azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_VERSION {Version string for existing chat deployment}`. Only needed if your chat deployment model version is not the default '2024-07-18'. You definitely need to change this if you changed the model.
3232
1. Run `azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_SKU {Name of SKU for existing chat deployment}`. Only needed if your chat deployment SKU is not the default 'Standard', like if it is 'GlobalStandard' instead.
3333
1. Run `azd env set AZURE_OPENAI_EMB_DEPLOYMENT {Name of existing embedding deployment}`. Only needed if your embeddings deployment is not the default 'embedding'.

docs/deploy_features.md

Lines changed: 21 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,24 +40,30 @@ As of late March 2025, the default chat completion model is `gpt-4o-mini`. If yo
4040

4141
1. To set the GPT model to a different [available model](https://learn.microsoft.com/azure/ai-services/openai/concepts/models), run this command with the appropriate model name.
4242

43-
For GPT-4:
43+
For gpt-4.1-mini:
4444

4545
```bash
46-
azd env set AZURE_OPENAI_CHATGPT_MODEL gpt-4
46+
azd env set AZURE_OPENAI_CHATGPT_MODEL gpt-4.1-mini
4747
```
4848

49-
For GPT-4o:
49+
For gpt-4o:
5050

5151
```bash
5252
azd env set AZURE_OPENAI_CHATGPT_MODEL gpt-4o
5353
```
5454

55-
For GPT-4o mini:
55+
For gpt-4o mini:
5656

5757
```bash
5858
azd env set AZURE_OPENAI_CHATGPT_MODEL gpt-4o-mini
5959
```
6060

61+
For gpt-4:
62+
63+
```bash
64+
azd env set AZURE_OPENAI_CHATGPT_MODEL gpt-4
65+
```
66+
6167
For gpt-3.5-turbo:
6268

6369
```bash
@@ -66,24 +72,30 @@ As of late March 2025, the default chat completion model is `gpt-4o-mini`. If yo
6672

6773
1. To set the Azure OpenAI model version from the [available versions](https://learn.microsoft.com/azure/ai-services/openai/concepts/models), run this command with the appropriate version string.
6874

69-
For GPT-4:
75+
For gpt-4.1-mini:
7076

71-
```bash
72-
azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_VERSION turbo-2024-04-09
77+
```
78+
azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_VERSION 2025-04-14
7379
```
7480

75-
For GPT-4o:
81+
For gpt-4o:
7682

7783
```bash
7884
azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_VERSION 2024-05-13
7985
```
8086

81-
For GPT-4o mini:
87+
For gpt-4o mini:
8288

8389
```bash
8490
azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_VERSION 2024-07-18
8591
```
8692

93+
For gpt-4:
94+
95+
```bash
96+
azd env set AZURE_OPENAI_CHATGPT_DEPLOYMENT_VERSION turbo-2024-04-09
97+
```
98+
8799
For gpt-3.5-turbo:
88100

89101
```bash

docs/gpt4v.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ For more details on how this feature works, read [this blog post](https://techco
2323
* The ability to deploy a gpt-4o model in the [supported regions](https://learn.microsoft.com/azure/ai-services/openai/concepts/models#standard-deployment-model-availability). If you're not sure, try to create a gpt-4o deployment from your Azure OpenAI deployments page.
2424
* Ensure that you can deploy the Azure OpenAI resource group in [a region and deployment SKU where all required components are available](https://learn.microsoft.com/azure/cognitive-services/openai/concepts/models#model-summary-table-and-region-availability):
2525
* Azure OpenAI models
26-
* gpt-4o-mini
26+
* gpt-4.1-mini
2727
* text-embedding-3-large
2828
* gpt-4o (for vision/evaluation features)
2929
* [Azure AI Vision](https://learn.microsoft.com/azure/ai-services/computer-vision/)

evals/results/baseline/README.md

Lines changed: 0 additions & 8 deletions
This file was deleted.

evals/results/baseline/eval_results.jsonl

Lines changed: 50 additions & 50 deletions
Large diffs are not rendered by default.

evals/results/baseline/evaluate_parameters.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"evaluation_gpt_model": "gpt-4o",
3-
"evaluation_timestamp": 1746818372,
3+
"evaluation_timestamp": 1748932460,
44
"testdata_path": "/Users/pamelafox/azure-search-openai-demo/evals/ground_truth.jsonl",
55
"target_url": "http://localhost:50505/chat",
66
"target_parameters": {

evals/results/baseline/summary.json

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,31 @@
11
{
22
"gpt_groundedness": {
3-
"pass_count": 43,
4-
"pass_rate": 0.86,
5-
"mean_rating": 4.5
3+
"pass_count": 47,
4+
"pass_rate": 0.94,
5+
"mean_rating": 4.76
66
},
77
"gpt_relevance": {
8-
"pass_count": 42,
9-
"pass_rate": 0.84,
10-
"mean_rating": 4.22
8+
"pass_count": 47,
9+
"pass_rate": 0.94,
10+
"mean_rating": 4.42
1111
},
1212
"answer_length": {
13-
"mean": 919.26,
14-
"max": 1647,
15-
"min": 193
13+
"mean": 829.06,
14+
"max": 1380,
15+
"min": 275
1616
},
1717
"latency": {
18-
"mean": 4.46,
19-
"max": 15.129978,
20-
"min": 2.465542
18+
"mean": 2.89,
19+
"max": 5.183753,
20+
"min": -1.0
2121
},
2222
"citations_matched": {
23-
"total": 24,
24-
"rate": 0.49
23+
"total": 26,
24+
"rate": 0.52
2525
},
2626
"any_citation": {
27-
"total": 50,
28-
"rate": 1.0
27+
"total": 49,
28+
"rate": 0.98
2929
},
3030
"num_questions": {
3131
"total": 50
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
"testdata_path": "ground_truth.jsonl",
3+
"results_dir": "results/experiment<TIMESTAMP>",
4+
"requested_metrics": ["gpt_groundedness", "gpt_relevance", "answer_length", "latency", "citations_matched", "any_citation"],
5+
"target_url": "http://localhost:50505/chat",
6+
"target_parameters": {
7+
"overrides": {
8+
"top": 3,
9+
"temperature": 0.3,
10+
"minimum_reranker_score": 0,
11+
"minimum_search_score": 0,
12+
"retrieval_mode": "hybrid",
13+
"semantic_ranker": true,
14+
"semantic_captions": false,
15+
"suggest_followup_questions": false,
16+
"use_oid_security_filter": false,
17+
"use_groups_security_filter": false,
18+
"vector_fields": [
19+
"embedding"
20+
],
21+
"use_gpt4v": false,
22+
"gpt4v_input": "textAndImages",
23+
"seed": 1
24+
}
25+
},
26+
"target_response_answer_jmespath": "message.content",
27+
"target_response_context_jmespath": "context.data_points.text"
28+
}

0 commit comments

Comments
 (0)