Skip to content

Commit

Permalink
Parameterise OpenAI model name and version (locals for now but should…
Browse files Browse the repository at this point in the history
… be vars)
  • Loading branch information
harryy94 committed Aug 19, 2024
1 parent 04376ac commit c5892e7
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions templates/workspace_services/openai/terraform/openai.tf
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,20 @@ resource "azurerm_cognitive_account" "openai" {
sku_name = "S0"
}

locals {
openai_model_name = "gpt-35-turbo"
openai_model_version = "0301"
}

resource "azurerm_cognitive_deployment" "openai" {
name = "openai-gpt-4-32k-0314"
name = "openai-${local.openai_model_name}-${local.openai_model_version}-${var.tre_id}-${local.short_workspace_id}"
cognitive_account_id = azurerm_cognitive_account.openai.id
model {
format = "OpenAI"
name = "gpt-4-32k"
version = "0314"
# name = "gpt-4-32k"
name = local.openai_model_name
# version = "0314"
version = local.openai_model_version
}

scale {
Expand Down

0 comments on commit c5892e7

Please sign in to comment.