Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove remnants of planners in scripts #841

Merged
merged 1 commit into from
Mar 6, 2024
Merged
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
2 changes: 0 additions & 2 deletions scripts/.env
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@

# Default values
ENV_COMPLETION_MODEL_OPEN_AI="gpt-3.5-turbo"
ENV_PLANNER_MODEL_OPEN_AI="gpt-3.5-turbo"
ENV_COMPLETION_MODEL_AZURE_OPEN_AI="gpt-35-turbo"
ENV_PLANNER_MODEL_AZURE_OPEN_AI="gpt-35-turbo"
ENV_EMBEDDING_MODEL="text-embedding-ada-002"
ENV_ASPNETCORE="Development"
ENV_INSTANCE="https://login.microsoftonline.com"
Expand Down
19 changes: 3 additions & 16 deletions scripts/Configure.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Configure user secrets, appsettings.Development.json, and webapp/.env for Chat Copilot.

.PARAMETER AIService
The service type used: OpenAI or Azure OpenAI.
The service type used: OpenAI or AzureOpenAI.

.PARAMETER APIKey
The API key for the AI service.
Expand All @@ -17,9 +17,6 @@ The chat completion model to use (e.g., gpt-3.5-turbo or gpt-4).
.PARAMETER EmbeddingModel
The embedding model to use (e.g., text-embedding-ada-002).

.PARAMETER PlannerModel
The chat completion model to use for planning (e.g., gpt-3.5-turbo or gpt-4).

.PARAMETER FrontendClientId
The client (application) ID associated with your frontend's AAD app registration.

Expand Down Expand Up @@ -51,9 +48,6 @@ param(
[Parameter(Mandatory = $false)]
[string]$EmbeddingModel,

[Parameter(Mandatory = $false)]
[string]$PlannerModel,

[Parameter(Mandatory = $false)]
[string] $FrontendClientId,

Expand All @@ -74,21 +68,17 @@ $varScriptFilePath = Join-Path "$PSScriptRoot" 'Variables.ps1'
# Set remaining values from Variables.ps1
if ($AIService -eq $varOpenAI) {
if (!$CompletionModel) {
Write-Host "No completion model provided - Defaulting to $varCompletionModelOpenAI"
$CompletionModel = $varCompletionModelOpenAI
}
if (!$PlannerModel) {
$PlannerModel = $varPlannerModelOpenAI
}

# TO DO: Validate model values if set by command line.
}
elseif ($AIService -eq $varAzureOpenAI) {
if (!$CompletionModel) {
Write-Host "No completion model provided - Defaulting to $varCompletionModelAzureOpenAI"
$CompletionModel = $varCompletionModelAzureOpenAI
}
if (!$PlannerModel) {
$PlannerModel = $varPlannerModelAzureOpenAI
}

# TO DO: Validate model values if set by command line.

Expand Down Expand Up @@ -177,9 +167,6 @@ $appsettingsOverrides = @{
Scopes = $varScopes
}
};
Planner = @{
Model = $PlannerModel
};
KernelMemory = @{
TextGeneratorType = $AIService;
DataIngestion = @{
Expand Down
2 changes: 0 additions & 2 deletions scripts/Variables.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@

# Default values
$varCompletionModelOpenAI = "gpt-3.5-turbo"
$varPlannerModelOpenAI = "gpt-3.5-turbo"
$varCompletionModelAzureOpenAI = "gpt-35-turbo"
$varPlannerModelAzureOpenAI = "gpt-35-turbo"
$varEmbeddingModel = "text-embedding-ada-002"
$varASPNetCore = "Development"
$varInstance = "https://login.microsoftonline.com"
Expand Down
14 changes: 0 additions & 14 deletions scripts/configure.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@ while [[ $# -gt 0 ]]; do
shift
shift
;;
--plannermodel)
PLANNER_MODEL="$2"
shift
shift
;;
-fc | --frontend-clientid)
FRONTEND_CLIENT_ID="$2"
shift
Expand Down Expand Up @@ -111,17 +106,11 @@ if [ "$AI_SERVICE" = "$ENV_OPEN_AI" ]; then
if [ -z "$COMPLETION_MODEL" ]; then
COMPLETION_MODEL="$ENV_COMPLETION_MODEL_OPEN_AI"
fi
if [ -z "$PLANNER_MODEL" ]; then
PLANNER_MODEL="$ENV_PLANNER_MODEL_OPEN_AI"
fi
# TO DO: Validate model values if set by command line.
else # elif [ "$AI_SERVICE" = "$ENV_AZURE_OPEN_AI" ]; then
if [ -z "$COMPLETION_MODEL" ]; then
COMPLETION_MODEL="$ENV_COMPLETION_MODEL_AZURE_OPEN_AI"
fi
if [ -z "$PLANNER_MODEL" ]; then
PLANNER_MODEL="$ENV_PLANNER_MODEL_AZURE_OPEN_AI"
fi
# TO DO: Validate model values if set by command line.
fi

Expand Down Expand Up @@ -194,9 +183,6 @@ APPSETTINGS_OVERRIDES="{
\"Scopes\": \"${ENV_SCOPES}\"
}
},
\"Planner\": {
\"Model\": \"${PLANNER_MODEL}\"
},
\"KernelMemory\": {
\"TextGeneratorType\": \"${AI_SERVICE}\",
\"DataIngestion\": {
Expand Down