-
Notifications
You must be signed in to change notification settings - Fork 161
feat: added fdp changes, updated to use ai agents instead of openai assistants #566
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
Conversation
…ing imports and formatting code blocks consistently across multiple files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR transitions the deployment to use Azure AI Foundry resources, refactors core database and chat services, updates tests and configuration paths, and adjusts documentation and scripts to align with the new framework.
- Replace legacy AI Hub and Cognitive Services with AI Foundry resources in Bicep templates
- Introduce a unified
sqldb_servicefor SQL connections and update related tests - Update deployment scripts and docs for new
aiFoundryandaiSearchparameters
Reviewed Changes
Copilot reviewed 34 out of 38 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| infra/deploy_ai_foundry.bicep | Define AI Foundry account and project resources |
| infra/deploy_app_service.bicep | Wire AI Foundry endpoints and identities into app |
| src/App/backend/services/sqldb_service.py | New SQL DB service with managed identity support |
| src/App/tests/test_app.py | Updated tests to use backend.common.config.config |
| docs/DeploymentGuide.md | Bumped API version and sample script parameters |
Comments suppressed due to low confidence (3)
infra/main.bicep:258
- Typo in output variable name:
FOUNDARYshould be spelledFOUNDRYto match the resource naming convention.
output AI_FOUNDARY_NAME string = aifoundry.outputs.aiFoundryName
src/App/backend/services/sqldb_service.py:35
- Consider adding unit tests for
get_connection(including successful token-based connect and fallback) and fordict_cursorto ensure full test coverage of this new service.
def get_connection():
infra/scripts/run_create_index_scripts.sh:74
- The variable
signed_user_idis used but never set in this script. You should retrieve the signed-in user ID (e.g., viaaz ad signed-in-user show --query id -o tsv) before referencing it.
role_assignment=$(MSYS_NO_PATHCONV=1 az role assignment list --role 53ca6127-db72-4b80-b1b0-d745d6d5456d --scope $aif_resource_id --assignee $signed_user_id --query "[].roleDefinitionId" -o tsv)
| Otherwise, provide thorough answers using only data from SQL or call transcripts. | ||
| If no data is found, please respond with 'No data found for that client.' Remove any client identifiers from the final response.''' | ||
| var functionAppStreamTextSystemPrompt = '''The currently selected client's name is '{SelectedClientName}'. Treat any case-insensitive or partial mention as referring to this client. | ||
| If the user mentions no name, assume they are asking about '{SelectedClientName}'.. |
Copilot
AI
Jun 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is an extra period before the closing quote after {SelectedClientName}—please remove the duplicate period.
| If the user mentions no name, assume they are asking about '{SelectedClientName}'.. | |
| If the user mentions no name, assume they are asking about '{SelectedClientName}'. |
| continue | ||
| yield chunk.content # just the deltaText | ||
| finally: | ||
| thread = chunk.thread |
Copilot
AI
Jun 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the finally block, chunk may be undefined if no items were yielded, causing an UnboundLocalError. You should capture the thread reference outside the loop or guard against chunk not existing.
| thread = chunk.thread | |
| thread = chunk.thread if chunk else None # Guard against chunk being None |
* Implemented Log execution time per prompt in Report * updated readme * updated the code * added functions * feat: added fdp changes, updated to use ai agents instead of openai assistants (#566) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * refactor: couple of typo fix (#570) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * fix: correct variable names for managed identity and AI foundry in scripts and templates --------- Co-authored-by: Rohini-Microsoft <v-rwalunj@microsoft.com> Co-authored-by: Avijit-Microsoft <v-aghorui@microsoft.com> Co-authored-by: Harsh-Microsoft <v-hbangera@microsoft.com>
…from popup (#578) * feat: FDP changes, Updation to use AI agents (#571) * Implemented Log execution time per prompt in Report * updated readme * updated the code * added functions * feat: added fdp changes, updated to use ai agents instead of openai assistants (#566) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * refactor: couple of typo fix (#570) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * fix: correct variable names for managed identity and AI foundry in scripts and templates --------- Co-authored-by: Rohini-Microsoft <v-rwalunj@microsoft.com> Co-authored-by: Avijit-Microsoft <v-aghorui@microsoft.com> Co-authored-by: Harsh-Microsoft <v-hbangera@microsoft.com> * bug fix(#19849) --------- Co-authored-by: Prajwal-Microsoft <v-dcprajwal@microsoft.com> Co-authored-by: Ragini-Microsoft <v-raginich@microsoft.com> Co-authored-by: Rohini-Microsoft <v-rwalunj@microsoft.com> Co-authored-by: Avijit-Microsoft <v-aghorui@microsoft.com> Co-authored-by: Harsh-Microsoft <v-hbangera@microsoft.com>
* Implemented Log execution time per prompt in Report * updated readme * updated the code * added functions * feat: added fdp changes, updated to use ai agents instead of openai assistants (#566) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * refactor: couple of typo fix (#570) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * fix: correct variable names for managed identity and AI foundry in scripts and templates * feat: quota check during azd up (#579) * quota-check-during azd up * updated bicep and parameter json * fix: There is no progress/Process message when deleting chat history from popup (#578) * feat: FDP changes, Updation to use AI agents (#571) * Implemented Log execution time per prompt in Report * updated readme * updated the code * added functions * feat: added fdp changes, updated to use ai agents instead of openai assistants (#566) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * refactor: couple of typo fix (#570) * initial bicep changes for fdp * update role assignments in bicep * feat: initial fdp changes for client advisor * updated post deployment scripts to use keyless authentication * rebuilt main.json * fix configuration handling and error checking in backend services * updated unit tests * Refactor code for improved readability and maintainability by organizing imports and formatting code blocks consistently across multiple files. * fix: correct variable names for managed identity and AI foundry in scripts and templates --------- Co-authored-by: Rohini-Microsoft <v-rwalunj@microsoft.com> Co-authored-by: Avijit-Microsoft <v-aghorui@microsoft.com> Co-authored-by: Harsh-Microsoft <v-hbangera@microsoft.com> * bug fix(#19849) --------- Co-authored-by: Prajwal-Microsoft <v-dcprajwal@microsoft.com> Co-authored-by: Ragini-Microsoft <v-raginich@microsoft.com> Co-authored-by: Rohini-Microsoft <v-rwalunj@microsoft.com> Co-authored-by: Avijit-Microsoft <v-aghorui@microsoft.com> Co-authored-by: Harsh-Microsoft <v-hbangera@microsoft.com> * updated openai version (#581) * deleted params --------- Co-authored-by: Rohini-Microsoft <v-rwalunj@microsoft.com> Co-authored-by: Avijit-Microsoft <v-aghorui@microsoft.com> Co-authored-by: Harsh-Microsoft <v-hbangera@microsoft.com> Co-authored-by: Priyanka-Microsoft <v-prisinghal@microsoft.com> Co-authored-by: Bangarraju-Microsoft <v-golib@microsoft.com> Co-authored-by: Prajwal-Microsoft <v-dcprajwal@microsoft.com> Co-authored-by: Ragini-Microsoft <v-raginich@microsoft.com>
|
🎉 This PR is included in version 1.5.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Purpose
This pull request introduces significant updates to the AI Foundry deployment infrastructure, including replacing older AI services with new AI Foundry resources, updating API versions, and simplifying parameter usage. The changes focus on transitioning to the AI Foundry framework, optimizing resource configurations, and removing unused or redundant parameters. Below is a summary of the most important changes grouped by theme.
Transition to AI Foundry Framework:
aiServicesandaiHubresources withaiFoundryandaiFoundryProjectresources ininfra/deploy_ai_foundry.bicep. This includes defining new properties such asallowProjectManagementand introducing aSystemAssignedidentity. [1] [2]infra/abbreviations.jsonto includeaiFoundryandaiFoundryProject.API and Resource Updates:
Azure OpenAI API Versionfrom2025-01-01-previewto2025-04-01-previewindocs/DeploymentGuide.md.aiSearchand its related configurations to use the2025-02-01-previewAPI version, adding support forSystemAssignedidentity and enhanced authentication options. [1] [2]Simplification and Cleanup:
AzureSearchKey,AzureOpenAIKey,SQLDB_USERNAME, andSQLDB_PASSWORDfrominfra/deploy_app_service.bicep. [1] [2] [3]infra/deploy_ai_foundry.bicep. [1] [2]Parameter and Script Enhancements:
aiFoundryResourceNameandaiSearchResourceNameto the sample data processing script indocs/DeploymentGuide.md.aiFoundryProjectEndpointandaiFoundryProjectNameparameters ininfra/deploy_app_service.bicepto align with the AI Foundry framework.Role Assignments and Connections:
Search Index Data ReaderandSearch Service Contributorto enable AI Foundry integration with Azure Search.These updates collectively enhance the deployment process, align the infrastructure with the latest AI Foundry capabilities, and simplify the overall configuration.
Does this introduce a breaking change?
Golden Path Validation
Deployment Validation
What to Check
Verify that the following are valid
Other Information