Skip to content
Open
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
18 changes: 14 additions & 4 deletions .github/workflows/azd_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,14 @@ on:
- provision
- deploy
- destroy
run_evals:
description: 'Run evals'
required: false
default: 'false'
type: choice
options:
- true
- false
push:
# Run when commits are pushed to mainline branch (main or master)
# Set this to the mainline branch you are using
Expand All @@ -37,17 +45,19 @@ env:
AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
AZURE_ENV_NAME: ${{ vars.AZURE_ENV_NAME }}
AZURE_LOCATION: ${{ vars.AZURE_LOCATION }}
RUN_EVALS: false
RUN_EVALS: ${{ github.event.inputs.run_evals || 'false' }}

jobs:
provision:
environment: prod
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install azd
uses: Azure/setup-azd@ae0f8b5482eeac61e940f447327d84c73beb8b1e
# Disabling due to embedded sudo cmdlet.
# Relying on the self-hosted runner to have azd installed
# - name: Install azd
# uses: Azure/setup-azd@ae0f8b5482eeac61e940f447327d84c73beb8b1e
- name: Azure CLI Login
# Uses azure/login@v2.2
uses: azure/login@a65d910e8af852a8061c627c456678983e180302
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main_staging_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ on:

jobs:
quality-checks:
runs-on: ubuntu-latest
runs-on: self-hosted

steps:
- name: Checkout Code 🛎️
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
🚀 **Welcome! Ready to streamline your Prior Authorization process?** Click below to get started with your deployment and unlock the full potential of AutoAuth.

<div align="center">
<a href="https://pablosalvador10.github.io/gbb-ai-hls-factory-prior-auth/azd_deployment.html">
<a href="https://azure-samples.github.io/autoauth-solution-accelerator/azd_deployment.html">
<img src="https://img.shields.io/badge/🚀%20Click Me-Deploy%20To%20Azure-blue?style=for-the-badge&logo=github&logoWidth=20" alt="📚 Wiki" height="32">
</a>
</a>
Expand All @@ -21,7 +21,7 @@
- [Overview](#-overview)
- [Introducing AutoAuth](#-introducing-autoauth)
- [Quick Start](#-quick-start)
- [End-to-End Deployment Using AZD](https://pablosalvador10.github.io/gbb-ai-hls-factory-prior-auth/azd_deployment.html)
- [End-to-End Deployment Using AZD](https://azure-samples.github.io/autoauth-solution-accelerator/azd_deployment.html)
- [PriorAuth SDK](#priorauth-sdk)
- [Evaluations Framework](#evaluations)
- [What's Next?](#-whats-next)
Expand Down Expand Up @@ -61,7 +61,7 @@ This repository aims to **streamline and automate** the PA process using Azure A
</p>
</div>

**Note:** For comprehensive details, including technical architecture, customization steps, references, and additional documentation, please visit our **[GitHub Pages](https://pablosalvador10.github.io/gbb-ai-hls-factory-prior-auth)**.
**Note:** For comprehensive details, including technical architecture, customization steps, references, and additional documentation, please visit our **[GitHub Pages](https://azure-samples.github.io/autoauth-solution-accelerator)**.

<div align="center">
<a href="https://player.vimeo.com/video/1040993686?h=f9c8e5ffba">
Expand All @@ -78,7 +78,7 @@ This repository aims to **streamline and automate** the PA process using Azure A

> [!TIP]
> *Want to customize or learn more about configuration?*
> **[Read the detailed instructions on our GitHub Pages ➜](https://pablosalvador10.github.io/gbb-ai-hls-factory-prior-auth)**
> **[Read the detailed instructions on our GitHub Pages ➜](https://azure-samples.github.io/autoauth-solution-accelerator)**

More detailed documentation can be found in [docs/azd_deployment.md](docs/azd_deployment.md).

Expand Down Expand Up @@ -112,7 +112,7 @@ For those looking for greater flexibility, the AutoAuth SDK enables you to embed

With the AutoAuth SDK, you have the flexibility to automate end-to-end Prior Authorization workflows or select specific components to integrate into your system. Whether you require a full application or a microservice solution, AutoAuth provides the tools you need.

**Note:** Detailed information, technical architecture, customization steps, references, and further documentation are available on our **[GitHub Pages](https://pablosalvador10.github.io/gbb-ai-hls-factory-prior-auth)**.
**Note:** Detailed information, technical architecture, customization steps, references, and further documentation are available on our **[GitHub Pages](https://azure-samples.github.io/autoauth-solution-accelerator)**.

### Evaluations

Expand Down
1 change: 0 additions & 1 deletion infra/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,6 @@ AZURE_OPENAI_API_VERSION | string |
AZURE_OPENAI_EMBEDDING_DEPLOYMENT | string |
AZURE_OPENAI_CHAT_DEPLOYMENT_ID | string |
AZURE_OPENAI_CHAT_DEPLOYMENT_01 | string |
AZURE_OPENAI_API_VERSION_O1 | string |
AZURE_OPENAI_EMBEDDING_DIMENSIONS | string |
AZURE_SEARCH_SERVICE_NAME | string |
AZURE_SEARCH_INDEX_NAME | string |
Expand Down
4 changes: 0 additions & 4 deletions infra/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -15471,10 +15471,6 @@
"type": "string",
"value": "[if(contains(parameters('reasoningModel').name, 'o1'), parameters('reasoningModel').name, '')]"
},
"AZURE_OPENAI_API_VERSION_O1": {
"type": "string",
"value": "[if(contains(parameters('reasoningModel').name, 'o1'), parameters('reasoningModel').version, '')]"
},
"AZURE_OPENAI_EMBEDDING_DIMENSIONS": {
"type": "string",
"value": "[parameters('embeddingModelDimension')]"
Expand Down
1 change: 0 additions & 1 deletion infra/resources.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,6 @@ output AZURE_OPENAI_API_VERSION string = chatModel.version
output AZURE_OPENAI_EMBEDDING_DEPLOYMENT string = embeddingModel.name
output AZURE_OPENAI_CHAT_DEPLOYMENT_ID string = chatCompletionModels[0].name
output AZURE_OPENAI_CHAT_DEPLOYMENT_01 string = contains(reasoningModel.name, 'o1') ? reasoningModel.name : ''
output AZURE_OPENAI_API_VERSION_O1 string = contains(reasoningModel.name, 'o1') ? reasoningModel.version : ''
output AZURE_OPENAI_EMBEDDING_DIMENSIONS string = embeddingModelDimension
output AZURE_SEARCH_SERVICE_NAME string = searchService.outputs.searchServiceName
output AZURE_SEARCH_INDEX_NAME string = 'ai-policies-index'
Expand Down
4 changes: 0 additions & 4 deletions infra/resources.json
Original file line number Diff line number Diff line change
Expand Up @@ -15266,10 +15266,6 @@
"type": "string",
"value": "[if(contains(parameters('reasoningModel').name, 'o1'), parameters('reasoningModel').name, '')]"
},
"AZURE_OPENAI_API_VERSION_O1": {
"type": "string",
"value": "[if(contains(parameters('reasoningModel').name, 'o1'), parameters('reasoningModel').version, '')]"
},
"AZURE_OPENAI_EMBEDDING_DIMENSIONS": {
"type": "string",
"value": "[parameters('embeddingModelDimension')]"
Expand Down
8 changes: 2 additions & 6 deletions utils/azd/hooks/postdeploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -152,12 +152,8 @@ set_storage_shared_key_access() {
run_evaluations() {
# Ask user if they want to run evaluations (if not already set)
if [ -z "${RUN_EVALS:-}" ]; then
read -p "Would you like to run model evaluations through AI Foundry? (y/n): " response
if [[ ! "$response" =~ ^[Yy] ]]; then
log_info "Model evaluations will be skipped."
return 0
fi
log_info "Model evaluations will be run."
log_info "RUN_EVALS env flag currently not set. Model evaluations will be skipped."
return 0
else
log_info "RUN_EVALS flag is already set to: $RUN_EVALS"
if [[ "$RUN_EVALS" =~ ^[Ff][Aa][Ll][Ss][Ee]$ ]]; then
Expand Down
1 change: 0 additions & 1 deletion utils/azd/hooks/postprovision.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
Write-Output "
AZURE_OPENAI_ENDPOINT=$(azd env get-value AZURE_OPENAI_ENDPOINT)
AZURE_OPENAI_API_VERSION=$(azd env get-value AZURE_OPENAI_API_VERSION)
AZURE_OPENAI_API_VERSION_O1=$(azd env get-value AZURE_OPENAI_API_VERSION_O1)
AZURE_OPENAI_EMBEDDING_DEPLOYMENT=$(azd env get-value AZURE_OPENAI_EMBEDDING_DEPLOYMENT)
AZURE_OPENAI_CHAT_DEPLOYMENT_ID=$(azd env get-value AZURE_OPENAI_CHAT_DEPLOYMENT_ID)
AZURE_OPENAI_EMBEDDING_DIMENSIONS=$(azd env get-value AZURE_OPENAI_EMBEDDING_DIMENSIONS)
Expand Down
1 change: 0 additions & 1 deletion utils/azd/hooks/postprovision.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ echo "Generating .env file..."
echo "
AZURE_OPENAI_ENDPOINT=$(azd env get-value AZURE_OPENAI_ENDPOINT)
AZURE_OPENAI_API_VERSION=$(azd env get-value AZURE_OPENAI_API_VERSION)
AZURE_OPENAI_API_VERSION_O1=$(azd env get-value AZURE_OPENAI_API_VERSION_O1)
AZURE_OPENAI_EMBEDDING_DEPLOYMENT=$(azd env get-value AZURE_OPENAI_EMBEDDING_DEPLOYMENT)
AZURE_OPENAI_CHAT_DEPLOYMENT_ID=$(azd env get-value AZURE_OPENAI_CHAT_DEPLOYMENT_ID)
AZURE_OPENAI_EMBEDDING_DIMENSIONS=$(azd env get-value AZURE_OPENAI_EMBEDDING_DIMENSIONS)
Expand Down
26 changes: 26 additions & 0 deletions utils/devops/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
FROM ghcr.io/actions/actions-runner:2.304.0
# for latest release, see https://github.com/actions/runner/releases

USER root

# install curl and jq
RUN apt-get update && apt-get install -y curl jq && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

# Install Azure CLI
RUN curl -sL https://aka.ms/InstallAzureCLIDeb | bash

# Install Azure Developer CLI (azd)
RUN mkdir -p /tmp/azd && \
curl -fsSL https://aka.ms/install-azd.sh > /tmp/azd/install-azd.sh && \
chmod +x /tmp/azd/install-azd.sh && \
/tmp/azd/install-azd.sh && \
rm -rf /tmp/azd

COPY github-actions-runner/entrypoint.sh ./entrypoint.sh
RUN chmod +x ./entrypoint.sh

USER runner

ENTRYPOINT ["./entrypoint.sh"]
11 changes: 11 additions & 0 deletions utils/devops/github-actions-runner/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/sh -l

# Retrieve a short lived runner registration token using the PAT
REGISTRATION_TOKEN="$(curl -X POST -fsSL \
-H 'Accept: application/vnd.github.v3+json' \
-H "Authorization: Bearer $GITHUB_PAT" \
-H 'X-GitHub-Api-Version: 2022-11-28' \
"$REGISTRATION_TOKEN_API_URL" \
| jq -r '.token')"

./config.sh --url $GH_URL --token $REGISTRATION_TOKEN --unattended --ephemeral && ./run.sh
Loading