You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add low cost deployment process and update Azure AI Document Intelligence references (#364)
## Purpose
This pull request updates the references to Azure Form Recognizer to
Azure AI Document Intelligence.
It also includes changes to the deployment process to support low-cost
deployment using services with free tiers.
The documentation has been updated to provide a step-by-step guide for
deploying with minimal costs.
Additionally, a video link has been added to showcase the low-cost
deployment process.
## Does this introduce a breaking change?
<!-- Mark one with an "x". -->
```
[ ] Yes
[X] No
```
## Pull Request Type
What kind of change does this Pull Request introduce?
<!-- Please check the one that applies to this PR using "x". -->
```
[ ] Bugfix
[X] Feature
[ ] Code style update (formatting, local variables)
[X] Refactoring (no functional changes, no api changes)
[X] Documentation content changes
[ ] Other... Please describe:
```
## How to Test
* Get the code
```
git clone [repo-address]
cd [repo-name]
```
Follow the low-cost deploy document instructions.
Copy file name to clipboardExpand all lines: README.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -97,7 +97,7 @@ In order to deploy and run this example, you'll need
97
97
-**Azure account permissions** - Your Azure Account must have `Microsoft.Authorization/roleAssignments/write` permissions, such as [User Access Administrator](https://learn.microsoft.com/azure/role-based-access-control/built-in-roles#user-access-administrator) or [Owner](https://learn.microsoft.com/azure/role-based-access-control/built-in-roles#owner).
98
98
99
99
> [!WARNING]<br>
100
-
> By default this sample will create an Azure Container App, and Azure AI Search resource that have a monthly cost, as well as Form Recognizer resource that has cost per document page. You can switch them to free versions of each of them if you want to avoid this cost by changing the parameters file under the infra folder (though there are some limits to consider; for example, you can have up to 1 free Azure AI Search resource per subscription, and the free Form Recognizer resource only analyzes the first 2 pages of each document.)
100
+
> By default this sample will create an Azure Container App, and Azure AI Search resource that have a monthly cost, as well as Azure AI Document Intelligence resource that has cost per document page. You can switch them to free versions of each of them if you want to avoid this cost by changing the parameters file under the infra folder (though there are some limits to consider; for example, you can have up to 1 free Azure AI Search resource per subscription, and the free Azure AI Document Intelligence resource only analyzes the first 2 pages of each document.)
101
101
102
102
### Project setup
103
103
@@ -358,11 +358,13 @@ Pricing varies per region and usage, so it isn't possible to predict exact costs
To reduce costs, you can switch to free SKUs for various services, but those SKUs have limitations. See this [guide on deploying with minimal costs](./docs/deploy_lowcost.md) for more details.
367
+
366
368
## Resources
367
369
368
370
-[Revolutionize your Enterprise Data with ChatGPT: Next-gen Apps w/ Azure OpenAI and Azure AI Search](https://aka.ms/entgptsearchblog)
new(name:"--formrecognizerendpoint",description:"Optional. The Azure Form Recognizer service endpoint which will be used to extract text, tables and layout from the documents (must exist already)");
42
+
new(name:"--formrecognizerendpoint",description:"Optional. The Azure AI Document Intelligence service endpoint which will be used to extract text, tables and layout from the documents (must exist already)");
new(name:"--computervisionendpoint",description:"Optional. The Azure Computer Vision service endpoint which will be used to vectorize image and query");
This AI RAG chat application is designed to be easily deployed using the Azure Developer CLI, which provisions the infrastructure according to the Bicep files in the `infra` folder. Those files describe each of the Azure resources needed, and configures their SKU (pricing tier) and other parameters. Many Azure services offer a free tier, but the infrastructure files in this project do *not* default to the free tier as there are often limitations in that tier.
4
+
5
+
However, if your goal is to minimize costs while prototyping your application, follow the steps below *before* running `azd up`. Once you've gone through these steps, return to the [deployment steps](../README.md#deployment).
6
+
7
+
[📺 Live stream: Deploying from a free account](https://youtu.be/V1ZLzXU4iiw)
8
+
9
+
1. Log in to your Azure account using the Azure Developer CLI:
10
+
11
+
```shell
12
+
azd auth login
13
+
```
14
+
15
+
1. Create a new azd environment for the free resource group:
16
+
17
+
```shell
18
+
azd env new
19
+
```
20
+
21
+
Enter a name that will be used for the resource group.
22
+
This will create a new folder in the `.azure` folder, and set it as the active environment for any calls to `azd` going forward.
23
+
24
+
1. Use the free tier of **Azure AI Document Intelligence** (previously known as [Form Recognizer](https://learn.microsoft.com/en-us/azure/ai-services/document-intelligence/overview?view=doc-intel-4.0.0)):
25
+
26
+
```shell
27
+
azd env set AZURE_FORMRECOGNIZER_SERVICE_SKU F0
28
+
```
29
+
30
+
1. Use the free tier of **Azure AI Search**:
31
+
32
+
```shell
33
+
azd env set AZURE_SEARCH_SERVICE_SKU free
34
+
azd env set AZURE_SEARCH_SEMANTIC_RANKER disabled
35
+
```
36
+
37
+
Limitations:
38
+
1. You are only allowed one free search service across all regions.
39
+
If you have one already, either delete that service or follow instructions to
40
+
reuse your [existing search service](../README.md#use-existing-resources).
41
+
2. The free tier does not support semantic ranker. Note that will generally result in [decreased search relevance](https://techcommunity.microsoft.com/t5/ai-azure-ai-services-blog/azure-ai-search-outperforming-vector-search-with-hybrid/ba-p/3929167).
42
+
43
+
1. Turn off **Azure Monitor** (Application Insights):
44
+
45
+
```shell
46
+
azd env set AZURE_USE_APPLICATION_INSIGHTS false
47
+
```
48
+
49
+
Application Insights is quite inexpensive already, so turning this off may not be worth the costs saved, but it is an option for those who want to minimize costs.
50
+
51
+
1. (Optional) Use **OpenAI.com** instead of Azure OpenAI.
52
+
53
+
You can create a free account in OpenAI and [request a key to use OpenAI models](https://platform.openai.com/docs/quickstart/create-and-export-an-api-key). Once you have this, you can disable the use of Azure OpenAI Services, and use OpenAI APIs.
54
+
55
+
```shell
56
+
azd env set USE_AOAI false
57
+
azd env set USE_VISION false
58
+
azd env set OPENAI_CHATGPT_DEPLOYMENT gpt-4o-mini
59
+
azd env set OPENAI_API_KEY <your openai.com key goes here>
60
+
```
61
+
62
+
***Note:** Both Azure OpenAI and openai.com OpenAI accounts will incur costs, based on tokens used, but the costs are fairly low for the amount of sample data (less than $10).*
63
+
64
+
1. Once you've made the desired customizations, follow the steps in the README [to run `azd up`](../README.md#deploying-from-scratch). We recommend using "eastus" as the region, for availability reasons.
0 commit comments