Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions reference_architectures/foundry_basic/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -219,14 +219,15 @@ For issues and questions:

## Inputs

| Name | Description | Type | Default | Required |
|-------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------|-------------------|:--------:|
| base\_name | Base name used as suffix in the naming module. | `string` | `"basic"` | no |
| enable\_telemetry | This variable controls whether or not telemetry is enabled for the module.<br/>For more information see <https://aka.ms/avm/telemetryinfo>.<br/>If it is set to false, then no telemetry will be collected. | `bool` | `true` | no |
| location | Azure region where the resource should be deployed. | `string` | `"swedencentral"` | no |
| resource\_group\_resource\_id | The resource group resource id where the module resources will be deployed. If not provided, a new resource group will be created. | `string` | `null` | no |
| sku | The SKU for the AI Foundry resource. The default is 'S0'. | `string` | `"S0"` | no |
| tags | (Optional) Tags to be applied to all resources. | `map(string)` | `null` | no |
| Name | Description | Type | Default | Required |
|-------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:--------:|
| base\_name | Base name used as suffix in the naming module. | `string` | `"basic"` | no |
| enable\_telemetry | This variable controls whether or not telemetry is enabled for the module.<br/>For more information see <https://aka.ms/avm/telemetryinfo>.<br/>If it is set to false, then no telemetry will be collected. | `bool` | `true` | no |
| location | Azure region where the resource should be deployed. | `string` | `"swedencentral"` | no |
| model\_deployments | The list of model deployments to create in AI Foundry. | <pre>list(object({<br/> name = string<br/> version = string<br/> format = string<br/> sku = optional(object({<br/> name = string<br/> capacity = number<br/> }), {<br/> name = "GlobalStandard"<br/> capacity = 50<br/> })<br/> }))</pre> | <pre>[<br/> {<br/> "format": "OpenAI",<br/> "name": "gpt-5-chat",<br/> "version": "2025-10-03"<br/> },<br/> {<br/> "format": "OpenAI",<br/> "name": "gpt-5-nano",<br/> "version": "2025-08-07"<br/> },<br/> {<br/> "format": "OpenAI",<br/> "name": "text-embedding-3-large",<br/> "version": "1"<br/> },<br/> {<br/> "format": "OpenAI",<br/> "name": "gpt-4o-mini",<br/> "version": "2024-07-18"<br/> }<br/>]</pre> | no |
| resource\_group\_resource\_id | The resource group resource id where the module resources will be deployed. If not provided, a new resource group will be created. | `string` | `null` | no |
| sku | The SKU for the AI Foundry resource. The default is 'S0'. | `string` | `"S0"` | no |
| tags | (Optional) Tags to be applied to all resources. | `map(string)` | `null` | no |

## Outputs

Expand Down
7 changes: 1 addition & 6 deletions reference_architectures/foundry_basic/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,7 @@ module "ai_foundry" {

# Model deployments to make available within Foundry
# Add/remove models as needed for your workload requirements
model_deployments = [
module.common_models.gpt_5_2_chat,
module.common_models.gpt_5_nano,
module.common_models.text_embedding_3_large,
module.common_models.gpt_4o_mini
]
model_deployments = var.model_deployments

Comment on lines 58 to 61
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With model_deployments = var.model_deployments, the common_models module in this stack is now unused (it’s only declared, never referenced). Suggest either removing the module "common_models" block (and letting terraform-docs drop it from the README), or re-introducing it via a local.default_model_deployments fallback so model versions stay centrally maintained while still allowing overrides.

Copilot uses AI. Check for mistakes.
application_insights = module.application_insights

Expand Down
38 changes: 38 additions & 0 deletions reference_architectures/foundry_basic/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,44 @@ variable "sku" {
default = "S0"
}

variable "model_deployments" {
description = "The list of model deployments to create in AI Foundry."
type = list(object({
name = string
version = string
format = string
sku = optional(object({
name = string
capacity = number
}), {
Comment on lines +33 to +40
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This new variable block doesn’t appear to be terraform fmt-ed (e.g., type = isn’t aligned like other attributes in the file). Please run terraform fmt (or update spacing/order to match surrounding conventions) before merging to avoid formatting churn across these duplicated blocks.

Suggested change
type = list(object({
name = string
version = string
format = string
sku = optional(object({
name = string
capacity = number
}), {
type = list(object({
name = string
version = string
format = string
sku = optional(object({
name = string
capacity = number
}), {

Copilot uses AI. Check for mistakes.
name = "GlobalStandard"
capacity = 50
})
}))
Comment on lines +31 to +44
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding validation to model_deployments to catch common misconfiguration early (e.g., unique deployment names, non-empty strings, and sku.capacity > 0). Repo Terraform standards call out adding validation in reference architectures when constraints are known (.github/guidance/terraform/terraform-standards.md around the reference-architecture conventions).

Copilot uses AI. Check for mistakes.
default = [
{
format = "OpenAI"
name = "gpt-5-chat"
version = "2025-10-03"
},
Comment on lines +45 to +50
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default model list here changes behavior vs the previous hard-coded deployments: it now deploys gpt-5-chat (2025-10-03) instead of the previously configured gpt-5.2-chat (2025-12-11). If the goal is only to make deployments configurable (without changing defaults), update the default entry to match the prior model/version (and apply consistently across the other reference architectures updated in this PR).

Copilot uses AI. Check for mistakes.
{
format = "OpenAI"
name = "gpt-5-nano"
version = "2025-08-07"
},
{
format = "OpenAI"
name = "text-embedding-3-large"
version = "1"
},
{
format = "OpenAI"
name = "gpt-4o-mini"
version = "2024-07-18"
}
]
}

variable "enable_telemetry" {
type = bool
default = true
Expand Down
Loading
Loading