├── 4.company-research
├── .gitattributes
├── app
│ └── backend
│ │ ├── static
│ │ ├── themes
│ │ │ └── sb-admin
│ │ │ │ ├── scss
│ │ │ │ ├── _mixins.scss
│ │ │ │ ├── utilities
│ │ │ │ │ ├── _progress.scss
│ │ │ │ │ ├── _display.scss
│ │ │ │ │ ├── _rotate.scss
│ │ │ │ │ ├── _border.scss
│ │ │ │ │ ├── _background.scss
│ │ │ │ │ ├── _animation.scss
│ │ │ │ │ └── _text.scss
│ │ │ │ ├── _navs.scss
│ │ │ │ ├── _footer.scss
│ │ │ │ ├── _utilities.scss
│ │ │ │ ├── _dropdowns.scss
│ │ │ │ ├── _charts.scss
│ │ │ │ ├── sb-admin-2.scss
│ │ │ │ ├── _cards.scss
│ │ │ │ ├── navs
│ │ │ │ │ └── _global.scss
│ │ │ │ ├── _login.scss
│ │ │ │ ├── _global.scss
│ │ │ │ ├── _buttons.scss
│ │ │ │ └── _error.scss
│ │ │ │ └── js
│ │ │ │ └── sb-admin-2.min.js
│ │ ├── css
│ │ │ ├── company.css
│ │ │ └── site.css
│ │ ├── favicon.ico
│ │ ├── images
│ │ │ ├── msft-md.png
│ │ │ └── atomic-loading.gif
│ │ └── js
│ │ │ └── site.js
│ │ ├── .deployment
│ │ ├── requirements.txt
│ │ └── .env.template
├── docs
│ ├── diagram.png
│ ├── demo-chat.png
│ └── demo-report.png
├── .vscode
│ ├── extensions.json
│ ├── tasks.json
│ ├── launch.json
│ └── settings.json
├── scripts
│ ├── requirements.txt
│ ├── .env.template
│ └── company_common.json
├── azure.yaml
├── infra
│ ├── core
│ │ ├── host
│ │ │ └── appserviceplan.bicep
│ │ ├── security
│ │ │ └── role.bicep
│ │ ├── redis
│ │ │ └── enterprise.bicep
│ │ └── ai
│ │ │ └── cognitiveservices.bicep
│ └── main.parameters.json
└── .devcontainer
│ ├── devcontainer.json
│ └── Dockerfile
├── poetry.toml
├── 3.goal-achievement-adviser
├── .gitattributes
├── app
│ ├── backend
│ │ ├── startup.txt
│ │ ├── .deployment
│ │ ├── requirements-dev.txt
│ │ ├── requirements.txt
│ │ ├── templates
│ │ │ ├── display.html
│ │ │ ├── login.html
│ │ │ ├── index_org.html
│ │ │ └── auth_error.html
│ │ ├── pyproject.toml
│ │ ├── .env.example
│ │ └── task_assistant
│ │ │ ├── conversation_summary.py
│ │ │ └── search_info.py
│ ├── frontend
│ │ ├── src
│ │ │ ├── vite-env.d.ts
│ │ │ ├── api
│ │ │ │ ├── index.ts
│ │ │ │ ├── api.ts
│ │ │ │ └── models.ts
│ │ │ ├── components
│ │ │ │ ├── QuestionInput
│ │ │ │ │ ├── index.ts
│ │ │ │ │ └── QuestionInput.module.css
│ │ │ │ ├── SettingsButton
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── SettingsButton.module.css
│ │ │ │ │ └── SettingsButton.tsx
│ │ │ │ ├── UserChatMessage
│ │ │ │ │ ├── index.ts
│ │ │ │ │ ├── UserChatMessage.tsx
│ │ │ │ │ └── UserChatMessage.module.css
│ │ │ │ ├── ClearChatButton
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── ClearChatButton.module.css
│ │ │ │ │ └── ClearChatButton.tsx
│ │ │ │ ├── SupportingContent
│ │ │ │ │ ├── index.ts
│ │ │ │ │ ├── SupportingContentParser.ts
│ │ │ │ │ ├── SupportingContent.module.css
│ │ │ │ │ └── SupportingContent.tsx
│ │ │ │ ├── Example
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── Example.tsx
│ │ │ │ │ └── Example.module.css
│ │ │ │ ├── AnalysisPanel
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── AnalysisPanelTabs.tsx
│ │ │ │ │ └── AnalysisPanel.module.css
│ │ │ │ └── Answer
│ │ │ │ │ ├── index.ts
│ │ │ │ │ ├── AnswerIcon.tsx
│ │ │ │ │ ├── AnswerError.tsx
│ │ │ │ │ └── AnswerLoading.tsx
│ │ │ ├── pages
│ │ │ │ ├── NoPage.tsx
│ │ │ │ └── layout
│ │ │ │ │ └── Layout.module.css
│ │ │ ├── assets
│ │ │ │ ├── sample01.png
│ │ │ │ ├── sample02.png
│ │ │ │ ├── sample03.png
│ │ │ │ ├── msft-logo-color.png
│ │ │ │ ├── msft-logo-color-text.png
│ │ │ │ ├── search.svg
│ │ │ │ └── github.svg
│ │ │ ├── index.css
│ │ │ └── index.tsx
│ │ ├── .prettierrc.json
│ │ ├── public
│ │ │ └── favicon.ico
│ │ ├── index.html
│ │ ├── vite.config.ts
│ │ ├── tsconfig.json
│ │ └── package.json
│ └── start.sh
├── assets
│ └── endpoint.png
├── docs
│ ├── chatscreen.png
│ └── appcomponents.png
├── .vscode
│ ├── extensions.json
│ ├── tasks.json
│ └── settings.json
├── scripts
│ ├── requirements.txt
│ └── .env.template
├── infra
│ ├── core
│ │ ├── host
│ │ │ └── appserviceplan.bicep
│ │ ├── security
│ │ │ └── role.bicep
│ │ ├── redis
│ │ │ └── enterprise.bicep
│ │ ├── search
│ │ │ └── search-services.bicep
│ │ └── ai
│ │ │ └── cognitiveservices.bicep
│ └── main.parameters.json
└── azure.yaml
├── 5.internal-document-search
├── .gitattributes
├── src
│ ├── backend
│ │ ├── core
│ │ │ └── __init__.py
│ │ ├── text.py
│ │ ├── approaches
│ │ │ └── approach.py
│ │ ├── data
│ │ │ └── employeeinfo.csv
│ │ └── requirements.txt
│ ├── frontend
│ │ ├── src
│ │ │ ├── vite-env.d.ts
│ │ │ ├── api
│ │ │ │ └── index.ts
│ │ │ ├── components
│ │ │ │ ├── QuestionInput
│ │ │ │ │ ├── index.ts
│ │ │ │ │ └── QuestionInput.module.css
│ │ │ │ ├── SettingsButton
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── SettingsButton.module.css
│ │ │ │ │ └── SettingsButton.tsx
│ │ │ │ ├── UserChatMessage
│ │ │ │ │ ├── index.ts
│ │ │ │ │ ├── UserChatMessage.tsx
│ │ │ │ │ └── UserChatMessage.module.css
│ │ │ │ ├── ClearChatButton
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── ClearChatButton.module.css
│ │ │ │ │ └── ClearChatButton.tsx
│ │ │ │ ├── SupportingContent
│ │ │ │ │ ├── index.ts
│ │ │ │ │ ├── SupportingContentParser.ts
│ │ │ │ │ ├── SupportingContent.module.css
│ │ │ │ │ └── SupportingContent.tsx
│ │ │ │ ├── Example
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── Example.tsx
│ │ │ │ │ ├── Example.module.css
│ │ │ │ │ └── ExampleList.tsx
│ │ │ │ ├── AnalysisPanel
│ │ │ │ │ ├── index.tsx
│ │ │ │ │ ├── AnalysisPanelTabs.tsx
│ │ │ │ │ └── AnalysisPanel.module.css
│ │ │ │ └── Answer
│ │ │ │ │ ├── index.ts
│ │ │ │ │ ├── AnswerIcon.tsx
│ │ │ │ │ ├── AnswerError.tsx
│ │ │ │ │ ├── AnswerLoading.tsx
│ │ │ │ │ └── AnswerChat.tsx
│ │ │ ├── pages
│ │ │ │ └── NoPage.tsx
│ │ │ ├── index.css
│ │ │ ├── assets
│ │ │ │ ├── search.svg
│ │ │ │ └── github.svg
│ │ │ └── index.tsx
│ │ ├── .prettierrc.json
│ │ ├── public
│ │ │ └── favicon.ico
│ │ ├── index.html
│ │ ├── vite.config.ts
│ │ ├── tsconfig.json
│ │ └── package.json
│ └── start.sh
├── data
│ └── 001018385.pdf
├── assets
│ ├── apim_arch.png
│ ├── chatscreen.png
│ ├── endpoint.png
│ ├── private_403.png
│ ├── appcomponents.png
│ ├── apim_arch_deploy_step1.png
│ ├── apim_arch_deploy_step2.png
│ ├── apim_arch_deploy_step3.png
│ ├── apim_arch_deploy_step4.png
│ ├── apim_arch_deploy_step5.png
│ ├── apim_arch_deploy_step6.png
│ ├── entra-id-app-settings.png
│ └── private_endpoint_arch.png
├── scripts
│ ├── requirements.txt
│ ├── cosmosreadwriterole.json
│ ├── roles.ps1
│ └── prepdocs.sh
├── infra
│ └── core
│ │ ├── monitor
│ │ ├── loganalytics.bicep
│ │ ├── applicationinsights.bicep
│ │ └── monitoring.bicep
│ │ ├── network
│ │ ├── vnet.bicep
│ │ ├── pip.bicep
│ │ ├── nsg.bicep
│ │ ├── subnet.bicep
│ │ └── nic.bicep
│ │ ├── host
│ │ └── appserviceplan.bicep
│ │ ├── security
│ │ └── role.bicep
│ │ ├── search
│ │ └── search-services.bicep
│ │ └── vm
│ │ └── vm.bicep
├── .devcontainer
│ └── devcontainer.json
└── azure.yaml
├── 1.call-center
├── app
│ ├── static
│ │ ├── themes
│ │ │ └── sb-admin
│ │ │ │ ├── scss
│ │ │ │ ├── _mixins.scss
│ │ │ │ ├── utilities
│ │ │ │ │ ├── _progress.scss
│ │ │ │ │ ├── _display.scss
│ │ │ │ │ ├── _rotate.scss
│ │ │ │ │ ├── _border.scss
│ │ │ │ │ ├── _background.scss
│ │ │ │ │ ├── _animation.scss
│ │ │ │ │ └── _text.scss
│ │ │ │ ├── _navs.scss
│ │ │ │ ├── _footer.scss
│ │ │ │ ├── _utilities.scss
│ │ │ │ ├── _dropdowns.scss
│ │ │ │ ├── _charts.scss
│ │ │ │ ├── sb-admin-2.scss
│ │ │ │ ├── _cards.scss
│ │ │ │ ├── navs
│ │ │ │ │ └── _global.scss
│ │ │ │ ├── _login.scss
│ │ │ │ ├── _global.scss
│ │ │ │ ├── _buttons.scss
│ │ │ │ └── _error.scss
│ │ │ │ └── js
│ │ │ │ └── sb-admin-2.min.js
│ │ ├── images
│ │ │ ├── done.gif
│ │ │ ├── done.png
│ │ │ ├── logo.png
│ │ │ ├── red.png
│ │ │ ├── hero-1.jpg
│ │ │ ├── loading.gif
│ │ │ ├── msft-md.png
│ │ │ ├── openai.png
│ │ │ ├── openai_black.png
│ │ │ ├── openai_blue.png
│ │ │ ├── anime-working.gif
│ │ │ ├── atomic-loading.gif
│ │ │ ├── msft-logo-color.png
│ │ │ ├── anime-conversation.gif
│ │ │ └── msft-large-white-xs.png
│ │ └── js
│ │ │ └── main.js
│ ├── requirements.txt
│ ├── utilities
│ │ └── config.py
│ ├── swagger_client
│ │ └── api
│ │ │ └── __init__.py
│ ├── .vscode
│ │ └── launch.json
│ ├── LICENSE
│ └── templates
│ │ └── template.html
└── assets
│ ├── demo.jpg
│ ├── deploy.jpg
│ ├── diagram.jpg
│ └── appservice_configuration.jpg
├── 2.recipe-adviser
├── .gitignore
├── app
│ ├── backend
│ │ ├── static
│ │ │ ├── themes
│ │ │ │ └── sb-admin
│ │ │ │ │ ├── scss
│ │ │ │ │ ├── _mixins.scss
│ │ │ │ │ ├── utilities
│ │ │ │ │ │ ├── _progress.scss
│ │ │ │ │ │ ├── _display.scss
│ │ │ │ │ │ ├── _rotate.scss
│ │ │ │ │ │ ├── _border.scss
│ │ │ │ │ │ ├── _background.scss
│ │ │ │ │ │ ├── _animation.scss
│ │ │ │ │ │ └── _text.scss
│ │ │ │ │ ├── _navs.scss
│ │ │ │ │ ├── _footer.scss
│ │ │ │ │ ├── _utilities.scss
│ │ │ │ │ ├── _dropdowns.scss
│ │ │ │ │ ├── _charts.scss
│ │ │ │ │ ├── sb-admin-2.scss
│ │ │ │ │ ├── _cards.scss
│ │ │ │ │ ├── navs
│ │ │ │ │ │ └── _global.scss
│ │ │ │ │ ├── _login.scss
│ │ │ │ │ ├── _global.scss
│ │ │ │ │ ├── _buttons.scss
│ │ │ │ │ └── _error.scss
│ │ │ │ │ └── js
│ │ │ │ │ └── sb-admin-2.min.js
│ │ │ ├── favicon.ico
│ │ │ ├── images
│ │ │ │ ├── msft-md.png
│ │ │ │ ├── atomic-loading.gif
│ │ │ │ └── loan_simulation.png
│ │ │ └── css
│ │ │ │ ├── site.css
│ │ │ │ └── food_menu.css
│ │ ├── .deployment
│ │ ├── requirements.txt
│ │ └── food_menu
│ │ │ ├── food_advisory.py
│ │ │ └── food_image.py
│ ├── Dockerfile
│ ├── compose.yml
│ └── .env.example
├── assets
│ ├── app-service.png
│ ├── architecture.png
│ ├── app-service-2.png
│ ├── application-ui.png
│ ├── open-ai-service.png
│ └── bicep-deployment.png
├── azure.yaml
└── infra
│ ├── core
│ ├── host
│ │ ├── appServicePlan.bicep
│ │ └── appService.bicep
│ ├── security
│ │ └── keyVault.bicep
│ └── ai
│ │ └── cognitiveServices.bicep
│ └── main.parameters.json
├── 6.azureopenai-landing-zone-accelerator
├── azure.yaml
├── assets
│ ├── apim-settings.png
│ ├── architecture.png
│ ├── deployment-id.png
│ ├── jwt-get-step1.png
│ ├── jwt-get-step2.png
│ ├── jwt-get-step3.png
│ ├── jwt-get-step4.png
│ ├── subscription.png
│ ├── apim-howto-test.png
│ └── apim-test-result.png
└── infra
│ ├── core
│ ├── monitor
│ │ ├── loganalytics.bicep
│ │ ├── applicationinsights.bicep
│ │ └── monitoring.bicep
│ ├── security
│ │ ├── role.bicep
│ │ ├── keyvault-access.bicep
│ │ ├── keyvault.bicep
│ │ └── keyvault-secret.bicep
│ ├── ai
│ │ └── cognitiveservices.bicep
│ └── search
│ │ └── search-services.bicep
│ ├── main.parameters.json
│ └── app
│ └── web.bicep
├── CHANGELOG.md
├── .github
├── dependabot.yml
├── CODE_OF_CONDUCT.md
├── workflows
│ ├── static-analysis.yml
│ ├── bicep-audit.yml
│ └── 5.what-if.yml
├── ISSUE_TEMPLATE.md
└── PULL_REQUEST_TEMPLATE.md
├── pyproject.toml
└── LICENSE.md
/4.company-research/.gitattributes:
--------------------------------------------------------------------------------
1 | *.sh text eol=lf
--------------------------------------------------------------------------------
/poetry.toml:
--------------------------------------------------------------------------------
1 | [virtualenvs]
2 | in-project = true
3 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/.gitattributes:
--------------------------------------------------------------------------------
1 | *.sh text eol=lf
--------------------------------------------------------------------------------
/5.internal-document-search/.gitattributes:
--------------------------------------------------------------------------------
1 | *.sh text eol=lf
--------------------------------------------------------------------------------
/5.internal-document-search/src/backend/core/__init__.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_mixins.scss:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/2.recipe-adviser/.gitignore:
--------------------------------------------------------------------------------
1 | __pycache__
2 | .env
3 | .venv
4 | .azure
5 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/startup.txt:
--------------------------------------------------------------------------------
1 | PORT=80 python app.py
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_mixins.scss:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_mixins.scss:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/.deployment:
--------------------------------------------------------------------------------
1 | [config]
2 | SCM_DO_BUILD_DURING_DEPLOYMENT=true
--------------------------------------------------------------------------------
/4.company-research/app/backend/.deployment:
--------------------------------------------------------------------------------
1 | [config]
2 | SCM_DO_BUILD_DURING_DEPLOYMENT=true
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/.deployment:
--------------------------------------------------------------------------------
1 | [config]
2 | SCM_DO_BUILD_DURING_DEPLOYMENT=true
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/css/company.css:
--------------------------------------------------------------------------------
1 | body {
2 | background-color: white;
3 | }
4 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/api/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./api";
2 | export * from "./models";
3 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/api/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./api";
2 | export * from "./models";
3 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/utilities/_progress.scss:
--------------------------------------------------------------------------------
1 | .progress-sm {
2 | height: .5rem;
3 | }
4 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/QuestionInput/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./QuestionInput";
2 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/SettingsButton/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./SettingsButton";
2 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/UserChatMessage/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./UserChatMessage";
2 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/QuestionInput/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./QuestionInput";
2 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/SettingsButton/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./SettingsButton";
2 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/UserChatMessage/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./UserChatMessage";
2 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/ClearChatButton/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./ClearChatButton";
2 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/SupportingContent/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./SupportingContent";
2 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/ClearChatButton/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./ClearChatButton";
2 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/SupportingContent/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./SupportingContent";
2 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/utilities/_progress.scss:
--------------------------------------------------------------------------------
1 | .progress-sm {
2 | height: .5rem;
3 | }
4 |
--------------------------------------------------------------------------------
/1.call-center/assets/demo.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/assets/demo.jpg
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/utilities/_progress.scss:
--------------------------------------------------------------------------------
1 | .progress-sm {
2 | height: .5rem;
3 | }
4 |
--------------------------------------------------------------------------------
/1.call-center/assets/deploy.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/assets/deploy.jpg
--------------------------------------------------------------------------------
/1.call-center/assets/diagram.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/assets/diagram.jpg
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/requirements-dev.txt:
--------------------------------------------------------------------------------
1 | black==24.3.0
2 | ruff==0.0.267
3 | pytest==7.3.1
4 | pytest-cov==4.0.0
5 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/Example/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./Example";
2 | export * from "./ExampleList";
3 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Example/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./Example";
2 | export * from "./ExampleList";
3 |
--------------------------------------------------------------------------------
/4.company-research/docs/diagram.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/4.company-research/docs/diagram.png
--------------------------------------------------------------------------------
/5.internal-document-search/src/backend/text.py:
--------------------------------------------------------------------------------
1 | def nonewlines(s: str) -> str:
2 | return s.replace('\n', ' ').replace('\r', ' ')
3 |
4 |
--------------------------------------------------------------------------------
/4.company-research/docs/demo-chat.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/4.company-research/docs/demo-chat.png
--------------------------------------------------------------------------------
/1.call-center/app/static/images/done.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/done.gif
--------------------------------------------------------------------------------
/1.call-center/app/static/images/done.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/done.png
--------------------------------------------------------------------------------
/1.call-center/app/static/images/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/logo.png
--------------------------------------------------------------------------------
/1.call-center/app/static/images/red.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/red.png
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_navs.scss:
--------------------------------------------------------------------------------
1 | @import "navs/global.scss";
2 | @import "navs/topbar.scss";
3 | @import "navs/sidebar.scss";
4 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/utilities/_display.scss:
--------------------------------------------------------------------------------
1 | // Overflow Hidden
2 | .o-hidden {
3 | overflow: hidden !important;
4 | }
5 |
--------------------------------------------------------------------------------
/2.recipe-adviser/assets/app-service.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/assets/app-service.png
--------------------------------------------------------------------------------
/2.recipe-adviser/assets/architecture.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/assets/architecture.png
--------------------------------------------------------------------------------
/4.company-research/docs/demo-report.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/4.company-research/docs/demo-report.png
--------------------------------------------------------------------------------
/1.call-center/app/static/images/hero-1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/hero-1.jpg
--------------------------------------------------------------------------------
/1.call-center/app/static/images/loading.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/loading.gif
--------------------------------------------------------------------------------
/1.call-center/app/static/images/msft-md.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/msft-md.png
--------------------------------------------------------------------------------
/1.call-center/app/static/images/openai.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/openai.png
--------------------------------------------------------------------------------
/2.recipe-adviser/assets/app-service-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/assets/app-service-2.png
--------------------------------------------------------------------------------
/2.recipe-adviser/assets/application-ui.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/assets/application-ui.png
--------------------------------------------------------------------------------
/2.recipe-adviser/assets/open-ai-service.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/assets/open-ai-service.png
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/AnalysisPanel/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./AnalysisPanel";
2 | export * from "./AnalysisPanelTabs";
3 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/pages/NoPage.tsx:
--------------------------------------------------------------------------------
1 | const NoPage = () => {
2 | return
404
;
3 | };
4 |
5 | export default NoPage;
6 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/AnalysisPanel/index.tsx:
--------------------------------------------------------------------------------
1 | export * from "./AnalysisPanel";
2 | export * from "./AnalysisPanelTabs";
3 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/pages/NoPage.tsx:
--------------------------------------------------------------------------------
1 | const NoPage = () => {
2 | return 404
;
3 | };
4 |
5 | export default NoPage;
6 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/utilities/_display.scss:
--------------------------------------------------------------------------------
1 | // Overflow Hidden
2 | .o-hidden {
3 | overflow: hidden !important;
4 | }
5 |
--------------------------------------------------------------------------------
/2.recipe-adviser/assets/bicep-deployment.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/assets/bicep-deployment.png
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/utilities/_display.scss:
--------------------------------------------------------------------------------
1 | // Overflow Hidden
2 | .o-hidden {
3 | overflow: hidden !important;
4 | }
5 |
--------------------------------------------------------------------------------
/5.internal-document-search/data/001018385.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/data/001018385.pdf
--------------------------------------------------------------------------------
/1.call-center/app/static/images/openai_black.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/openai_black.png
--------------------------------------------------------------------------------
/1.call-center/app/static/images/openai_blue.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/openai_blue.png
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/app/backend/static/favicon.ico
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_navs.scss:
--------------------------------------------------------------------------------
1 | @import "navs/global.scss";
2 | @import "navs/topbar.scss";
3 | @import "navs/sidebar.scss";
4 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/assets/endpoint.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/assets/endpoint.png
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/docs/chatscreen.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/docs/chatscreen.png
--------------------------------------------------------------------------------
/4.company-research/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": [
3 | "esbenp.prettier-vscode",
4 | "ms-azuretools.azure-dev"
5 | ]
6 | }
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_navs.scss:
--------------------------------------------------------------------------------
1 | @import "navs/global.scss";
2 | @import "navs/topbar.scss";
3 | @import "navs/sidebar.scss";
4 |
--------------------------------------------------------------------------------
/5.internal-document-search/assets/apim_arch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/apim_arch.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/chatscreen.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/chatscreen.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/endpoint.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/endpoint.png
--------------------------------------------------------------------------------
/1.call-center/app/requirements.txt:
--------------------------------------------------------------------------------
1 | Flask==2.2.5
2 | Flask-Cors==5.0.0
3 | Flask-Session==0.4.0
4 | openai==0.27.0
5 | azure.identity==1.13.0
6 | azure.ai.textanalytics==5.2.1
--------------------------------------------------------------------------------
/1.call-center/app/static/images/anime-working.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/anime-working.gif
--------------------------------------------------------------------------------
/1.call-center/app/static/images/atomic-loading.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/atomic-loading.gif
--------------------------------------------------------------------------------
/1.call-center/app/utilities/config.py:
--------------------------------------------------------------------------------
1 | import uuid
2 |
3 | # app settings
4 | APP_SECRET = str(uuid.uuid4())
5 | JWT_SECRET = str(uuid.uuid4())
6 | MAX_CONTENT_SIZE = 200
--------------------------------------------------------------------------------
/1.call-center/assets/appservice_configuration.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/assets/appservice_configuration.jpg
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": [
3 | "esbenp.prettier-vscode",
4 | "ms-azuretools.azure-dev"
5 | ]
6 | }
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/Answer/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./Answer";
2 | export * from "./AnswerLoading";
3 | export * from "./AnswerError";
4 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/docs/appcomponents.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/docs/appcomponents.png
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/4.company-research/app/backend/static/favicon.ico
--------------------------------------------------------------------------------
/5.internal-document-search/assets/private_403.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/private_403.png
--------------------------------------------------------------------------------
/1.call-center/app/static/images/msft-logo-color.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/msft-logo-color.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/appcomponents.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/appcomponents.png
--------------------------------------------------------------------------------
/5.internal-document-search/src/backend/approaches/approach.py:
--------------------------------------------------------------------------------
1 | class Approach:
2 | def run(self, q: str, use_summaries: bool) -> any:
3 | raise NotImplementedError
4 |
--------------------------------------------------------------------------------
/1.call-center/app/static/images/anime-conversation.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/anime-conversation.gif
--------------------------------------------------------------------------------
/1.call-center/app/static/images/msft-large-white-xs.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/1.call-center/app/static/images/msft-large-white-xs.png
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/images/msft-md.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/app/backend/static/images/msft-md.png
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/.prettierrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "tabWidth": 4,
3 | "printWidth": 160,
4 | "arrowParens": "avoid",
5 | "trailingComma": "none"
6 | }
7 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/.prettierrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "tabWidth": 4,
3 | "printWidth": 160,
4 | "arrowParens": "avoid",
5 | "trailingComma": "none"
6 | }
7 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/utilities/_rotate.scss:
--------------------------------------------------------------------------------
1 | .rotate-15 {
2 | transform: rotate(15deg);
3 | }
4 |
5 | .rotate-n-15 {
6 | transform: rotate(-15deg);
7 | }
8 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/app/frontend/public/favicon.ico
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/images/msft-md.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/4.company-research/app/backend/static/images/msft-md.png
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/src/frontend/public/favicon.ico
--------------------------------------------------------------------------------
/4.company-research/app/backend/requirements.txt:
--------------------------------------------------------------------------------
1 | azure-identity==1.16.1
2 | numpy==1.24.3
3 | pandas==2.0.2
4 | Flask==2.2.5
5 | openai==0.27.7
6 | redis==4.5.4
7 | opencensus-ext-azure==1.1.9
--------------------------------------------------------------------------------
/5.internal-document-search/assets/apim_arch_deploy_step1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/apim_arch_deploy_step1.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/apim_arch_deploy_step2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/apim_arch_deploy_step2.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/apim_arch_deploy_step3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/apim_arch_deploy_step3.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/apim_arch_deploy_step4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/apim_arch_deploy_step4.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/apim_arch_deploy_step5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/apim_arch_deploy_step5.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/apim_arch_deploy_step6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/apim_arch_deploy_step6.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/entra-id-app-settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/entra-id-app-settings.png
--------------------------------------------------------------------------------
/5.internal-document-search/assets/private_endpoint_arch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/5.internal-document-search/assets/private_endpoint_arch.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/azure.yaml:
--------------------------------------------------------------------------------
1 | # yaml-language-server: $schema=https://raw.githubusercontent.com/Azure/azure-dev/main/schemas/v1.0/azure.yaml.json
2 |
3 | name: set-your-app
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/images/atomic-loading.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/app/backend/static/images/atomic-loading.gif
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/images/loan_simulation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/2.recipe-adviser/app/backend/static/images/loan_simulation.png
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/utilities/_rotate.scss:
--------------------------------------------------------------------------------
1 | .rotate-15 {
2 | transform: rotate(15deg);
3 | }
4 |
5 | .rotate-n-15 {
6 | transform: rotate(-15deg);
7 | }
8 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/assets/sample01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/app/frontend/src/assets/sample01.png
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/assets/sample02.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/app/frontend/src/assets/sample02.png
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/assets/sample03.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/app/frontend/src/assets/sample03.png
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/scripts/requirements.txt:
--------------------------------------------------------------------------------
1 | azure-identity==1.13.0
2 | python-dotenv==1.0.0
3 | redis==4.5.5
4 | openai==0.27.8
5 | tiktoken==0.4.0
6 | numpy==1.25.0
7 | pandas==2.0.2
8 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/images/atomic-loading.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/4.company-research/app/backend/static/images/atomic-loading.gif
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/apim-settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/apim-settings.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/architecture.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/architecture.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/deployment-id.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/deployment-id.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step1.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step2.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step3.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/jwt-get-step4.png
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/subscription.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/subscription.png
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/utilities/_rotate.scss:
--------------------------------------------------------------------------------
1 | .rotate-15 {
2 | transform: rotate(15deg);
3 | }
4 |
5 | .rotate-n-15 {
6 | transform: rotate(-15deg);
7 | }
8 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/apim-howto-test.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/apim-howto-test.png
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Answer/index.ts:
--------------------------------------------------------------------------------
1 | export * from "./Answer";
2 | export * from "./AnswerChat";
3 | export * from "./AnswerLoading";
4 | export * from "./AnswerError";
5 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/assets/apim-test-result.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/6.azureopenai-landing-zone-accelerator/assets/apim-test-result.png
--------------------------------------------------------------------------------
/1.call-center/app/swagger_client/api/__init__.py:
--------------------------------------------------------------------------------
1 | from __future__ import absolute_import
2 |
3 | # flake8: noqa
4 |
5 | # import apis into api package
6 | from swagger_client.api.default_api import DefaultApi
7 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/assets/msft-logo-color.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/app/frontend/src/assets/msft-logo-color.png
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/SettingsButton/SettingsButton.module.css:
--------------------------------------------------------------------------------
1 | .container {
2 | display: flex;
3 | align-items: center;
4 | gap: 6px;
5 | cursor: pointer;
6 | }
7 |
--------------------------------------------------------------------------------
/4.company-research/scripts/requirements.txt:
--------------------------------------------------------------------------------
1 | azure-identity==1.16.1
2 | python-dotenv
3 | redis
4 | openai==0.27.8
5 | tiktoken==0.4.0
6 | azure-cognitiveservices-search-websearch==2.0.0
7 | numpy
8 | pandas
9 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/SettingsButton/SettingsButton.module.css:
--------------------------------------------------------------------------------
1 | .container {
2 | display: flex;
3 | align-items: center;
4 | gap: 6px;
5 | cursor: pointer;
6 | }
7 |
--------------------------------------------------------------------------------
/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | ## [project-title] Changelog
2 |
3 |
4 | # x.y.z (yyyy-mm-dd)
5 |
6 | *Features*
7 | * ...
8 |
9 | *Bug Fixes*
10 | * ...
11 |
12 | *Breaking Changes*
13 | * ...
14 |
--------------------------------------------------------------------------------
/5.internal-document-search/scripts/requirements.txt:
--------------------------------------------------------------------------------
1 | azure-identity==1.25.0
2 | azure-search-documents==11.5.3
3 | azure-ai-formrecognizer==3.3.3
4 | pypdf==6.0.0
5 | azure-storage-blob==12.26.0
6 | typing==3.7.4.3
7 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/requirements.txt:
--------------------------------------------------------------------------------
1 | azure-identity==1.13.0b3
2 | numpy==1.24.3
3 | pandas==2.0.2
4 | Flask==2.2.5
5 | openai==0.27.7
6 | redis==4.5.4
7 | opencensus-ext-azure==1.1.9
8 | python-dotenv==1.0.0
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/assets/msft-logo-color-text.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/jp-azureopenai-samples/HEAD/3.goal-achievement-adviser/app/frontend/src/assets/msft-logo-color-text.png
--------------------------------------------------------------------------------
/4.company-research/azure.yaml:
--------------------------------------------------------------------------------
1 | # yaml-language-server: $schema=https://raw.githubusercontent.com/Azure/azure-dev/main/schemas/v1.0/azure.yaml.json
2 |
3 | name: azure-openai-demo-retail
4 | metadata:
5 | template: azure-openai-demo-retail@0.0.1-beta
6 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/AnalysisPanel/AnalysisPanelTabs.tsx:
--------------------------------------------------------------------------------
1 | export enum AnalysisPanelTabs {
2 | ThoughtProcessTab = "thoughtProcess",
3 | SupportingContentTab = "supportingContent",
4 | CitationTab = "citation"
5 | }
6 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/AnalysisPanel/AnalysisPanelTabs.tsx:
--------------------------------------------------------------------------------
1 | export enum AnalysisPanelTabs {
2 | ThoughtProcessTab = "thoughtProcess",
3 | SupportingContentTab = "supportingContent",
4 | CitationTab = "citation"
5 | }
6 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/ClearChatButton/ClearChatButton.module.css:
--------------------------------------------------------------------------------
1 | .container {
2 | display: flex;
3 | align-items: center;
4 | gap: 6px;
5 | cursor: pointer;
6 | }
7 |
8 | .disabled {
9 | opacity: 0.4;
10 | }
11 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/ClearChatButton/ClearChatButton.module.css:
--------------------------------------------------------------------------------
1 | .container {
2 | display: flex;
3 | align-items: center;
4 | gap: 6px;
5 | cursor: pointer;
6 | }
7 |
8 | .disabled {
9 | opacity: 0.4;
10 | }
11 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/utilities/_border.scss:
--------------------------------------------------------------------------------
1 | @each $color, $value in $theme-colors {
2 | @each $position in ['left', 'bottom'] {
3 | .border-#{$position}-#{$color} {
4 | border-#{$position}: .25rem solid $value !important;
5 | }
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/js/site.js:
--------------------------------------------------------------------------------
1 | // Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification
2 | // for details on configuring this project to bundle and minify static web assets.
3 |
4 | // Write your JavaScript code.
5 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/backend/data/employeeinfo.csv:
--------------------------------------------------------------------------------
1 | name,title,insurance,insurancegroup
2 | Employee1,Program Manager,Northwind Health Plus,Family
3 | Employee2,Software Engineer,Northwind Health Plus,Single
4 | Employee3,Software Engineer,Northwind Health Standard,Family
5 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/utilities/_border.scss:
--------------------------------------------------------------------------------
1 | @each $color, $value in $theme-colors {
2 | @each $position in ['left', 'bottom'] {
3 | .border-#{$position}-#{$color} {
4 | border-#{$position}: .25rem solid $value !important;
5 | }
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/AnalysisPanel/AnalysisPanel.module.css:
--------------------------------------------------------------------------------
1 | .thoughtProcess {
2 | font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New", monospace;
3 | word-wrap: break-word;
4 | padding-top: 12px;
5 | padding-bottom: 12px;
6 | }
7 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/utilities/_border.scss:
--------------------------------------------------------------------------------
1 | @each $color, $value in $theme-colors {
2 | @each $position in ['left', 'bottom'] {
3 | .border-#{$position}-#{$color} {
4 | border-#{$position}: .25rem solid $value !important;
5 | }
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/Answer/AnswerIcon.tsx:
--------------------------------------------------------------------------------
1 | import { Sparkle28Filled } from "@fluentui/react-icons";
2 |
3 | export const AnswerIcon = () => {
4 | return ;
5 | };
6 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Answer/AnswerIcon.tsx:
--------------------------------------------------------------------------------
1 | import { Sparkle28Filled } from "@fluentui/react-icons";
2 |
3 | export const AnswerIcon = () => {
4 | return ;
5 | };
6 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM ubuntu:latest
2 |
3 | RUN apt update
4 | RUN apt install python3 python3-pip curl -y
5 |
6 | RUN curl -sL https://aka.ms/InstallAzureCLIDeb | bash
7 |
8 | RUN mkdir /backend
9 |
10 | COPY ./backend /backend
11 |
12 | RUN pip3 install -r ./backend/requirements.txt
--------------------------------------------------------------------------------
/2.recipe-adviser/app/compose.yml:
--------------------------------------------------------------------------------
1 | version: '3'
2 | services:
3 | web:
4 | container_name: backend
5 | build: .
6 | command: python3 backend/app.py
7 | volumes:
8 | - ./backend:/backend
9 | ports:
10 | - 5000:5000
11 | env_file:
12 | - .env
13 | tty: true
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/css/site.css:
--------------------------------------------------------------------------------
1 | html {
2 | font-size: 14px;
3 | }
4 |
5 | @media (min-width: 768px) {
6 | html {
7 | font-size: 16px;
8 | }
9 | }
10 |
11 | html {
12 | position: relative;
13 | min-height: 100%;
14 | }
15 |
16 | body {
17 | margin-bottom: 60px;
18 | }
--------------------------------------------------------------------------------
/.github/dependabot.yml:
--------------------------------------------------------------------------------
1 | version: 2
2 | updates:
3 | - package-ecosystem: "pip"
4 | directory: "/5.internal-document-search/"
5 | schedule:
6 | interval: weekly
7 |
8 | - package-ecosystem: "npm"
9 | directory: "/5.internal-document-search/"
10 | schedule:
11 | interval: weekly
12 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_footer.scss:
--------------------------------------------------------------------------------
1 | footer.sticky-footer {
2 | padding: 2rem 0;
3 | flex-shrink: 0;
4 | .copyright {
5 | line-height: 1;
6 | font-size: 0.8rem;
7 | }
8 | }
9 |
10 | body.sidebar-toggled {
11 | footer.sticky-footer {
12 | width: 100%;
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_utilities.scss:
--------------------------------------------------------------------------------
1 | @import "utilities/animation.scss";
2 | @import "utilities/background.scss";
3 | @import "utilities/display.scss";
4 | @import "utilities/text.scss";
5 | @import "utilities/border.scss";
6 | @import "utilities/progress.scss";
7 | @import "utilities/rotate.scss";
8 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/css/site.css:
--------------------------------------------------------------------------------
1 | html {
2 | font-size: 14px;
3 | }
4 |
5 | @media (min-width: 768px) {
6 | html {
7 | font-size: 16px;
8 | }
9 | }
10 |
11 | html {
12 | position: relative;
13 | min-height: 100%;
14 | }
15 |
16 | body {
17 | margin-bottom: 60px;
18 | }
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_footer.scss:
--------------------------------------------------------------------------------
1 | footer.sticky-footer {
2 | padding: 2rem 0;
3 | flex-shrink: 0;
4 | .copyright {
5 | line-height: 1;
6 | font-size: 0.8rem;
7 | }
8 | }
9 |
10 | body.sidebar-toggled {
11 | footer.sticky-footer {
12 | width: 100%;
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_footer.scss:
--------------------------------------------------------------------------------
1 | footer.sticky-footer {
2 | padding: 2rem 0;
3 | flex-shrink: 0;
4 | .copyright {
5 | line-height: 1;
6 | font-size: 0.8rem;
7 | }
8 | }
9 |
10 | body.sidebar-toggled {
11 | footer.sticky-footer {
12 | width: 100%;
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_utilities.scss:
--------------------------------------------------------------------------------
1 | @import "utilities/animation.scss";
2 | @import "utilities/background.scss";
3 | @import "utilities/display.scss";
4 | @import "utilities/text.scss";
5 | @import "utilities/border.scss";
6 | @import "utilities/progress.scss";
7 | @import "utilities/rotate.scss";
8 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_utilities.scss:
--------------------------------------------------------------------------------
1 | @import "utilities/animation.scss";
2 | @import "utilities/background.scss";
3 | @import "utilities/display.scss";
4 | @import "utilities/text.scss";
5 | @import "utilities/border.scss";
6 | @import "utilities/progress.scss";
7 | @import "utilities/rotate.scss";
8 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/.env.example:
--------------------------------------------------------------------------------
1 | # Azure OpenAI Servicesの名称
2 | AZURE_OPENAI_GPT_DEPLOYMENT=
3 | # Azure OpenAI ServicesのAPIバージョン
4 | AZURE_OPENAI_API_VERSION=
5 | # Azure OpenAI Servicesのエンドポイント
6 | AZURE_OPENAI_SERVICE=
7 | # Azure OpenAI ServicesのAPIキー
8 | AZURE_OPENAI_API_KEY=
9 | # 画像生成モデルDALL-Eのバージョン
10 | AZURE_OPENAI_DALLE_API_VERSION=
--------------------------------------------------------------------------------
/5.internal-document-search/src/backend/requirements.txt:
--------------------------------------------------------------------------------
1 | azure-identity==1.15.0
2 | Flask==3.0.2
3 | openai==1.63.2
4 | azure-search-documents==11.4.0
5 | azure-storage-blob==12.19.0
6 | azure-cosmos==4.5.1
7 | azure-monitor-opentelemetry==1.2.0
8 | opencensus-ext-azure==1.1.13
9 | tiktoken==0.9.0
10 | opentelemetry-instrumentation-flask==0.48b0
11 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/requirements.txt:
--------------------------------------------------------------------------------
1 | python-dotenv
2 | azure-identity==1.13.0b3
3 | Flask==2.2.5
4 | # langchain==0.0.152
5 | azure-storage-blob==12.14.1
6 | openai==0.27.4
7 | redis==4.5.4
8 | pandas==2.0.1
9 | werkzeug>=2
10 | flask-session>=0.3.2,<0.5
11 | requests>=2,<3
12 | msal>=1.7,<2
13 | tiktoken==0.4.0
14 | numpy==1.26.4
15 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/UserChatMessage/UserChatMessage.tsx:
--------------------------------------------------------------------------------
1 | import styles from "./UserChatMessage.module.css";
2 |
3 | interface Props {
4 | message: string;
5 | }
6 |
7 | export const UserChatMessage = ({ message }: Props) => {
8 | return (
9 |
12 | );
13 | };
14 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/UserChatMessage/UserChatMessage.tsx:
--------------------------------------------------------------------------------
1 | import styles from "./UserChatMessage.module.css";
2 |
3 | interface Props {
4 | message: string;
5 | }
6 |
7 | export const UserChatMessage = ({ message }: Props) => {
8 | return (
9 |
12 | );
13 | };
14 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/templates/display.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Back
8 | Graph API Call Result
9 | {{ result |tojson(indent=4) }}
10 |
11 |
12 |
--------------------------------------------------------------------------------
/2.recipe-adviser/azure.yaml:
--------------------------------------------------------------------------------
1 | # yaml-language-server: $schema=https://raw.githubusercontent.com/Azure/azure-dev/main/schemas/v1.0/azure.yaml.json
2 |
3 | name: azure-open-ai-recipe-adviser
4 | resourceGroup: azure-open-ai-recipe-adviser
5 | metadata:
6 | template: app-azure-open-ai-recipe-adviser@0.0.1-beta
7 | services:
8 | backend:
9 | resourceName: app-azure-open-ai-recipe-adviser
10 | project: ./app/backend
11 | language: py
12 | host: appservice
13 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | 企業内向けChatと社内文書検索
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | 目標達成アシスタント デモ
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/monitor/loganalytics.bicep:
--------------------------------------------------------------------------------
1 | param workspaceName string = ''
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | resource logAnalyticsWorkspace 'Microsoft.OperationalInsights/workspaces@2022-10-01' = {
6 | name: workspaceName
7 | location: location
8 | tags: tags
9 | }
10 |
11 |
12 | output workspaceId string = logAnalyticsWorkspace.id
13 | output workspaceName string = logAnalyticsWorkspace.name
14 |
--------------------------------------------------------------------------------
/1.call-center/app/static/js/main.js:
--------------------------------------------------------------------------------
1 | // Copyright (c) Microsoft Corporation
2 | // Licensed under the MIT license.
3 |
4 | // Popover
5 | var popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'))
6 | var popoverList = popoverTriggerList.map(function (popoverTriggerEl) {
7 | return new bootstrap.Popover(popoverTriggerEl)
8 | })
9 |
10 | var popover = new bootstrap.Popover(document.querySelector('.popover-dismiss'), {
11 | trigger: 'focus'
12 | })
--------------------------------------------------------------------------------
/5.internal-document-search/scripts/cosmosreadwriterole.json:
--------------------------------------------------------------------------------
1 | {
2 | "RoleName": "MyReadWriteRole",
3 | "Type": "CustomRole",
4 | "AssignableScopes": ["/"],
5 | "Permissions": [{
6 | "DataActions": [
7 | "Microsoft.DocumentDB/databaseAccounts/readMetadata",
8 | "Microsoft.DocumentDB/databaseAccounts/sqlDatabases/containers/items/*",
9 | "Microsoft.DocumentDB/databaseAccounts/sqlDatabases/containers/*"
10 | ]
11 | }]
12 | }
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/UserChatMessage/UserChatMessage.module.css:
--------------------------------------------------------------------------------
1 | .container {
2 | display: flex;
3 | justify-content: flex-end;
4 | margin-bottom: 20px;
5 | max-width: 80%;
6 | margin-left: auto;
7 | }
8 |
9 | .message {
10 | padding: 20px;
11 | background: #e8ebfa;
12 | border-radius: 8px;
13 | box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);
14 | outline: transparent solid 1px;
15 | }
16 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/UserChatMessage/UserChatMessage.module.css:
--------------------------------------------------------------------------------
1 | .container {
2 | display: flex;
3 | justify-content: flex-end;
4 | margin-bottom: 20px;
5 | max-width: 80%;
6 | margin-left: auto;
7 | }
8 |
9 | .message {
10 | padding: 20px;
11 | background: #e8ebfa;
12 | border-radius: 8px;
13 | box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);
14 | outline: transparent solid 1px;
15 | }
16 |
--------------------------------------------------------------------------------
/.github/CODE_OF_CONDUCT.md:
--------------------------------------------------------------------------------
1 | # Microsoft Open Source Code of Conduct
2 |
3 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
4 |
5 | Resources:
6 |
7 | - [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
8 | - [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
9 | - Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns
10 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_dropdowns.scss:
--------------------------------------------------------------------------------
1 | // Custom Dropdown Styling
2 |
3 | .dropdown {
4 | .dropdown-menu {
5 | font-size: $dropdown-font-size;
6 | .dropdown-header {
7 | @extend .text-uppercase;
8 | font-weight: 800;
9 | font-size: 0.65rem;
10 | color: $gray-500;
11 | }
12 | }
13 | }
14 |
15 | // Utility class to hide arrow from dropdown
16 |
17 | .dropdown.no-arrow {
18 | .dropdown-toggle::after {
19 | display: none;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/network/vnet.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string
3 | param addressPrefixes array
4 | param isPrivateNetworkEnabled bool
5 |
6 | resource vnet 'Microsoft.Network/virtualNetworks@2023-11-01' = if (isPrivateNetworkEnabled) {
7 | name: name
8 | location: location
9 | properties: {
10 | addressSpace: {
11 | addressPrefixes: addressPrefixes
12 | }
13 | }
14 | }
15 |
16 | output id string = vnet.id
17 | output name string = vnet.name
18 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Example/Example.tsx:
--------------------------------------------------------------------------------
1 | import styles from "./Example.module.css";
2 |
3 | interface Props {
4 | text: string;
5 | value: string;
6 | onClick: (value: string) => void;
7 | }
8 |
9 | export const Example = ({ text, value, onClick }: Props) => {
10 | return (
11 | onClick(value)}>
12 |
{text}
13 |
14 | );
15 | };
16 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/scripts/.env.template:
--------------------------------------------------------------------------------
1 | AZURE_OPENAI_SERVICE=""
2 | AZURE_OPENAI_VERSION="2023-05-15"
3 | AZURE_OPENAI_EMBEDDING_DEPLOYMENT=""
4 | AZURE_OPENAI_KEY="" # Try to connect using DefaultAzureCredential if this value is empty.
5 |
6 | REDIS_NAME="..redisenterprise.cache.azure.net"
7 | REDIS_KEY=""
8 | REDIS_INDEX_CATEGORY="task-planning"
9 | REDIS_INDEX_NAME="embedding_index"
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_dropdowns.scss:
--------------------------------------------------------------------------------
1 | // Custom Dropdown Styling
2 |
3 | .dropdown {
4 | .dropdown-menu {
5 | font-size: $dropdown-font-size;
6 | .dropdown-header {
7 | @extend .text-uppercase;
8 | font-weight: 800;
9 | font-size: 0.65rem;
10 | color: $gray-500;
11 | }
12 | }
13 | }
14 |
15 | // Utility class to hide arrow from dropdown
16 |
17 | .dropdown.no-arrow {
18 | .dropdown-toggle::after {
19 | display: none;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_dropdowns.scss:
--------------------------------------------------------------------------------
1 | // Custom Dropdown Styling
2 |
3 | .dropdown {
4 | .dropdown-menu {
5 | font-size: $dropdown-font-size;
6 | .dropdown-header {
7 | @extend .text-uppercase;
8 | font-weight: 800;
9 | font-size: 0.65rem;
10 | color: $gray-500;
11 | }
12 | }
13 | }
14 |
15 | // Utility class to hide arrow from dropdown
16 |
17 | .dropdown.no-arrow {
18 | .dropdown-toggle::after {
19 | display: none;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/pyproject.toml:
--------------------------------------------------------------------------------
1 | # ref. https://github.com/tiangolo/fastapi/blob/master/pyproject.toml
2 | [tool.ruff]
3 | select = [
4 | "E", # pycodestyle errors
5 | "W", # pycodestyle warnings
6 | "F", # pyflakes
7 | "I", # isort
8 | "C", # flake8-comprehensions
9 | "B", # flake8-bugbear
10 | ]
11 | ignore = [
12 | "E501", # line too long, handled by black
13 | "B008", # do not perform function calls in argument defaults
14 | "C901", # too complex
15 | ]
16 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/utilities/_background.scss:
--------------------------------------------------------------------------------
1 | // Background Gradient Utilities
2 |
3 | @each $color, $value in $theme-colors {
4 | .bg-gradient-#{$color} {
5 | background-color: $value;
6 | background-image: linear-gradient(180deg, $value 10%, darken($value, 15%) 100%);
7 | background-size: cover;
8 | }
9 | }
10 |
11 | // Grayscale Background Utilities
12 |
13 | @each $level, $value in $grays {
14 | .bg-gray-#{$level} {
15 | background-color: $value !important;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/utilities/_background.scss:
--------------------------------------------------------------------------------
1 | // Background Gradient Utilities
2 |
3 | @each $color, $value in $theme-colors {
4 | .bg-gradient-#{$color} {
5 | background-color: $value;
6 | background-image: linear-gradient(180deg, $value 10%, darken($value, 15%) 100%);
7 | background-size: cover;
8 | }
9 | }
10 |
11 | // Grayscale Background Utilities
12 |
13 | @each $level, $value in $grays {
14 | .bg-gray-#{$level} {
15 | background-color: $value !important;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from "vite";
2 | import react from "@vitejs/plugin-react";
3 |
4 | // https://vitejs.dev/config/
5 | export default defineConfig({
6 | plugins: [react()],
7 | build: {
8 | outDir: "../backend/static",
9 | emptyOutDir: true,
10 | sourcemap: true
11 | },
12 | server: {
13 | proxy: {
14 | "/ask": "http://localhost:5000",
15 | "/chat": "http://localhost:5000"
16 | }
17 | }
18 | });
19 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/utilities/_background.scss:
--------------------------------------------------------------------------------
1 | // Background Gradient Utilities
2 |
3 | @each $color, $value in $theme-colors {
4 | .bg-gradient-#{$color} {
5 | background-color: $value;
6 | background-image: linear-gradient(180deg, $value 10%, darken($value, 15%) 100%);
7 | background-size: cover;
8 | }
9 | }
10 |
11 | // Grayscale Background Utilities
12 |
13 | @each $level, $value in $grays {
14 | .bg-gray-#{$level} {
15 | background-color: $value !important;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/network/pip.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string
3 | param isPrivateNetworkEnabled bool
4 |
5 | resource publicIP 'Microsoft.Network/publicIPAddresses@2023-11-01' = if (isPrivateNetworkEnabled) {
6 | name: name
7 | location: location
8 | sku: {
9 | name: 'Standard'
10 | tier: 'Regional'
11 | }
12 | properties: {
13 | publicIPAllocationMethod: 'Static'
14 | }
15 | }
16 |
17 | output publicIPId string = publicIP.id
18 | // output publicIPAddress string = publicIP.properties.ipAddress
19 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/index.css:
--------------------------------------------------------------------------------
1 | * {
2 | box-sizing: border-box;
3 | }
4 |
5 | html,
6 | body {
7 | height: 100%;
8 | margin: 0;
9 | padding: 0;
10 | }
11 |
12 | html {
13 | background: #f2f2f2;
14 |
15 | font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
16 | sans-serif;
17 | -webkit-font-smoothing: antialiased;
18 | -moz-osx-font-smoothing: grayscale;
19 | }
20 |
21 | #root {
22 | height: 100%;
23 | }
24 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/index.css:
--------------------------------------------------------------------------------
1 | * {
2 | box-sizing: border-box;
3 | }
4 |
5 | html,
6 | body {
7 | height: 100%;
8 | margin: 0;
9 | padding: 0;
10 | }
11 |
12 | html {
13 | background: #f2f2f2;
14 |
15 | font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
16 | sans-serif;
17 | -webkit-font-smoothing: antialiased;
18 | -moz-osx-font-smoothing: grayscale;
19 | }
20 |
21 | #root {
22 | height: 100%;
23 | }
24 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/infra/core/host/appserviceplan.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param kind string = ''
6 | param reserved bool = true
7 | param sku object
8 |
9 | resource appServicePlan 'Microsoft.Web/serverfarms@2022-03-01' = {
10 | name: name
11 | location: location
12 | tags: tags
13 | sku: sku
14 | kind: kind
15 | properties: {
16 | reserved: reserved
17 | }
18 | }
19 |
20 | output id string = appServicePlan.id
21 | output name string = appServicePlan.name
22 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/host/appserviceplan.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param kind string = ''
6 | param reserved bool = true
7 | param sku object
8 |
9 | resource appServicePlan 'Microsoft.Web/serverfarms@2022-09-01' = {
10 | name: name
11 | location: location
12 | tags: tags
13 | sku: sku
14 | kind: kind
15 | properties: {
16 | reserved: reserved
17 | }
18 | }
19 |
20 | output id string = appServicePlan.id
21 | output name string = appServicePlan.name
22 |
--------------------------------------------------------------------------------
/2.recipe-adviser/infra/core/host/appServicePlan.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param kind string = ''
6 | param reserved bool = true
7 | param sku string
8 |
9 | resource appServicePlan 'Microsoft.Web/serverfarms@2022-03-01' = {
10 | name: name
11 | location: location
12 | tags: tags
13 | sku: {
14 | name: sku
15 | }
16 | kind: kind
17 | properties: {
18 | reserved: reserved
19 | }
20 | }
21 |
22 | output id string = appServicePlan.id
23 | output name string = appServicePlan.name
24 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from "vite";
2 | import react from "@vitejs/plugin-react";
3 |
4 | // https://vitejs.dev/config/
5 | export default defineConfig({
6 | plugins: [react()],
7 | build: {
8 | outDir: "../backend/static",
9 | emptyOutDir: true,
10 | sourcemap: true
11 | },
12 | server: {
13 | proxy: {
14 | "/ask": "http://localhost:5000",
15 | "/chat": "http://localhost:5000",
16 | "/logout": "http://localhost:5000"
17 | }
18 | }
19 | });
20 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/monitor/loganalytics.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | resource logAnalytics 'Microsoft.OperationalInsights/workspaces@2021-12-01-preview' = {
6 | name: name
7 | location: location
8 | tags: tags
9 | properties: any({
10 | retentionInDays: 30
11 | features: {
12 | searchVersion: 1
13 | }
14 | sku: {
15 | name: 'PerGB2018'
16 | }
17 | })
18 | }
19 |
20 | output id string = logAnalytics.id
21 | output name string = logAnalytics.name
22 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/templates/login.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Microsoft Identity Python Web App
8 |
9 | Sign In
10 |
11 | {% if config.get("B2C_RESET_PASSWORD_AUTHORITY") %}
12 | Reset Password
13 | {% endif %}
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_charts.scss:
--------------------------------------------------------------------------------
1 | // Area Chart
2 | .chart-area {
3 | position: relative;
4 | height: 10rem;
5 | width: 100%;
6 | @include media-breakpoint-up(md) {
7 | height: 20rem;
8 | }
9 | }
10 |
11 | // Bar Chart
12 | .chart-bar {
13 | position: relative;
14 | height: 10rem;
15 | width: 100%;
16 | @include media-breakpoint-up(md) {
17 | height: 20rem;
18 | }
19 | }
20 |
21 | // Pie Chart
22 | .chart-pie {
23 | position: relative;
24 | height: 15rem;
25 | width: 100%;
26 | @include media-breakpoint-up(md) {
27 | height: calc(20rem - 43px) !important;
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/SettingsButton/SettingsButton.tsx:
--------------------------------------------------------------------------------
1 | import { Text } from "@fluentui/react";
2 | import { Settings24Regular } from "@fluentui/react-icons";
3 |
4 | import styles from "./SettingsButton.module.css";
5 |
6 | interface Props {
7 | className?: string;
8 | onClick: () => void;
9 | }
10 |
11 | export const SettingsButton = ({ className, onClick }: Props) => {
12 | return (
13 |
14 |
15 | {"設定"}
16 |
17 | );
18 | };
19 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/sb-admin-2.scss:
--------------------------------------------------------------------------------
1 | // Import Custom SB Admin 2 Variables (Overrides Default Bootstrap Variables)
2 | @import "variables.scss";
3 |
4 | // Import Bootstrap
5 | @import "../vendor/bootstrap/scss/bootstrap.scss";
6 |
7 | // Import Custom SB Admin 2 Mixins and Components
8 | @import "mixins.scss";
9 | @import "global.scss";
10 | @import "utilities.scss";
11 |
12 | // Custom Components
13 | @import "dropdowns.scss";
14 | @import "navs.scss";
15 | @import "buttons.scss";
16 | @import "cards.scss";
17 | @import "charts.scss";
18 | @import "login.scss";
19 | @import "error.scss";
20 | @import "footer.scss";
21 |
--------------------------------------------------------------------------------
/4.company-research/infra/core/host/appserviceplan.bicep:
--------------------------------------------------------------------------------
1 | // Copyright (c) Microsoft Corporation.
2 | // Licensed under the MIT license.
3 | param name string
4 | param location string = resourceGroup().location
5 | param tags object = {}
6 |
7 | param kind string = ''
8 | param reserved bool = true
9 | param sku object
10 |
11 | resource appServicePlan 'Microsoft.Web/serverfarms@2022-03-01' = {
12 | name: name
13 | location: location
14 | tags: tags
15 | sku: sku
16 | kind: kind
17 | properties: {
18 | reserved: reserved
19 | }
20 | }
21 |
22 | output id string = appServicePlan.id
23 | output name string = appServicePlan.name
24 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_charts.scss:
--------------------------------------------------------------------------------
1 | // Area Chart
2 | .chart-area {
3 | position: relative;
4 | height: 10rem;
5 | width: 100%;
6 | @include media-breakpoint-up(md) {
7 | height: 20rem;
8 | }
9 | }
10 |
11 | // Bar Chart
12 | .chart-bar {
13 | position: relative;
14 | height: 10rem;
15 | width: 100%;
16 | @include media-breakpoint-up(md) {
17 | height: 20rem;
18 | }
19 | }
20 |
21 | // Pie Chart
22 | .chart-pie {
23 | position: relative;
24 | height: 15rem;
25 | width: 100%;
26 | @include media-breakpoint-up(md) {
27 | height: calc(20rem - 43px) !important;
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/SettingsButton/SettingsButton.tsx:
--------------------------------------------------------------------------------
1 | import { Text } from "@fluentui/react";
2 | import { Settings24Regular } from "@fluentui/react-icons";
3 |
4 | import styles from "./SettingsButton.module.css";
5 |
6 | interface Props {
7 | className?: string;
8 | onClick: () => void;
9 | }
10 |
11 | export const SettingsButton = ({ className, onClick }: Props) => {
12 | return (
13 |
14 |
15 | {"Developer settings"}
16 |
17 | );
18 | };
19 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/SupportingContent/SupportingContentParser.ts:
--------------------------------------------------------------------------------
1 | type ParsedSupportingContentItem = {
2 | title: string;
3 | content: string;
4 | };
5 |
6 | export function parseSupportingContentItem(item: string): ParsedSupportingContentItem {
7 | // Assumes the item starts with the file name followed by : and the content.
8 | // Example: "sdp_corporate.pdf: this is the content that follows".
9 | const parts = item.split(": ");
10 | const title = parts[0];
11 | const content = parts.slice(1).join(": ");
12 |
13 | return {
14 | title,
15 | content
16 | };
17 | }
18 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_charts.scss:
--------------------------------------------------------------------------------
1 | // Area Chart
2 | .chart-area {
3 | position: relative;
4 | height: 10rem;
5 | width: 100%;
6 | @include media-breakpoint-up(md) {
7 | height: 20rem;
8 | }
9 | }
10 |
11 | // Bar Chart
12 | .chart-bar {
13 | position: relative;
14 | height: 10rem;
15 | width: 100%;
16 | @include media-breakpoint-up(md) {
17 | height: 20rem;
18 | }
19 | }
20 |
21 | // Pie Chart
22 | .chart-pie {
23 | position: relative;
24 | height: 15rem;
25 | width: 100%;
26 | @include media-breakpoint-up(md) {
27 | height: calc(20rem - 43px) !important;
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/SupportingContent/SupportingContentParser.ts:
--------------------------------------------------------------------------------
1 | type ParsedSupportingContentItem = {
2 | title: string;
3 | content: string;
4 | };
5 |
6 | export function parseSupportingContentItem(item: string): ParsedSupportingContentItem {
7 | // Assumes the item starts with the file name followed by : and the content.
8 | // Example: "sdp_corporate.pdf: this is the content that follows".
9 | const parts = item.split(": ");
10 | const title = parts[0];
11 | const content = parts.slice(1).join(": ");
12 |
13 | return {
14 | title,
15 | content
16 | };
17 | }
18 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/sb-admin-2.scss:
--------------------------------------------------------------------------------
1 | // Import Custom SB Admin 2 Variables (Overrides Default Bootstrap Variables)
2 | @import "variables.scss";
3 |
4 | // Import Bootstrap
5 | @import "../vendor/bootstrap/scss/bootstrap.scss";
6 |
7 | // Import Custom SB Admin 2 Mixins and Components
8 | @import "mixins.scss";
9 | @import "global.scss";
10 | @import "utilities.scss";
11 |
12 | // Custom Components
13 | @import "dropdowns.scss";
14 | @import "navs.scss";
15 | @import "buttons.scss";
16 | @import "cards.scss";
17 | @import "charts.scss";
18 | @import "login.scss";
19 | @import "error.scss";
20 | @import "footer.scss";
21 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/infra/core/security/role.bicep:
--------------------------------------------------------------------------------
1 | param principalId string
2 |
3 | @allowed([
4 | 'Device'
5 | 'ForeignGroup'
6 | 'Group'
7 | 'ServicePrincipal'
8 | 'User'
9 | ])
10 | param principalType string = 'ServicePrincipal'
11 | param roleDefinitionId string
12 |
13 | resource role 'Microsoft.Authorization/roleAssignments@2022-04-01' = {
14 | name: guid(subscription().id, resourceGroup().id, principalId, roleDefinitionId)
15 | properties: {
16 | principalId: principalId
17 | principalType: principalType
18 | roleDefinitionId: resourceId('Microsoft.Authorization/roleDefinitions', roleDefinitionId)
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/security/role.bicep:
--------------------------------------------------------------------------------
1 | param principalId string
2 |
3 | @allowed([
4 | 'Device'
5 | 'ForeignGroup'
6 | 'Group'
7 | 'ServicePrincipal'
8 | 'User'
9 | ])
10 | param principalType string = 'ServicePrincipal'
11 | param roleDefinitionId string
12 |
13 | resource role 'Microsoft.Authorization/roleAssignments@2022-04-01' = {
14 | name: guid(subscription().id, resourceGroup().id, principalId, roleDefinitionId)
15 | properties: {
16 | principalId: principalId
17 | principalType: principalType
18 | roleDefinitionId: resourceId('Microsoft.Authorization/roleDefinitions', roleDefinitionId)
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/sb-admin-2.scss:
--------------------------------------------------------------------------------
1 | // Import Custom SB Admin 2 Variables (Overrides Default Bootstrap Variables)
2 | @import "variables.scss";
3 |
4 | // Import Bootstrap
5 | @import "../vendor/bootstrap/scss/bootstrap.scss";
6 |
7 | // Import Custom SB Admin 2 Mixins and Components
8 | @import "mixins.scss";
9 | @import "global.scss";
10 | @import "utilities.scss";
11 |
12 | // Custom Components
13 | @import "dropdowns.scss";
14 | @import "navs.scss";
15 | @import "buttons.scss";
16 | @import "cards.scss";
17 | @import "charts.scss";
18 | @import "login.scss";
19 | @import "error.scss";
20 | @import "footer.scss";
21 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/security/role.bicep:
--------------------------------------------------------------------------------
1 | param principalId string
2 |
3 | @allowed([
4 | 'Device'
5 | 'ForeignGroup'
6 | 'Group'
7 | 'ServicePrincipal'
8 | 'User'
9 | ])
10 | param principalType string = 'ServicePrincipal'
11 | param roleDefinitionId string
12 |
13 | resource role 'Microsoft.Authorization/roleAssignments@2022-04-01' = {
14 | name: guid(subscription().id, resourceGroup().id, principalId, roleDefinitionId)
15 | properties: {
16 | principalId: principalId
17 | principalType: principalType
18 | roleDefinitionId: resourceId('Microsoft.Authorization/roleDefinitions', roleDefinitionId)
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "ESNext",
4 | "useDefineForClassFields": true,
5 | "lib": ["DOM", "DOM.Iterable", "ESNext"],
6 | "allowJs": false,
7 | "skipLibCheck": true,
8 | "esModuleInterop": false,
9 | "allowSyntheticDefaultImports": true,
10 | "strict": true,
11 | "forceConsistentCasingInFileNames": true,
12 | "module": "ESNext",
13 | "moduleResolution": "Node",
14 | "resolveJsonModule": true,
15 | "isolatedModules": true,
16 | "noEmit": true,
17 | "jsx": "react-jsx",
18 | "types": ["vite/client"]
19 | },
20 | "include": ["src"]
21 | }
22 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "ESNext",
4 | "useDefineForClassFields": true,
5 | "lib": ["DOM", "DOM.Iterable", "ESNext"],
6 | "allowJs": false,
7 | "skipLibCheck": true,
8 | "esModuleInterop": false,
9 | "allowSyntheticDefaultImports": true,
10 | "strict": true,
11 | "forceConsistentCasingInFileNames": true,
12 | "module": "ESNext",
13 | "moduleResolution": "Node",
14 | "resolveJsonModule": true,
15 | "isolatedModules": true,
16 | "noEmit": true,
17 | "jsx": "react-jsx",
18 | "types": ["vite/client"]
19 | },
20 | "include": ["src"]
21 | }
22 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/security/keyvault-access.bicep:
--------------------------------------------------------------------------------
1 | param name string = 'add'
2 |
3 | param keyVaultName string
4 | param permissions object = { secrets: [ 'get', 'list' ] }
5 | param principalId string
6 |
7 | resource keyVaultAccessPolicies 'Microsoft.KeyVault/vaults/accessPolicies@2022-07-01' = {
8 | parent: keyVault
9 | name: name
10 | properties: {
11 | accessPolicies: [ {
12 | objectId: principalId
13 | tenantId: subscription().tenantId
14 | permissions: permissions
15 | } ]
16 | }
17 | }
18 |
19 | resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' existing = {
20 | name: keyVaultName
21 | }
22 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/monitor/applicationinsights.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 | param workspaceId string
5 |
6 | resource applicationInsights 'Microsoft.Insights/components@2020-02-02' = {
7 | name: name
8 | location: location
9 | tags: tags
10 | kind: 'web'
11 | properties: {
12 | Application_Type: 'web'
13 | WorkspaceResourceId: workspaceId
14 | }
15 | }
16 |
17 | output connectionString string = applicationInsights.properties.ConnectionString
18 | output instrumentationKey string = applicationInsights.properties.InstrumentationKey
19 | output name string = applicationInsights.name
20 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/ClearChatButton/ClearChatButton.tsx:
--------------------------------------------------------------------------------
1 | import { Text } from "@fluentui/react";
2 | import { Delete24Regular } from "@fluentui/react-icons";
3 |
4 | import styles from "./ClearChatButton.module.css";
5 |
6 | interface Props {
7 | className?: string;
8 | onClick: () => void;
9 | disabled?: boolean;
10 | }
11 |
12 | export const ClearChatButton = ({ className, disabled, onClick }: Props) => {
13 | return (
14 |
15 |
16 | {"消去"}
17 |
18 | );
19 | };
20 |
--------------------------------------------------------------------------------
/pyproject.toml:
--------------------------------------------------------------------------------
1 | [tool.poetry]
2 | name = "jp-azureopenai-samples"
3 | version = "0.0.0"
4 | description = "Azure OpenAI Samples Japan"
5 | authors = ["Microsoft Corporation."]
6 | license = "MIT"
7 | readme = "README.md"
8 |
9 | [tool.poetry.dependencies]
10 | python = "^3.10"
11 |
12 |
13 | [tool.poetry.group.dev.dependencies]
14 | ruff = "^0.0.284"
15 |
16 | [build-system]
17 | requires = ["poetry-core"]
18 | build-backend = "poetry.core.masonry.api"
19 |
20 | [tool.ruff]
21 | ignore = [
22 | "E501",
23 | "E722",
24 | ]
25 |
26 | [tool.ruff.per-file-ignores]
27 | "5.internal-document-search/scripts/prepdocs.py" = [
28 | "E701",
29 | "E741",
30 | "F403",
31 | "F405",
32 | ]
33 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/QuestionInput/QuestionInput.module.css:
--------------------------------------------------------------------------------
1 | .questionInputContainer {
2 | border-radius: 8px;
3 | box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);
4 | height: 90px;
5 | width: 100%;
6 | padding: 15px;
7 | background: white;
8 | }
9 |
10 | .questionInputTextArea {
11 | width: 100%;
12 | line-height: 40px;
13 | }
14 |
15 | .questionInputButtonsContainer {
16 | display: flex;
17 | flex-direction: column;
18 | justify-content: flex-end;
19 | }
20 |
21 | .questionInputSendButton {
22 | cursor: pointer;
23 | }
24 |
25 | .questionInputSendButtonDisabled {
26 | opacity: 0.4;
27 | }
28 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/ClearChatButton/ClearChatButton.tsx:
--------------------------------------------------------------------------------
1 | import { Text } from "@fluentui/react";
2 | import { Delete24Regular } from "@fluentui/react-icons";
3 |
4 | import styles from "./ClearChatButton.module.css";
5 |
6 | interface Props {
7 | className?: string;
8 | onClick: () => void;
9 | disabled?: boolean;
10 | }
11 |
12 | export const ClearChatButton = ({ className, disabled, onClick }: Props) => {
13 | return (
14 |
15 |
16 | {"Clear chat"}
17 |
18 | );
19 | };
20 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/azure.yaml:
--------------------------------------------------------------------------------
1 | # yaml-language-server: $schema=https://raw.githubusercontent.com/Azure/azure-dev/main/schemas/v1.0/azure.yaml.json
2 |
3 | name: azure-search-openai-demo
4 | metadata:
5 | template: azure-search-openai-demo@0.0.2-beta
6 | services:
7 | backend:
8 | project: ./app/backend
9 | language: py
10 | host: appservice
11 | hooks:
12 | predeploy:
13 | windows:
14 | shell: pwsh
15 | run: cd ./app/frontend;npm install;npm run build
16 | interactive: true
17 | continueOnError: false
18 | posix:
19 | shell: sh
20 | run: cd ./app/frontend;npm install;npm run build
21 | interactive: true
22 | continueOnError: false
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/QuestionInput/QuestionInput.module.css:
--------------------------------------------------------------------------------
1 | .questionInputContainer {
2 | border-radius: 8px;
3 | box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);
4 | height: 90px;
5 | width: 100%;
6 | padding: 15px;
7 | background: white;
8 | }
9 |
10 | .questionInputTextArea {
11 | width: 100%;
12 | font-size: 32pt;
13 | line-height: 40px;
14 | }
15 |
16 | .questionInputButtonsContainer {
17 | display: flex;
18 | flex-direction: column;
19 | justify-content: flex-end;
20 | }
21 |
22 | .questionInputSendButton {
23 | cursor: pointer;
24 | }
25 |
26 | .questionInputSendButtonDisabled {
27 | opacity: 0.4;
28 | }
29 |
--------------------------------------------------------------------------------
/4.company-research/infra/core/security/role.bicep:
--------------------------------------------------------------------------------
1 | // Copyright (c) Microsoft Corporation.
2 | // Licensed under the MIT license.
3 | param principalId string
4 |
5 | @allowed([
6 | 'Device'
7 | 'ForeignGroup'
8 | 'Group'
9 | 'ServicePrincipal'
10 | 'User'
11 | ])
12 | param principalType string = 'ServicePrincipal'
13 | param roleDefinitionId string
14 |
15 | resource role 'Microsoft.Authorization/roleAssignments@2022-04-01' = {
16 | name: guid(subscription().id, resourceGroup().id, principalId, roleDefinitionId)
17 | properties: {
18 | principalId: principalId
19 | principalType: principalType
20 | roleDefinitionId: resourceId('Microsoft.Authorization/roleDefinitions', roleDefinitionId)
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/5.internal-document-search/.devcontainer/devcontainer.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "internal document search",
3 | "image": "mcr.microsoft.com/devcontainers/python:1-3.11-bullseye",
4 | "features": {
5 | "ghcr.io/devcontainers/features/azure-cli:1": {},
6 | "ghcr.io/devcontainers/features/node:1": {},
7 | "ghcr.io/devcontainers/features/powershell:1": {},
8 | "ghcr.io/azure/azure-dev/azd:0": {}
9 | },
10 | "customizations": {
11 | "vscode": {
12 | "extensions": [
13 | "ms-azuretools.vscode-bicep",
14 | "ms-python.python",
15 | "GitHub.copilot",
16 | "GitHub.copilot-chat"
17 | ]
18 | }
19 | }
20 | }
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/Example/Example.tsx:
--------------------------------------------------------------------------------
1 | import styles from "./Example.module.css";
2 |
3 | interface Props {
4 | text: string;
5 | value: string;
6 | search: number;
7 | image: string;
8 | onClick: (value: string, search: number) => void;
9 | }
10 |
11 | export const Example = ({ text, value, image, search, onClick }: Props) => {
12 | return (
13 | onClick(value, search)}>
14 |
15 | サンプルシナリオ:
16 |
17 | {text}
18 |
19 |

20 |
21 | );
22 | };
23 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/main.parameters.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
3 | "contentVersion": "1.0.0.0",
4 | "parameters": {
5 | "environmentName": {
6 | "value": "${AZURE_ENV_NAME}"
7 | },
8 | "location": {
9 | "value": "${AZURE_LOCATION}"
10 | },
11 |
12 | "corsOriginUrl": {
13 | "value": "*"
14 | },
15 | "audienceAppId": {
16 | "value": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
17 | },
18 | "scopeName": {
19 | "value": "chat"
20 | },
21 | "tenantId": {
22 | "value": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
23 | },
24 | "aoaiCapacity": {
25 | "value": 30
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/SupportingContent/SupportingContent.module.css:
--------------------------------------------------------------------------------
1 | .supportingContentNavList {
2 | list-style: none;
3 | padding-left: 5px;
4 | display: flex;
5 | flex-direction: column;
6 | gap: 10px;
7 | }
8 |
9 | .supportingContentItem {
10 | word-break: break-word;
11 | background: rgb(249, 249, 249);
12 | border-radius: 8px;
13 | box-shadow: rgb(0 0 0 / 5%) 0px 0px 0px 1px, rgb(0 0 0 / 10%) 0px 2px 3px 0px;
14 | outline: transparent solid 1px;
15 |
16 | display: flex;
17 | flex-direction: column;
18 | padding: 20px;
19 | }
20 |
21 | .supportingContentItemHeader {
22 | margin: 0;
23 | }
24 |
25 | .supportingContentItemText {
26 | margin-bottom: 0;
27 | font-weight: 300;
28 | }
29 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/SupportingContent/SupportingContent.module.css:
--------------------------------------------------------------------------------
1 | .supportingContentNavList {
2 | list-style: none;
3 | padding-left: 5px;
4 | display: flex;
5 | flex-direction: column;
6 | gap: 10px;
7 | }
8 |
9 | .supportingContentItem {
10 | word-break: break-word;
11 | background: rgb(249, 249, 249);
12 | border-radius: 8px;
13 | box-shadow: rgb(0 0 0 / 5%) 0px 0px 0px 1px, rgb(0 0 0 / 10%) 0px 2px 3px 0px;
14 | outline: transparent solid 1px;
15 |
16 | display: flex;
17 | flex-direction: column;
18 | padding: 20px;
19 | }
20 |
21 | .supportingContentItemHeader {
22 | margin: 0;
23 | }
24 |
25 | .supportingContentItemText {
26 | margin-bottom: 0;
27 | font-weight: 300;
28 | }
29 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/templates/index_org.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Microsoft Identity Python Web App
8 | Welcome {{ user.get("name") }}!
9 |
10 | {% if config.get("ENDPOINT") %}
11 | Call Microsoft Graph API
12 | {% endif %}
13 |
14 | {% if config.get("B2C_PROFILE_AUTHORITY") %}
15 | Edit Profile
16 | {% endif %}
17 |
18 | Logout
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/network/nsg.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string
3 | param isPrivateNetworkEnabled bool
4 |
5 | resource nsg 'Microsoft.Network/networkSecurityGroups@2023-11-01' = if (isPrivateNetworkEnabled) {
6 | name: name
7 | location: location
8 | properties: {
9 | securityRules: [
10 | {
11 | name: 'default-allow-3389'
12 | properties: {
13 | priority: 1000
14 | access: 'Allow'
15 | direction: 'Inbound'
16 | destinationPortRange: '3389'
17 | protocol: 'Tcp'
18 | sourcePortRange: '*'
19 | sourceAddressPrefix: '*'
20 | destinationAddressPrefix: '*'
21 | }
22 | }
23 | ]
24 | }
25 | }
26 |
27 | output id string = nsg.id
28 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/security/keyvault.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param principalId string = ''
6 |
7 | resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = {
8 | name: name
9 | location: location
10 | tags: tags
11 | properties: {
12 | tenantId: subscription().tenantId
13 | sku: { family: 'A', name: 'standard' }
14 | accessPolicies: !empty(principalId) ? [
15 | {
16 | objectId: principalId
17 | permissions: { secrets: [ 'get', 'list' ] }
18 | tenantId: subscription().tenantId
19 | }
20 | ] : []
21 | }
22 | }
23 |
24 | output endpoint string = keyVault.properties.vaultUri
25 | output name string = keyVault.name
26 |
--------------------------------------------------------------------------------
/2.recipe-adviser/infra/core/security/keyVault.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tenantId string = subscription().tenantId
4 | param objectId string = ''
5 |
6 | resource keyVault 'Microsoft.KeyVault/vaults@2022-11-01' = if(objectId != '') {
7 | name: name
8 | location: location
9 | properties: {
10 | sku: {
11 | family: 'A'
12 | name: 'standard'
13 | }
14 | tenantId: tenantId
15 | accessPolicies: [
16 | {
17 | tenantId: tenantId
18 | objectId: objectId
19 | permissions: {
20 | keys: [
21 | 'list'
22 | 'get'
23 | ]
24 | secrets: [
25 | 'list'
26 | 'get'
27 | ]
28 | }
29 | }
30 | ]
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/network/subnet.bicep:
--------------------------------------------------------------------------------
1 | param existVnetName string
2 | param name string
3 | param addressPrefix string
4 | param networkSecurityGroup object = {}
5 | param delegations array = []
6 | param isPrivateNetworkEnabled bool
7 |
8 | resource existVnet 'Microsoft.Network/virtualNetworks@2023-11-01' existing = if (isPrivateNetworkEnabled) {
9 | scope: resourceGroup()
10 | name: existVnetName
11 | }
12 |
13 | resource subnet 'Microsoft.Network/virtualNetworks/subnets@2023-11-01' = if (isPrivateNetworkEnabled) {
14 | parent: existVnet
15 | name: name
16 | properties: {
17 | addressPrefix: addressPrefix
18 | networkSecurityGroup: networkSecurityGroup
19 | delegations: delegations
20 | }
21 | }
22 |
23 | output id string = subnet.id
24 | output name string = subnet.name
25 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/utilities/_animation.scss:
--------------------------------------------------------------------------------
1 | // Animation Utilities
2 |
3 | // Grow In Animation
4 |
5 | @keyframes growIn {
6 | 0% {
7 | transform: scale(0.9);
8 | opacity: 0;
9 | }
10 | 100% {
11 | transform: scale(1);
12 | opacity: 1;
13 | }
14 | }
15 |
16 | .animated--grow-in {
17 | animation-name: growIn;
18 | animation-duration: 200ms;
19 | animation-timing-function: transform cubic-bezier(.18,1.25,.4,1), opacity cubic-bezier(0,1,.4,1);
20 | }
21 |
22 | // Fade In Animation
23 |
24 | @keyframes fadeIn {
25 | 0% {
26 | opacity: 0;
27 | }
28 | 100% {
29 | opacity: 1;
30 | }
31 | }
32 |
33 | .animated--fade-in {
34 | animation-name: fadeIn;
35 | animation-duration: 200ms;
36 | animation-timing-function: opacity cubic-bezier(0,1,.4,1);
37 | }
38 |
--------------------------------------------------------------------------------
/4.company-research/.devcontainer/devcontainer.json:
--------------------------------------------------------------------------------
1 | // For format details, see https://aka.ms/devcontainer.json. For config options, see the
2 | // README at: https://github.com/devcontainers/templates/tree/main/src/python
3 | {
4 | "name": "Dev Container",
5 | // Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6 | "dockerFile": "Dockerfile",
7 |
8 | // Features to add to the dev container. More info: https://containers.dev/features.
9 | "features": {
10 | "azure-cli": "latest"
11 | },
12 |
13 | // Use 'postCreateCommand' to run commands after the container is created.
14 | "postCreateCommand": "pip3 install -r scripts/requirements.txt"
15 |
16 | // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
17 | // "remoteUser": "root"
18 | }
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/utilities/_animation.scss:
--------------------------------------------------------------------------------
1 | // Animation Utilities
2 |
3 | // Grow In Animation
4 |
5 | @keyframes growIn {
6 | 0% {
7 | transform: scale(0.9);
8 | opacity: 0;
9 | }
10 | 100% {
11 | transform: scale(1);
12 | opacity: 1;
13 | }
14 | }
15 |
16 | .animated--grow-in {
17 | animation-name: growIn;
18 | animation-duration: 200ms;
19 | animation-timing-function: transform cubic-bezier(.18,1.25,.4,1), opacity cubic-bezier(0,1,.4,1);
20 | }
21 |
22 | // Fade In Animation
23 |
24 | @keyframes fadeIn {
25 | 0% {
26 | opacity: 0;
27 | }
28 | 100% {
29 | opacity: 1;
30 | }
31 | }
32 |
33 | .animated--fade-in {
34 | animation-name: fadeIn;
35 | animation-duration: 200ms;
36 | animation-timing-function: opacity cubic-bezier(0,1,.4,1);
37 | }
38 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/utilities/_animation.scss:
--------------------------------------------------------------------------------
1 | // Animation Utilities
2 |
3 | // Grow In Animation
4 |
5 | @keyframes growIn {
6 | 0% {
7 | transform: scale(0.9);
8 | opacity: 0;
9 | }
10 | 100% {
11 | transform: scale(1);
12 | opacity: 1;
13 | }
14 | }
15 |
16 | .animated--grow-in {
17 | animation-name: growIn;
18 | animation-duration: 200ms;
19 | animation-timing-function: transform cubic-bezier(.18,1.25,.4,1), opacity cubic-bezier(0,1,.4,1);
20 | }
21 |
22 | // Fade In Animation
23 |
24 | @keyframes fadeIn {
25 | 0% {
26 | opacity: 0;
27 | }
28 | 100% {
29 | opacity: 1;
30 | }
31 | }
32 |
33 | .animated--fade-in {
34 | animation-name: fadeIn;
35 | animation-duration: 200ms;
36 | animation-timing-function: opacity cubic-bezier(0,1,.4,1);
37 | }
38 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/templates/auth_error.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | {% if config.get("B2C_RESET_PASSWORD_AUTHORITY") and "AADB2C90118" in result.get("error_description") %}
7 |
8 |
9 | {% endif %}
10 |
11 |
12 | Login Failure
13 |
14 | - {{ result.get("error") }}
15 | - {{ result.get("error_description") }}
16 |
17 |
18 | Homepage
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/2.recipe-adviser/infra/main.parameters.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
3 | "contentVersion": "1.0.0.0",
4 | "parameters": {
5 | "resourceGroupName": {
6 | "value": "azure-open-ai-recipe-adviser"
7 | },
8 | "resourceGroupLocation": {
9 | "value": "japaneast"
10 | },
11 | "openAIName": {
12 | "value": "cog-azure-open-ai-recipe-adviser"
13 | },
14 | "openAILocation": {
15 | "value": "eastus"
16 | },
17 | "openAISkuName": {
18 | "value": "S0"
19 | },
20 | "appServicePlanName": {
21 | "value": "ase-azure-open-ai-recipe-adviser"
22 | },
23 | "appServicePlanSkuName": {
24 | "value": "S1"
25 | },
26 | "appServiceName": {
27 | "value": "app-azure-open-ai-recipe-adviser"
28 | }
29 | }
30 | }
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "frontend",
3 | "private": true,
4 | "version": "0.0.0",
5 | "type": "module",
6 | "scripts": {
7 | "dev": "vite",
8 | "build": "tsc && vite build",
9 | "watch": "tsc && vite build --watch"
10 | },
11 | "dependencies": {
12 | "@fluentui/react": "^8.105.3",
13 | "@fluentui/react-icons": "^2.0.195",
14 | "@react-spring/web": "^9.7.1",
15 | "dompurify": "^3.0.1",
16 | "react": "^18.2.0",
17 | "react-dom": "^18.2.0",
18 | "react-router-dom": "^6.8.1"
19 | },
20 | "devDependencies": {
21 | "@types/dompurify": "^2.4.0",
22 | "@types/react": "^18.0.27",
23 | "@types/react-dom": "^18.0.10",
24 | "@vitejs/plugin-react": "^3.1.0",
25 | "prettier": "^2.8.3",
26 | "typescript": "^4.9.3",
27 | "vite": "^4.5.9"
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/network/nic.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string
3 | param subnetId string
4 | param publicIPId string
5 | param nsgId string
6 | param isPrivateNetworkEnabled bool
7 |
8 | resource networkInterface 'Microsoft.Network/networkInterfaces@2023-11-01' = if (isPrivateNetworkEnabled) {
9 | name: name
10 | location: location
11 | properties: {
12 | networkSecurityGroup: {
13 | id: nsgId
14 | }
15 | ipConfigurations: [
16 | {
17 | name: 'ipconfig'
18 | properties: {
19 | subnet: {
20 | id: subnetId
21 | }
22 | privateIPAllocationMethod: 'Dynamic'
23 | publicIPAddress: {
24 | id: publicIPId
25 | }
26 | }
27 | }
28 | ]
29 | }
30 | }
31 |
32 | output nicId string = networkInterface.?id
33 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "frontend",
3 | "private": true,
4 | "version": "0.0.0",
5 | "type": "module",
6 | "scripts": {
7 | "dev": "vite",
8 | "build": "tsc && vite build",
9 | "watch": "tsc && vite build --watch"
10 | },
11 | "dependencies": {
12 | "@fluentui/react": "^8.105.3",
13 | "@fluentui/react-icons": "^2.0.195",
14 | "@react-spring/web": "^9.7.1",
15 | "dompurify": "^3.2.4",
16 | "react": "^18.2.0",
17 | "react-dom": "^18.2.0",
18 | "react-router-dom": "^6.8.1"
19 | },
20 | "devDependencies": {
21 | "@types/dompurify": "^2.4.0",
22 | "@types/react": "^18.0.27",
23 | "@types/react-dom": "^18.0.10",
24 | "@vitejs/plugin-react": "^3.1.0",
25 | "prettier": "^2.8.3",
26 | "typescript": "^4.9.3",
27 | "vite": "^4.5.14"
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/4.company-research/scripts/.env.template:
--------------------------------------------------------------------------------
1 | # Azure Open AI
2 | AZURE_OPENAI_API_TYPE="azure" # Likely not currently used in script. TODO: Consider deleting
3 | AZURE_OPENAI_SERVICE="Your resource name for Azure Open AI e.g. https://{your_resource_name}.openai.azure.com/"
4 | AZURE_OPENAI_VERSION="2023-05-15"
5 | AZURE_OPENAI_API_KEY="Your API KEY for Azure Open AI" # Likely not currently used in script. TODO: Consider deleting
6 | AZURE_OPENAI_EMBEDDING_DEPLOYMENT="Your deployed text-embedding-ada-002 based model name"
7 |
8 | # Azure Redis Enterprise (RediSearch)
9 | REDIS_NAME="Your endpoint for Redis Enterprise e.g. yourredis.southcentralus.redisenterprise.cache.azure.net"
10 | REDIS_KEY="Your KEY for Redis Enterprise"
11 | REDIS_INDEX_CATEGORY="company"
12 | REDIS_INDEX_NAME="embedding_index"
13 | REDIS_CATEGORY_COMMON="company_common"
14 | REDIS_CATEGORY_TOPICS="company_topics"
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/.env.example:
--------------------------------------------------------------------------------
1 | AZURE_OPENAI_SERVICE="your-openai-service-name"
2 | AZURE_OPENAI_API_VERSION="2023-05-15"
3 | AZURE_OPENAI_CHAT_MODEL="gpt-4"
4 | AZURE_OPENAI_CHAT_DEPLOYMENT="chat"
5 | AZURE_OPENAI_EMBEDDING_DEPLOYMENT="embedding"
6 | AZURE_OPENAI_KEY="your-api-key"
7 |
8 | # LANGCHAIN_HANDLER="langchain"
9 |
10 | REDIS_NAME="xxxxxx.southcentralus.redisenterprise.cache.azure.net"
11 | REDIS_KEY="xxxxxx"
12 | REDIS_INDEX_CATEGORY="task-planning"
13 | REDIS_INDEX_NAME="embedding_index"
14 |
15 | # BING_SUBSCRIPTION_KEY="xxxxxx"
16 | # BING_SEARCH_URL="https://api.bing.microsoft.com/v7.0/search"
17 |
18 | AZURE_STORAGE_CONNECTION_STRING="DefaultEndpointsProtocol=https;AccountName=xxxxxx;AccountKey=xxxxxx;EndpointSuffix=core.windows.net"
19 | AZURE_STORAGE_ACCOUNT="xxxxxx"
20 | AZURE_STORAGE_KEY="xxxxxx"
21 | AZURE_STORAGE_CONTAINER="content"
22 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/Answer/AnswerError.tsx:
--------------------------------------------------------------------------------
1 | import { Stack, PrimaryButton } from "@fluentui/react";
2 | import { ErrorCircle24Regular } from "@fluentui/react-icons";
3 |
4 | import styles from "./Answer.module.css";
5 |
6 | interface Props {
7 | error: string;
8 | onRetry: () => void;
9 | }
10 |
11 | export const AnswerError = ({ error, onRetry }: Props) => {
12 | return (
13 |
14 |
15 |
16 |
17 | {error}
18 |
19 |
20 |
21 |
22 | );
23 | };
24 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Answer/AnswerError.tsx:
--------------------------------------------------------------------------------
1 | import { Stack, PrimaryButton } from "@fluentui/react";
2 | import { ErrorCircle24Regular } from "@fluentui/react-icons";
3 |
4 | import styles from "./Answer.module.css";
5 |
6 | interface Props {
7 | error: string;
8 | onRetry: () => void;
9 | }
10 |
11 | export const AnswerError = ({ error, onRetry }: Props) => {
12 | return (
13 |
14 |
15 |
16 |
17 | {error}
18 |
19 |
20 |
21 |
22 | );
23 | };
24 |
--------------------------------------------------------------------------------
/.github/workflows/static-analysis.yml:
--------------------------------------------------------------------------------
1 | name: static-analysis
2 |
3 | on: push
4 |
5 | jobs:
6 | static-analysis:
7 | strategy:
8 | matrix:
9 | python-version: ["3.11"]
10 | poetry-version: ["1.4.2"]
11 | platform: [ubuntu-latest]
12 | runs-on: ${{ matrix.platform }}
13 | steps:
14 | - name: Checkout code
15 | uses: actions/checkout@v3
16 | with:
17 | fetch-depth: 0
18 | - name: Set up Python ${{ matrix.python-version }}
19 | uses: actions/setup-python@v4
20 | with:
21 | python-version: ${{ matrix.python-version }}
22 | - name: Run image
23 | uses: abatilo/actions-poetry@v2
24 | with:
25 | poetry-version: ${{ matrix.poetry-version }}
26 | - name: Run CI tests
27 | run: |
28 | poetry install
29 | poetry run ruff check .
30 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/security/keyvault-secret.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param tags object = {}
3 | param keyVaultName string
4 | param contentType string = 'string'
5 | @description('The value of the secret. Provide only derived values like blob storage access, but do not hard code any secrets in your templates')
6 | @secure()
7 | param secretValue string
8 |
9 | param enabled bool = true
10 | param exp int = 0
11 | param nbf int = 0
12 |
13 | resource keyVaultSecret 'Microsoft.KeyVault/vaults/secrets@2022-07-01' = {
14 | name: name
15 | tags: tags
16 | parent: keyVault
17 | properties: {
18 | attributes: {
19 | enabled: enabled
20 | exp: exp
21 | nbf: nbf
22 | }
23 | contentType: contentType
24 | value: secretValue
25 | }
26 | }
27 |
28 | resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' existing = {
29 | name: keyVaultName
30 | }
31 |
--------------------------------------------------------------------------------
/4.company-research/.devcontainer/Dockerfile:
--------------------------------------------------------------------------------
1 | # Start from a base image that includes Python
2 | FROM mcr.microsoft.com/devcontainers/python:0-3.11
3 |
4 | # Install some necessary system dependencies
5 | RUN apt-get update && apt-get install -y --no-install-recommends \
6 | wget \
7 | bzip2 \
8 | && rm -rf /var/lib/apt/lists/*
9 |
10 | # Set the Miniconda version and the path
11 | ENV MINICONDA_VERSION py38_4.8.3
12 | ENV CONDA_DIR /opt/conda
13 |
14 | # Add the conda bin directory to the path
15 | ENV PATH $CONDA_DIR/bin:$PATH
16 |
17 | # Download and install Miniconda
18 | RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh && \
19 | /bin/bash ~/miniconda.sh -b -p $CONDA_DIR && \
20 | rm ~/miniconda.sh
21 |
22 | # Create a conda environment and installs some packages
23 | RUN conda create -y -n myenv python=3.11
24 | RUN echo "source activate myenv" > ~/.bashrc
25 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/.env.template:
--------------------------------------------------------------------------------
1 | # Azure Open AI
2 | AZURE_OPENAI_API_TYPE="azure"
3 | AZURE_OPENAI_SERVICE="Your resource name for Azure Open AI e.g. https://{your_resource_name}.openai.azure.com/"
4 | AZURE_OPENAI_API_KEY="Your API KEY for Azure Open AI" # TODO: Maybe delete later, since likely not needed
5 | AZURE_OPENAI_API_VERSION="2023-05-15"
6 | AZURE_OPENAI_COMPLETION_DEPLOYMENT = "davinci"
7 | AZURE_OPENAI_CHAT_DEPLOYMENT = "chat"
8 | AZURE_OPENAI_EMBEDDING_DEPLOYMENT = "embedding"
9 |
10 | # Azure Redis Enterprise (RediSearch)
11 | REDIS_NAME="Your endpoint for Redis Enterprise e.g. yourredis.southcentralus.redisenterprise.cache.azure.net"
12 | REDIS_KEY="Your KEY for Redis Enterprise"
13 | REDIS_CATEGORY_COMMON="company_common"
14 | REDIS_CATEGORY_TOPICS="company_topics"
15 | REDIS_INDEX_NAME="embedding_index"
16 |
17 | # Microsoft Entra ID
18 | AZURE_TENANT_ID="Your Tenant ID e.g. xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_cards.scss:
--------------------------------------------------------------------------------
1 | // Custom Card Styling
2 |
3 | .card {
4 | .card-header {
5 | // Format Dropdowns in Card Headings
6 | .dropdown {
7 | line-height: 1;
8 | .dropdown-menu {
9 | line-height: 1.5;
10 | }
11 | }
12 | }
13 | // Collapsable Card Styling
14 | .card-header[data-toggle="collapse"] {
15 | text-decoration: none;
16 | position: relative;
17 | padding: 0.75rem 3.25rem 0.75rem 1.25rem;
18 | &::after {
19 | position: absolute;
20 | right: 0;
21 | top: 0;
22 | padding-right: 1.725rem;
23 | line-height: 51px;
24 | font-weight: 900;
25 | content: '\f107';
26 | font-family: 'Font Awesome 5 Free';
27 | color: $gray-400;
28 | }
29 | &.collapsed {
30 | border-radius: $card-border-radius;
31 | &::after {
32 | content: '\f105';
33 | }
34 | }
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/api/api.ts:
--------------------------------------------------------------------------------
1 | import { ChatRequest } from "./models";
2 |
3 | export async function chatApi(options: ChatRequest): Promise {
4 | const response = await fetch("/chat", {
5 | method: "POST",
6 | headers: {
7 | "Content-Type": "application/json"
8 | },
9 | body: JSON.stringify({
10 | theme: options.theme,
11 | history: options.history,
12 | search: options.search
13 | })
14 | });
15 |
16 | // const parsedResponse: AskResponse = await response.json();
17 | const parsedResponse: string = await response.text();
18 | if (response.status > 299 || !response.ok) {
19 | throw Error(response.statusText || "Unknown error");
20 | }
21 |
22 | return parsedResponse;
23 | }
24 |
25 | export function getCitationFilePath(citation: string): string {
26 | return `/content/${citation}`;
27 | }
28 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_cards.scss:
--------------------------------------------------------------------------------
1 | // Custom Card Styling
2 |
3 | .card {
4 | .card-header {
5 | // Format Dropdowns in Card Headings
6 | .dropdown {
7 | line-height: 1;
8 | .dropdown-menu {
9 | line-height: 1.5;
10 | }
11 | }
12 | }
13 | // Collapsable Card Styling
14 | .card-header[data-toggle="collapse"] {
15 | text-decoration: none;
16 | position: relative;
17 | padding: 0.75rem 3.25rem 0.75rem 1.25rem;
18 | &::after {
19 | position: absolute;
20 | right: 0;
21 | top: 0;
22 | padding-right: 1.725rem;
23 | line-height: 51px;
24 | font-weight: 900;
25 | content: '\f107';
26 | font-family: 'Font Awesome 5 Free';
27 | color: $gray-400;
28 | }
29 | &.collapsed {
30 | border-radius: $card-border-radius;
31 | &::after {
32 | content: '\f105';
33 | }
34 | }
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_cards.scss:
--------------------------------------------------------------------------------
1 | // Custom Card Styling
2 |
3 | .card {
4 | .card-header {
5 | // Format Dropdowns in Card Headings
6 | .dropdown {
7 | line-height: 1;
8 | .dropdown-menu {
9 | line-height: 1.5;
10 | }
11 | }
12 | }
13 | // Collapsable Card Styling
14 | .card-header[data-toggle="collapse"] {
15 | text-decoration: none;
16 | position: relative;
17 | padding: 0.75rem 3.25rem 0.75rem 1.25rem;
18 | &::after {
19 | position: absolute;
20 | right: 0;
21 | top: 0;
22 | padding-right: 1.725rem;
23 | line-height: 51px;
24 | font-weight: 900;
25 | content: '\f107';
26 | font-family: 'Font Awesome 5 Free';
27 | color: $gray-400;
28 | }
29 | &.collapsed {
30 | border-radius: $card-border-radius;
31 | &::after {
32 | content: '\f105';
33 | }
34 | }
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/.github/workflows/bicep-audit.yml:
--------------------------------------------------------------------------------
1 | name: Validate bicep templates
2 | on:
3 | push:
4 | branches:
5 | - main
6 | paths:
7 | - "**/*.bicep"
8 | pull_request:
9 | branches:
10 | - main
11 | paths:
12 | - "**/*.bicep"
13 | workflow_dispatch:
14 |
15 | jobs:
16 | build:
17 | runs-on: ubuntu-latest
18 | permissions:
19 | security-events: write
20 | steps:
21 | - name: Checkout
22 | uses: actions/checkout@v4
23 |
24 | - name: Run Microsoft Security DevOps Analysis
25 | uses: microsoft/security-devops-action@latest
26 | id: msdo
27 | continue-on-error: true
28 | with:
29 | tools: templateanalyzer
30 |
31 | - name: Upload alerts to Security tab
32 | uses: github/codeql-action/upload-sarif@v3
33 | if: github.repository_owner == 'Azure-Samples'
34 | with:
35 | sarif_file: ${{ steps.msdo.outputs.sarifFile }}
36 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/api/models.ts:
--------------------------------------------------------------------------------
1 | export type Step = {
2 | step_num: number;
3 | content: string;
4 | variable_name: string;
5 | value: string;
6 | };
7 |
8 | export type Prompt = {
9 | role: string;
10 | content: string;
11 | };
12 |
13 | export type ChatRequest = {
14 | theme: string;
15 | history: Prompt[];
16 | search: number;
17 | };
18 |
19 | export type ChatResponse = {
20 | answer: string;
21 | headers: string[];
22 | steps: Step[];
23 | support: string;
24 | error?: string;
25 | };
26 |
27 | export type ChatAnswer = {
28 | user: string;
29 | assistant: string;
30 | };
31 |
32 | export type Claim = {
33 | typ: string;
34 | val: string;
35 | };
36 |
37 | export type AccessToken = {
38 | access_token: string;
39 | expires_on: string;
40 | id_token: string;
41 | provider_name: string;
42 | user_claims: Claim[];
43 | user_id: string;
44 | };
45 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/assets/search.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/assets/search.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Example/Example.module.css:
--------------------------------------------------------------------------------
1 | .examplesNavList {
2 | list-style: none;
3 | padding-left: 0;
4 | display: flex;
5 | flex-wrap: wrap;
6 | gap: 10px;
7 | flex: 1;
8 | justify-content: center;
9 | }
10 |
11 | .example {
12 | word-break: break-word;
13 | background: #dbdbdb;
14 | border-radius: 8px;
15 | display: flex;
16 | flex-direction: column;
17 | padding: 20px;
18 | margin-bottom: 5px;
19 | cursor: pointer;
20 | }
21 |
22 | .example:hover {
23 | box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);
24 | outline: 2px solid rgba(115, 118, 225, 1);
25 | }
26 |
27 | .exampleText {
28 | margin: 0;
29 | font-size: 22px;
30 | width: 280px;
31 | height: 100px;
32 | }
33 |
34 | @media only screen and (max-height: 780px) {
35 | .exampleText {
36 | font-size: 20px;
37 | height: 80px;
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/SupportingContent/SupportingContent.tsx:
--------------------------------------------------------------------------------
1 | import { parseSupportingContentItem } from "./SupportingContentParser";
2 |
3 | import styles from "./SupportingContent.module.css";
4 |
5 | interface Props {
6 | supportingContent: string[];
7 | }
8 |
9 | export const SupportingContent = ({ supportingContent }: Props) => {
10 | return (
11 |
12 | {supportingContent.map((x, i) => {
13 | const parsed = parseSupportingContentItem(x);
14 |
15 | return (
16 | -
17 |
{parsed.title}
18 | {parsed.content}
19 |
20 | );
21 | })}
22 |
23 | );
24 | };
25 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Answer/AnswerLoading.tsx:
--------------------------------------------------------------------------------
1 | import { Stack } from "@fluentui/react";
2 | import { animated, useSpring } from "@react-spring/web";
3 |
4 | import styles from "./Answer.module.css";
5 | import { AnswerIcon } from "./AnswerIcon";
6 |
7 | export const AnswerLoading = () => {
8 | const animatedStyles = useSpring({
9 | from: { opacity: 0 },
10 | to: { opacity: 1 }
11 | });
12 |
13 | return (
14 |
15 |
16 |
17 |
18 |
19 | 回答生成中
20 |
21 |
22 |
23 |
24 |
25 | );
26 | };
27 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/SupportingContent/SupportingContent.tsx:
--------------------------------------------------------------------------------
1 | import { parseSupportingContentItem } from "./SupportingContentParser";
2 |
3 | import styles from "./SupportingContent.module.css";
4 |
5 | interface Props {
6 | supportingContent: string[];
7 | }
8 |
9 | export const SupportingContent = ({ supportingContent }: Props) => {
10 | return (
11 |
12 | {supportingContent.map((x, i) => {
13 | const parsed = parseSupportingContentItem(x);
14 |
15 | return (
16 | -
17 |
{parsed.title}
18 | {parsed.content}
19 |
20 | );
21 | })}
22 |
23 | );
24 | };
25 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/css/food_menu.css:
--------------------------------------------------------------------------------
1 | body {
2 | background-color: white;
3 | }
4 |
5 | .stock_table tr:hover td {
6 | background-color: LightSkyBlue;
7 | cursor: pointer;
8 | }
9 |
10 | .wait {
11 | position: absolute;
12 | top: 50%;
13 | left: 50%;
14 | transform: translate(-50%, -50%);
15 | display: none;
16 | }
17 |
18 | .floor {
19 | max-width: 100%;
20 | max-height: 100%;
21 | margin: auto;
22 | display: block;
23 | }
24 |
25 | /* ブロックのスタイル */
26 | .block {
27 | fill: rgpa(255, 255, 255, 0);
28 | stroke: rgb(127, 127, 127);
29 | stroke-width: 2;
30 | filter: drop-shadow(2px 2px 2px rgba(0, 0, 0, 0.5));
31 | }
32 |
33 | /* ブロックのテキストのスタイル */
34 | .block-text {
35 | font-size: 32px;
36 | fill: black;
37 | text-anchor: middle;
38 | dominant-baseline: middle;
39 | }
40 |
41 | /* ハイライトされたブロックのスタイル */
42 | .highlight {
43 | fill: yellow;
44 | stroke: red;
45 | stroke-width: 4;
46 | }
47 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/assets/github.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/Answer/AnswerLoading.tsx:
--------------------------------------------------------------------------------
1 | import { Stack } from "@fluentui/react";
2 | import { animated, useSpring } from "@react-spring/web";
3 |
4 | import styles from "./Answer.module.css";
5 | import { AnswerIcon } from "./AnswerIcon";
6 |
7 | export const AnswerLoading = () => {
8 | const animatedStyles = useSpring({
9 | from: { opacity: 0 },
10 | to: { opacity: 1 }
11 | });
12 |
13 | return (
14 |
15 |
16 |
17 |
18 |
19 | Generating answer
20 |
21 |
22 |
23 |
24 |
25 | );
26 | };
27 |
--------------------------------------------------------------------------------
/4.company-research/infra/main.parameters.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
3 | "contentVersion": "1.0.0.0",
4 | "parameters": {
5 | "environmentName": {
6 | "value": "${AZURE_ENV_NAME}"
7 | },
8 | "location": {
9 | "value": "${AZURE_LOCATION}"
10 | },
11 | "principalId": {
12 | "value": "${AZURE_PRINCIPAL_ID}"
13 | },
14 | "openAiServiceName": {
15 | "value": "${AZURE_OPENAI_SERVICE}"
16 | },
17 | "openAiResourceGroupName": {
18 | "value": "${AZURE_OPENAI_RESOURCE_GROUP}"
19 | },
20 | "openAiSkuName": {
21 | "value": "S0"
22 | },
23 | "storageAccountName": {
24 | "value": "${AZURE_STORAGE_ACCOUNT}"
25 | },
26 | "storageResourceGroupName": {
27 | "value": "${AZURE_STORAGE_RESOURCE_GROUP}"
28 | },
29 | "redisEnterpriseName": {
30 | "value": "${AZURE_REDIS_ENTERPRISE_NAME}"
31 | }
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/assets/github.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/index.tsx:
--------------------------------------------------------------------------------
1 | import React from "react";
2 | import ReactDOM from "react-dom/client";
3 | import { HashRouter, Routes, Route } from "react-router-dom";
4 | import { initializeIcons } from "@fluentui/react";
5 |
6 | import "./index.css";
7 |
8 | import Layout from "./pages/layout/Layout";
9 | import NoPage from "./pages/NoPage";
10 | import Chat from "./pages/chat/Chat";
11 |
12 | initializeIcons();
13 |
14 | export default function App() {
15 | return (
16 |
17 |
18 | }>
19 | } />
20 | } />
21 |
22 |
23 |
24 | );
25 | }
26 |
27 | ReactDOM.createRoot(document.getElementById("root") as HTMLElement).render(
28 |
29 |
30 |
31 | );
32 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/infra/main.parameters.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
3 | "contentVersion": "1.0.0.0",
4 | "parameters": {
5 | "environmentName": {
6 | "value": "${AZURE_ENV_NAME}"
7 | },
8 | "location": {
9 | "value": "${AZURE_LOCATION}"
10 | },
11 | "principalId": {
12 | "value": "${AZURE_PRINCIPAL_ID}"
13 | },
14 | "openAiServiceName": {
15 | "value": "${AZURE_OPENAI_SERVICE}"
16 | },
17 | "openAiResourceGroupName": {
18 | "value": "${AZURE_OPENAI_RESOURCE_GROUP}"
19 | },
20 | "openAiSkuName": {
21 | "value": "S0"
22 | },
23 | "storageAccountName": {
24 | "value": "${AZURE_STORAGE_ACCOUNT}"
25 | },
26 | "storageResourceGroupName": {
27 | "value": "${AZURE_STORAGE_RESOURCE_GROUP}"
28 | },
29 | "redisEnterpriseName": {
30 | "value": "${AZURE_REDIS_ENTERPRISE_NAME}"
31 | }
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/utilities/_text.scss:
--------------------------------------------------------------------------------
1 | // Grayscale Text Utilities
2 |
3 | .text-xs {
4 | font-size: .7rem;
5 | }
6 |
7 | .text-lg {
8 | font-size: 1.2rem;
9 | }
10 |
11 | .text-gray-100 {
12 | color: $gray-100 !important;
13 | }
14 |
15 | .text-gray-200 {
16 | color: $gray-200 !important;
17 | }
18 |
19 | .text-gray-300 {
20 | color: $gray-300 !important;
21 | }
22 |
23 | .text-gray-400 {
24 | color: $gray-400 !important;
25 | }
26 |
27 | .text-gray-500 {
28 | color: $gray-500 !important;
29 | }
30 |
31 | .text-gray-600 {
32 | color: $gray-600 !important;
33 | }
34 |
35 | .text-gray-700 {
36 | color: $gray-700 !important;
37 | }
38 |
39 | .text-gray-800 {
40 | color: $gray-800 !important;
41 | }
42 |
43 | .text-gray-900 {
44 | color: $gray-900 !important;
45 | }
46 |
47 | .icon-circle {
48 | height: 2.5rem;
49 | width: 2.5rem;
50 | border-radius: 100%;
51 | display: flex;
52 | align-items: center;
53 | justify-content: center;
54 | }
55 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/components/Example/ExampleList.tsx:
--------------------------------------------------------------------------------
1 | import { Example } from "./Example";
2 |
3 | import styles from "./Example.module.css";
4 |
5 | export type ExampleModel = {
6 | text: string;
7 | value: string;
8 | };
9 |
10 | const EXAMPLES: ExampleModel[] = [
11 | {
12 | text: "就業規則とは何ですか?",
13 | value: "就業規則とは何ですか?"
14 | },
15 | { text: "人事はどのような仕事をしますか?", value: "人事はどのような仕事をしますか?" },
16 | { text: "休暇にはどんな種類がありますか?", value: "休暇にはどんな種類がありますか?" }
17 | ];
18 |
19 | interface Props {
20 | onExampleClicked: (value: string) => void;
21 | }
22 |
23 | export const ExampleList = ({ onExampleClicked }: Props) => {
24 | return (
25 |
26 | {EXAMPLES.map((x, i) => (
27 | -
28 |
29 |
30 | ))}
31 |
32 | );
33 | };
34 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/infra/core/redis/enterprise.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param sku object = {
6 | name: 'Enterprise_E10'
7 | capacity: 2
8 | }
9 |
10 | resource redisEnterprise 'Microsoft.Cache/redisEnterprise@2021-03-01' = {
11 | name: name
12 | location: location
13 | tags: tags
14 | sku: sku
15 | properties: {
16 | minimumTlsVersion: '1.2'
17 | }
18 | }
19 |
20 | resource redisEnterpriseDatabase 'Microsoft.Cache/redisEnterprise/databases@2022-11-01-preview' = {
21 | parent: redisEnterprise
22 | name: 'default'
23 | properties: {
24 | clientProtocol: 'Encrypted'
25 | modules: [
26 | {
27 | name: 'RediSearch'
28 | }
29 | ]
30 | evictionPolicy: 'AllKeysLRU'
31 | clusteringPolicy: 'EnterpriseCluster'
32 | persistence: {
33 | aofEnabled: false
34 | rdbEnabled: false
35 | }
36 | }
37 | }
38 |
39 | output id string = redisEnterprise.id
40 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/utilities/_text.scss:
--------------------------------------------------------------------------------
1 | // Grayscale Text Utilities
2 |
3 | .text-xs {
4 | font-size: .7rem;
5 | }
6 |
7 | .text-lg {
8 | font-size: 1.2rem;
9 | }
10 |
11 | .text-gray-100 {
12 | color: $gray-100 !important;
13 | }
14 |
15 | .text-gray-200 {
16 | color: $gray-200 !important;
17 | }
18 |
19 | .text-gray-300 {
20 | color: $gray-300 !important;
21 | }
22 |
23 | .text-gray-400 {
24 | color: $gray-400 !important;
25 | }
26 |
27 | .text-gray-500 {
28 | color: $gray-500 !important;
29 | }
30 |
31 | .text-gray-600 {
32 | color: $gray-600 !important;
33 | }
34 |
35 | .text-gray-700 {
36 | color: $gray-700 !important;
37 | }
38 |
39 | .text-gray-800 {
40 | color: $gray-800 !important;
41 | }
42 |
43 | .text-gray-900 {
44 | color: $gray-900 !important;
45 | }
46 |
47 | .icon-circle {
48 | height: 2.5rem;
49 | width: 2.5rem;
50 | border-radius: 100%;
51 | display: flex;
52 | align-items: center;
53 | justify-content: center;
54 | }
55 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/utilities/_text.scss:
--------------------------------------------------------------------------------
1 | // Grayscale Text Utilities
2 |
3 | .text-xs {
4 | font-size: .7rem;
5 | }
6 |
7 | .text-lg {
8 | font-size: 1.2rem;
9 | }
10 |
11 | .text-gray-100 {
12 | color: $gray-100 !important;
13 | }
14 |
15 | .text-gray-200 {
16 | color: $gray-200 !important;
17 | }
18 |
19 | .text-gray-300 {
20 | color: $gray-300 !important;
21 | }
22 |
23 | .text-gray-400 {
24 | color: $gray-400 !important;
25 | }
26 |
27 | .text-gray-500 {
28 | color: $gray-500 !important;
29 | }
30 |
31 | .text-gray-600 {
32 | color: $gray-600 !important;
33 | }
34 |
35 | .text-gray-700 {
36 | color: $gray-700 !important;
37 | }
38 |
39 | .text-gray-800 {
40 | color: $gray-800 !important;
41 | }
42 |
43 | .text-gray-900 {
44 | color: $gray-900 !important;
45 | }
46 |
47 | .icon-circle {
48 | height: 2.5rem;
49 | width: 2.5rem;
50 | border-radius: 100%;
51 | display: flex;
52 | align-items: center;
53 | justify-content: center;
54 | }
55 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/app/web.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 | param serviceName string = 'web'
5 | param appCommandLine string = './entrypoint.sh -o ./env-config.js && pm2 serve /home/site/wwwroot --no-daemon --spa'
6 | param applicationInsightsName string = ''
7 | param appServicePlanId string
8 |
9 | module web '../core/host/appservice.bicep' = {
10 | name: '${name}-deployment'
11 | params: {
12 | name: name
13 | location: location
14 | appCommandLine: appCommandLine
15 | applicationInsightsName: applicationInsightsName
16 | appServicePlanId: appServicePlanId
17 | runtimeName: 'node'
18 | runtimeVersion: '18-lts'
19 | tags: union(tags, { 'azd-service-name': serviceName })
20 | }
21 | }
22 |
23 | output SERVICE_WEB_IDENTITY_PRINCIPAL_ID string = web.outputs.identityPrincipalId
24 | output SERVICE_WEB_NAME string = web.outputs.name
25 | output SERVICE_WEB_URI string = web.outputs.uri
26 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/Example/Example.module.css:
--------------------------------------------------------------------------------
1 | .examplesNavList {
2 | list-style: none;
3 | padding-left: 0;
4 | display: flex;
5 | flex-wrap: wrap;
6 | gap: 10px;
7 | flex: 1;
8 | justify-content: center;
9 | }
10 |
11 | .example {
12 | word-break: break-word;
13 | background: #dbdbdb;
14 | border-radius: 8px;
15 | display: flex;
16 | flex-direction: column;
17 | padding: 20px;
18 | margin-bottom: 5px;
19 | cursor: pointer;
20 | }
21 |
22 | .example:hover {
23 | box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);
24 | outline: 2px solid rgba(115, 118, 225, 1);
25 | }
26 |
27 | .exampleText {
28 | margin: 0;
29 | font-size: 22px;
30 | width: 280px;
31 | height: 100px;
32 | }
33 |
34 | .exampleImage {
35 | margin: 0;
36 | }
37 |
38 | @media only screen and (max-height: 780px) {
39 | .exampleText {
40 | font-size: 20px;
41 | height: 80px;
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/monitor/applicationinsights.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param dashboardName string
3 | param location string = resourceGroup().location
4 | param tags object = {}
5 |
6 | param logAnalyticsWorkspaceId string
7 |
8 | resource applicationInsights 'Microsoft.Insights/components@2020-02-02' = {
9 | name: name
10 | location: location
11 | tags: tags
12 | kind: 'web'
13 | properties: {
14 | Application_Type: 'web'
15 | WorkspaceResourceId: logAnalyticsWorkspaceId
16 | }
17 | }
18 |
19 | module applicationInsightsDashboard 'applicationinsights-dashboard.bicep' = {
20 | name: 'application-insights-dashboard'
21 | params: {
22 | name: dashboardName
23 | location: location
24 | applicationInsightsName: applicationInsights.name
25 | }
26 | }
27 |
28 | output connectionString string = applicationInsights.properties.ConnectionString
29 | output instrumentationKey string = applicationInsights.properties.InstrumentationKey
30 | output name string = applicationInsights.name
31 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/search/search-services.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param sku object = {
6 | name: 'standard'
7 | }
8 |
9 | param authOptions object = {}
10 | param semanticSearch string = 'disabled'
11 |
12 | resource search 'Microsoft.Search/searchServices@2023-11-01' = {
13 | name: name
14 | location: location
15 | tags: tags
16 | identity: {
17 | type: 'SystemAssigned'
18 | }
19 | properties: {
20 | authOptions: authOptions
21 | disableLocalAuth: false
22 | encryptionWithCmk: {
23 | enforcement: 'Unspecified'
24 | }
25 | hostingMode: 'default'
26 | networkRuleSet: {
27 | ipRules: []
28 | }
29 | partitionCount: 1
30 | publicNetworkAccess: 'enabled'
31 | replicaCount: 1
32 | semanticSearch: semanticSearch
33 | }
34 | sku: sku
35 | }
36 |
37 | output id string = search.id
38 | output endpoint string = 'https://${name}.search.windows.net/'
39 | output name string = search.name
40 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE.md:
--------------------------------------------------------------------------------
1 |
4 | > Please provide us with the following information:
5 | > ---------------------------------------------------------------
6 |
7 | ### This issue is for a: (mark with an `x`)
8 | ```
9 | - [ ] bug report -> please search issues before submitting
10 | - [ ] feature request
11 | - [ ] documentation issue or request
12 | - [ ] regression (a behavior that used to work and stopped in a new release)
13 | ```
14 |
15 | ### Minimal steps to reproduce
16 | >
17 |
18 | ### Any log messages given by the failure
19 | >
20 |
21 | ### Expected/desired behavior
22 | >
23 |
24 | ### OS and Version?
25 | > Windows 7, 8 or 10. Linux (which distribution). macOS (Yosemite? El Capitan? Sierra?)
26 |
27 | ### Versions
28 | >
29 |
30 | ### Mention any other details that might be useful
31 |
32 | > ---------------------------------------------------------------
33 | > Thanks! We'll be in touch soon.
34 |
--------------------------------------------------------------------------------
/4.company-research/.vscode/tasks.json:
--------------------------------------------------------------------------------
1 | {
2 | "version": "2.0.0",
3 | "tasks": [
4 | {
5 | "label": "Start App",
6 | "type": "dotenv",
7 | "targetTasks": [
8 | "Start App (Script)"
9 | ],
10 | "file": "${input:dotEnvFilePath}"
11 | },
12 | {
13 | "label": "Start App (Script)",
14 | "type": "shell",
15 | "command": "${workspaceFolder}/app/start.sh",
16 | "windows": {
17 | "command": "pwsh ${workspaceFolder}/app/start.ps1"
18 | },
19 | "presentation": {
20 | "reveal": "silent"
21 | },
22 | "options": {
23 | "cwd": "${workspaceFolder}/app"
24 | },
25 | "problemMatcher": []
26 | }
27 | ],
28 | "inputs": [
29 | {
30 | "id": "dotEnvFilePath",
31 | "type": "command",
32 | "command": "azure-dev.commands.getDotEnvFilePath"
33 | }
34 | ]
35 | }
--------------------------------------------------------------------------------
/1.call-center/app/.vscode/launch.json:
--------------------------------------------------------------------------------
1 | {
2 | "version": "0.2.0",
3 | "configurations": [
4 |
5 | {
6 | "name": "Python: Flask",
7 | "type": "python",
8 | "request": "launch",
9 | "module": "flask",
10 | "env": {
11 | "FLASK_APP": "${workspaceFolder}/app.py",
12 | "FLASK_DEBUG": "1",
13 | "STT_REGION": "",
14 | "STT_RESOURCE_ID": "/subscriptions//resourceGroups//providers/Microsoft.CognitiveServices/accounts/",
15 | "TEXT_ANALYTICS_ENDPOINT": "https://.cognitiveservices.azure.com",
16 | "AOAI_ENDPOINT": "https://.openai.azure.com",
17 | "AOAI_MODEL": "<>"
18 | },
19 | "args": [
20 | "run"
21 | ],
22 | "jinja": true,
23 | "justMyCode": true
24 | }
25 | ]
26 | }
27 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/.vscode/tasks.json:
--------------------------------------------------------------------------------
1 | {
2 | "version": "2.0.0",
3 | "tasks": [
4 | {
5 | "label": "Start App",
6 | "type": "dotenv",
7 | "targetTasks": [
8 | "Start App (Script)"
9 | ],
10 | "file": "${input:dotEnvFilePath}"
11 | },
12 | {
13 | "label": "Start App (Script)",
14 | "type": "shell",
15 | "command": "${workspaceFolder}/app/start.sh",
16 | "windows": {
17 | "command": "pwsh ${workspaceFolder}/app/start.ps1"
18 | },
19 | "presentation": {
20 | "reveal": "silent"
21 | },
22 | "options": {
23 | "cwd": "${workspaceFolder}/app"
24 | },
25 | "problemMatcher": []
26 | }
27 | ],
28 | "inputs": [
29 | {
30 | "id": "dotEnvFilePath",
31 | "type": "command",
32 | "command": "azure-dev.commands.getDotEnvFilePath"
33 | }
34 | ]
35 | }
--------------------------------------------------------------------------------
/5.internal-document-search/azure.yaml:
--------------------------------------------------------------------------------
1 | # yaml-language-server: $schema=https://raw.githubusercontent.com/Azure/azure-dev/main/schemas/v1.0/azure.yaml.json
2 |
3 | name: internal-document-search
4 | metadata:
5 | template: internal-document-search@0.0.1-beta
6 | services:
7 | backend:
8 | project: ./src/backend
9 | language: py
10 | host: appservice
11 | hooks:
12 | prepackage:
13 | windows:
14 | shell: pwsh
15 | run: cd ../frontend;npm install;npm run build
16 | interactive: true
17 | continueOnError: false
18 | posix:
19 | shell: sh
20 | run: cd ../frontend;npm install;npm run build
21 | interactive: true
22 | continueOnError: false
23 | hooks:
24 | postprovision:
25 | windows:
26 | shell: pwsh
27 | run: ./scripts/prepdocs.ps1
28 | interactive: true
29 | continueOnError: false
30 | posix:
31 | shell: sh
32 | run: ./scripts/prepdocs.sh
33 | interactive: true
34 | continueOnError: false
35 |
--------------------------------------------------------------------------------
/4.company-research/infra/core/redis/enterprise.bicep:
--------------------------------------------------------------------------------
1 | // Copyright (c) Microsoft Corporation.
2 | // Licensed under the MIT license.
3 | param name string
4 | param location string = resourceGroup().location
5 | param tags object = {}
6 |
7 | param sku object = {
8 | name: 'Enterprise_E10'
9 | capacity: 2
10 | }
11 |
12 | resource redisEnterprise 'Microsoft.Cache/redisEnterprise@2021-03-01' = {
13 | name: name
14 | location: location
15 | tags: tags
16 | sku: sku
17 | properties: {
18 | minimumTlsVersion: '1.2'
19 | }
20 | }
21 |
22 | resource redisEnterpriseDatabase 'Microsoft.Cache/redisEnterprise/databases@2022-11-01-preview' = {
23 | parent: redisEnterprise
24 | name: 'default'
25 | properties: {
26 | clientProtocol: 'Encrypted'
27 | modules: [
28 | {
29 | name: 'RediSearch'
30 | }
31 | ]
32 | evictionPolicy: 'NoEviction'
33 | clusteringPolicy: 'EnterpriseCluster'
34 | persistence: {
35 | aofEnabled: false
36 | rdbEnabled: false
37 | }
38 | }
39 | }
40 |
41 | output id string = redisEnterprise.id
42 |
--------------------------------------------------------------------------------
/5.internal-document-search/scripts/roles.ps1:
--------------------------------------------------------------------------------
1 | $output = azd env get-values
2 |
3 | foreach ($line in $output) {
4 | $name, $value = $line.Split("=")
5 | $value = $value -replace '^\"|\"$'
6 | [Environment]::SetEnvironmentVariable($name, $value)
7 | }
8 |
9 | Write-Host "Environment variables set."
10 |
11 | $roles = @(
12 | "5e0bd9bd-7b93-4f28-af87-19fc36ad61bd",
13 | "2a2b9908-6ea1-4ae2-8e65-a410df84e7d1",
14 | "ba92f5b4-2d11-453d-a403-e96b0029c9fe",
15 | "1407120a-92aa-4202-b7e9-c0e197c71c8f",
16 | "8ebe5a00-799e-43f5-93ac-243d3dce84a7"
17 | )
18 |
19 | if ([string]::IsNullOrEmpty($env:AZURE_RESOURCE_GROUP)) {
20 | $env:AZURE_RESOURCE_GROUP = "rg-$env:AZURE_ENV_NAME"
21 | azd env set AZURE_RESOURCE_GROUP $env:AZURE_RESOURCE_GROUP
22 | }
23 |
24 | foreach ($role in $roles) {
25 | az role assignment create `
26 | --role $role `
27 | --assignee-object-id $env:AZURE_PRINCIPAL_ID `
28 | --scope /subscriptions/$env:AZURE_SUBSCRIPTION_ID/resourceGroups/$env:AZURE_RESOURCE_GROUP `
29 | --assignee-principal-type User
30 | }
31 |
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/monitor/monitoring.bicep:
--------------------------------------------------------------------------------
1 | param applicationInsightsName string
2 | param workspaceName string
3 | param location string = resourceGroup().location
4 | param tags object = {}
5 |
6 | module logAnalytics 'loganalytics.bicep' = {
7 | name: 'loganalytics'
8 | params: {
9 | workspaceName: workspaceName
10 | location: location
11 | tags: tags
12 | }
13 | }
14 |
15 | module applicationInsights 'applicationinsights.bicep' = {
16 | name: 'applicationinsights'
17 | params: {
18 | name: applicationInsightsName
19 | location: location
20 | tags: tags
21 | workspaceId: logAnalytics.outputs.workspaceId
22 | }
23 | }
24 |
25 | output applicationInsightsConnectionString string = applicationInsights.outputs.connectionString
26 | output applicationInsightsInstrumentationKey string = applicationInsights.outputs.instrumentationKey
27 | output applicationInsightsName string = applicationInsights.outputs.name
28 | output logAnalyticsWorkspaceId string = logAnalytics.outputs.workspaceId
29 | output logAnalyticsWorkspaceName string = logAnalytics.outputs.workspaceName
30 |
--------------------------------------------------------------------------------
/5.internal-document-search/src/frontend/src/index.tsx:
--------------------------------------------------------------------------------
1 | import React from "react";
2 | import ReactDOM from "react-dom/client";
3 | import { HashRouter, Routes, Route } from "react-router-dom";
4 | import { initializeIcons } from "@fluentui/react";
5 |
6 | import "./index.css";
7 |
8 | import Layout from "./pages/layout/Layout";
9 | import NoPage from "./pages/NoPage";
10 | import Chat from "./pages/chat/Chat";
11 | import DocSearch from "./pages/docsearch/DocSearch";
12 |
13 | initializeIcons();
14 |
15 | export default function App() {
16 | return (
17 |
18 |
19 | }>
20 | } />
21 | } />
22 | } />
23 |
24 |
25 |
26 | );
27 | }
28 |
29 | ReactDOM.createRoot(document.getElementById("root") as HTMLElement).render(
30 |
31 |
32 |
33 | );
34 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/infra/core/search/search-services.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param sku object = {
6 | name: 'standard'
7 | }
8 |
9 | param authOptions object = {}
10 | param semanticSearch string = 'disabled'
11 |
12 | resource search 'Microsoft.Search/searchServices@2021-04-01-preview' = {
13 | name: name
14 | location: location
15 | tags: tags
16 | identity: {
17 | type: 'SystemAssigned'
18 | }
19 | properties: {
20 | authOptions: authOptions
21 | disableLocalAuth: false
22 | disabledDataExfiltrationOptions: []
23 | encryptionWithCmk: {
24 | enforcement: 'Unspecified'
25 | }
26 | hostingMode: 'default'
27 | networkRuleSet: {
28 | bypass: 'None'
29 | ipRules: []
30 | }
31 | partitionCount: 1
32 | publicNetworkAccess: 'Enabled'
33 | replicaCount: 1
34 | semanticSearch: semanticSearch
35 | }
36 | sku: sku
37 | }
38 |
39 | output id string = search.id
40 | output endpoint string = 'https://${name}.search.windows.net/'
41 | output name string = search.name
42 |
--------------------------------------------------------------------------------
/.github/workflows/5.what-if.yml:
--------------------------------------------------------------------------------
1 | name: bicep what-if
2 |
3 | on: workflow_dispatch
4 |
5 | jobs:
6 | deploy:
7 | runs-on: ubuntu-latest
8 | steps:
9 | - name: Checkout
10 | uses: actions/checkout@v3
11 |
12 | - name: Login azure
13 | uses: azure/login@v2
14 | with:
15 | creds: ${{ secrets.AZURE_CREDENTIALS }}
16 | enable-AzPSSession: true
17 |
18 | - name: what-if using Azure CLI
19 | run: |
20 | set +e
21 | results=$(az deployment sub what-if --template-file "./5.internal-document-search/infra/main.bicep" --location JapanEast -p vmLoginPassword=dummy -p resourceGroupName=rg-${{ github.run_id }} -p isPrivateNetworkEnabled=false -p environmentName=${{ github.run_id }} -p location=japaneast -p AzureOpenAIServiceRegion="8. japaneast (You can deploy only GPT-3 models)" -p useApiManagement=false 2>&1)
22 | echo "$results"
23 | # Check if "Error" is present in $results
24 | if echo "$results" | grep -i "Error"; then
25 | echo "Error found in what-if results. Exiting..."
26 | exit 1
27 | fi
28 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/navs/_global.scss:
--------------------------------------------------------------------------------
1 | // Global styles for both custom sidebar and topbar compoments
2 |
3 | .sidebar,
4 | .topbar {
5 | .nav-item {
6 | // Customize Dropdown Arrows for Navbar
7 | &.dropdown {
8 | .dropdown-toggle {
9 | &::after {
10 | width: 1rem;
11 | text-align: center;
12 | float: right;
13 | vertical-align: 0;
14 | border: 0;
15 | font-weight: 900;
16 | content: '\f105';
17 | font-family: 'Font Awesome 5 Free';
18 | }
19 | }
20 | &.show {
21 | .dropdown-toggle::after {
22 | content: '\f107';
23 | }
24 | }
25 | }
26 | // Counter for nav links and nav link image sizing
27 | .nav-link {
28 | position: relative;
29 | .badge-counter {
30 | position: absolute;
31 | transform: scale(0.7);
32 | transform-origin: top right;
33 | right: .25rem;
34 | margin-top: -.25rem;
35 | }
36 | .img-profile {
37 | height: 2rem;
38 | width: 2rem;
39 | }
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/2.recipe-adviser/infra/core/ai/cognitiveServices.bicep:
--------------------------------------------------------------------------------
1 | // create azure cognitive service & use open ai service
2 | param name string
3 | param tags object = {}
4 | param sku object = {}
5 | param location string
6 | @allowed(['Disabled', 'Enabled'])
7 | param publicNetworkAccess string
8 |
9 | resource cognitiveServices 'Microsoft.CognitiveServices/accounts@2022-12-01' = {
10 | name: name
11 | location: location
12 | tags: tags
13 | sku: sku
14 | properties: {
15 | publicNetworkAccess: publicNetworkAccess
16 | customSubDomainName: name
17 | }
18 | kind: 'OpenAI'
19 | }
20 |
21 | // deploy OpenAI text generating model
22 | param modelName string
23 | param deployVersion string
24 | @allowed(['Standard', 'Manual'])
25 | param scaleType string
26 |
27 | resource cognitiveServicesDeploy 'Microsoft.CognitiveServices/accounts/deployments@2022-10-01' = {
28 | parent: cognitiveServices
29 | name: name
30 | properties: {
31 | model: {
32 | name: modelName
33 | version: deployVersion
34 | format: 'OpenAI'
35 | }
36 | scaleSettings: {
37 | scaleType: scaleType
38 | }
39 | }
40 | }
41 |
42 |
43 |
--------------------------------------------------------------------------------
/.github/PULL_REQUEST_TEMPLATE.md:
--------------------------------------------------------------------------------
1 | ## Purpose
2 |
3 | * ...
4 |
5 | ## Does this introduce a breaking change?
6 |
7 | ```
8 | [ ] Yes
9 | [ ] No
10 | ```
11 |
12 | ## Pull Request Type
13 | What kind of change does this Pull Request introduce?
14 |
15 |
16 | ```
17 | [ ] Bugfix
18 | [ ] Feature
19 | [ ] Code style update (formatting, local variables)
20 | [ ] Refactoring (no functional changes, no api changes)
21 | [ ] Documentation content changes
22 | [ ] Other... Please describe:
23 | ```
24 |
25 | ## How to Test
26 | * Get the code
27 |
28 | ```
29 | git clone [repo-address]
30 | cd [repo-name]
31 | git checkout [branch-name]
32 | npm install
33 | ```
34 |
35 | * Test the code
36 |
37 | ```
38 | ```
39 |
40 | ## What to Check
41 | Verify that the following are valid
42 | * ...
43 |
44 | ## Other Information
45 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/navs/_global.scss:
--------------------------------------------------------------------------------
1 | // Global styles for both custom sidebar and topbar compoments
2 |
3 | .sidebar,
4 | .topbar {
5 | .nav-item {
6 | // Customize Dropdown Arrows for Navbar
7 | &.dropdown {
8 | .dropdown-toggle {
9 | &::after {
10 | width: 1rem;
11 | text-align: center;
12 | float: right;
13 | vertical-align: 0;
14 | border: 0;
15 | font-weight: 900;
16 | content: '\f105';
17 | font-family: 'Font Awesome 5 Free';
18 | }
19 | }
20 | &.show {
21 | .dropdown-toggle::after {
22 | content: '\f107';
23 | }
24 | }
25 | }
26 | // Counter for nav links and nav link image sizing
27 | .nav-link {
28 | position: relative;
29 | .badge-counter {
30 | position: absolute;
31 | transform: scale(0.7);
32 | transform-origin: top right;
33 | right: .25rem;
34 | margin-top: -.25rem;
35 | }
36 | .img-profile {
37 | height: 2rem;
38 | width: 2rem;
39 | }
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/navs/_global.scss:
--------------------------------------------------------------------------------
1 | // Global styles for both custom sidebar and topbar compoments
2 |
3 | .sidebar,
4 | .topbar {
5 | .nav-item {
6 | // Customize Dropdown Arrows for Navbar
7 | &.dropdown {
8 | .dropdown-toggle {
9 | &::after {
10 | width: 1rem;
11 | text-align: center;
12 | float: right;
13 | vertical-align: 0;
14 | border: 0;
15 | font-weight: 900;
16 | content: '\f105';
17 | font-family: 'Font Awesome 5 Free';
18 | }
19 | }
20 | &.show {
21 | .dropdown-toggle::after {
22 | content: '\f107';
23 | }
24 | }
25 | }
26 | // Counter for nav links and nav link image sizing
27 | .nav-link {
28 | position: relative;
29 | .badge-counter {
30 | position: absolute;
31 | transform: scale(0.7);
32 | transform-origin: top right;
33 | right: .25rem;
34 | margin-top: -.25rem;
35 | }
36 | .img-profile {
37 | height: 2rem;
38 | width: 2rem;
39 | }
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_login.scss:
--------------------------------------------------------------------------------
1 | // Pulling these images from Unsplash
2 | // Toshi the dog from https://unsplash.com/@charlesdeluvio - what a funny dog...
3 |
4 | .bg-login-image {
5 | background: url($login-image);
6 | background-position: center;
7 | background-size: cover;
8 | }
9 |
10 | .bg-register-image {
11 | background: url($register-image);
12 | background-position: center;
13 | background-size: cover;
14 | }
15 |
16 | .bg-password-image {
17 | background: url($password-image);
18 | background-position: center;
19 | background-size: cover;
20 | }
21 |
22 | form.user {
23 |
24 | .custom-checkbox.small {
25 | label {
26 | line-height: 1.5rem;
27 | }
28 | }
29 |
30 | .form-control-user {
31 | font-size: 0.8rem;
32 | border-radius: 10rem;
33 | padding: 1.5rem 1rem;
34 | }
35 |
36 | .btn-user {
37 | font-size: 0.8rem;
38 | border-radius: 10rem;
39 | padding: 0.75rem 1rem;
40 | }
41 |
42 | }
43 |
44 | .btn-google {
45 | @include button-variant($brand-google, $white);
46 | }
47 |
48 | .btn-facebook {
49 | @include button-variant($brand-facebook, $white);
50 | }
51 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_login.scss:
--------------------------------------------------------------------------------
1 | // Pulling these images from Unsplash
2 | // Toshi the dog from https://unsplash.com/@charlesdeluvio - what a funny dog...
3 |
4 | .bg-login-image {
5 | background: url($login-image);
6 | background-position: center;
7 | background-size: cover;
8 | }
9 |
10 | .bg-register-image {
11 | background: url($register-image);
12 | background-position: center;
13 | background-size: cover;
14 | }
15 |
16 | .bg-password-image {
17 | background: url($password-image);
18 | background-position: center;
19 | background-size: cover;
20 | }
21 |
22 | form.user {
23 |
24 | .custom-checkbox.small {
25 | label {
26 | line-height: 1.5rem;
27 | }
28 | }
29 |
30 | .form-control-user {
31 | font-size: 0.8rem;
32 | border-radius: 10rem;
33 | padding: 1.5rem 1rem;
34 | }
35 |
36 | .btn-user {
37 | font-size: 0.8rem;
38 | border-radius: 10rem;
39 | padding: 0.75rem 1rem;
40 | }
41 |
42 | }
43 |
44 | .btn-google {
45 | @include button-variant($brand-google, $white);
46 | }
47 |
48 | .btn-facebook {
49 | @include button-variant($brand-facebook, $white);
50 | }
51 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_login.scss:
--------------------------------------------------------------------------------
1 | // Pulling these images from Unsplash
2 | // Toshi the dog from https://unsplash.com/@charlesdeluvio - what a funny dog...
3 |
4 | .bg-login-image {
5 | background: url($login-image);
6 | background-position: center;
7 | background-size: cover;
8 | }
9 |
10 | .bg-register-image {
11 | background: url($register-image);
12 | background-position: center;
13 | background-size: cover;
14 | }
15 |
16 | .bg-password-image {
17 | background: url($password-image);
18 | background-position: center;
19 | background-size: cover;
20 | }
21 |
22 | form.user {
23 |
24 | .custom-checkbox.small {
25 | label {
26 | line-height: 1.5rem;
27 | }
28 | }
29 |
30 | .form-control-user {
31 | font-size: 0.8rem;
32 | border-radius: 10rem;
33 | padding: 1.5rem 1rem;
34 | }
35 |
36 | .btn-user {
37 | font-size: 0.8rem;
38 | border-radius: 10rem;
39 | padding: 0.75rem 1rem;
40 | }
41 |
42 | }
43 |
44 | .btn-google {
45 | @include button-variant($brand-google, $white);
46 | }
47 |
48 | .btn-facebook {
49 | @include button-variant($brand-facebook, $white);
50 | }
51 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_global.scss:
--------------------------------------------------------------------------------
1 | // Global component styles
2 |
3 | html {
4 | position: relative;
5 | min-height: 100%;
6 | }
7 |
8 | body {
9 | height: 100%;
10 | }
11 |
12 | a {
13 | &:focus {
14 | outline: none;
15 | }
16 | }
17 |
18 | // Main page wrapper
19 | #wrapper {
20 | display: flex;
21 | #content-wrapper {
22 | background-color: $gray-100;
23 | width: 100%;
24 | overflow-x: hidden;
25 | #content {
26 | flex: 1 0 auto;
27 | }
28 | }
29 | }
30 |
31 | // Set container padding to match gutter width instead of default 15px
32 | .container,
33 | .container-fluid {
34 | padding-left: $grid-gutter-width;
35 | padding-right: $grid-gutter-width;
36 | }
37 |
38 | // Scroll to top button
39 | .scroll-to-top {
40 | position: fixed;
41 | right: 1rem;
42 | bottom: 1rem;
43 | display: none;
44 | width: 2.75rem;
45 | height: 2.75rem;
46 | text-align: center;
47 | color: $white;
48 | background: fade-out($gray-800, .5);
49 | line-height: 46px;
50 | &:focus,
51 | &:hover {
52 | color: white;
53 | }
54 | &:hover {
55 | background: $gray-800;
56 | }
57 | i {
58 | font-weight: 800;
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/LICENSE.md:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) Microsoft Corporation.
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_global.scss:
--------------------------------------------------------------------------------
1 | // Global component styles
2 |
3 | html {
4 | position: relative;
5 | min-height: 100%;
6 | }
7 |
8 | body {
9 | height: 100%;
10 | }
11 |
12 | a {
13 | &:focus {
14 | outline: none;
15 | }
16 | }
17 |
18 | // Main page wrapper
19 | #wrapper {
20 | display: flex;
21 | #content-wrapper {
22 | background-color: $gray-100;
23 | width: 100%;
24 | overflow-x: hidden;
25 | #content {
26 | flex: 1 0 auto;
27 | }
28 | }
29 | }
30 |
31 | // Set container padding to match gutter width instead of default 15px
32 | .container,
33 | .container-fluid {
34 | padding-left: $grid-gutter-width;
35 | padding-right: $grid-gutter-width;
36 | }
37 |
38 | // Scroll to top button
39 | .scroll-to-top {
40 | position: fixed;
41 | right: 1rem;
42 | bottom: 1rem;
43 | display: none;
44 | width: 2.75rem;
45 | height: 2.75rem;
46 | text-align: center;
47 | color: $white;
48 | background: fade-out($gray-800, .5);
49 | line-height: 46px;
50 | &:focus,
51 | &:hover {
52 | color: white;
53 | }
54 | &:hover {
55 | background: $gray-800;
56 | }
57 | i {
58 | font-weight: 800;
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_global.scss:
--------------------------------------------------------------------------------
1 | // Global component styles
2 |
3 | html {
4 | position: relative;
5 | min-height: 100%;
6 | }
7 |
8 | body {
9 | height: 100%;
10 | }
11 |
12 | a {
13 | &:focus {
14 | outline: none;
15 | }
16 | }
17 |
18 | // Main page wrapper
19 | #wrapper {
20 | display: flex;
21 | #content-wrapper {
22 | background-color: $gray-100;
23 | width: 100%;
24 | overflow-x: hidden;
25 | #content {
26 | flex: 1 0 auto;
27 | }
28 | }
29 | }
30 |
31 | // Set container padding to match gutter width instead of default 15px
32 | .container,
33 | .container-fluid {
34 | padding-left: $grid-gutter-width;
35 | padding-right: $grid-gutter-width;
36 | }
37 |
38 | // Scroll to top button
39 | .scroll-to-top {
40 | position: fixed;
41 | right: 1rem;
42 | bottom: 1rem;
43 | display: none;
44 | width: 2.75rem;
45 | height: 2.75rem;
46 | text-align: center;
47 | color: $white;
48 | background: fade-out($gray-800, .5);
49 | line-height: 46px;
50 | &:focus,
51 | &:hover {
52 | color: white;
53 | }
54 | &:hover {
55 | background: $gray-800;
56 | }
57 | i {
58 | font-weight: 800;
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/monitor/monitoring.bicep:
--------------------------------------------------------------------------------
1 | param logAnalyticsName string
2 | param applicationInsightsName string
3 | param applicationInsightsDashboardName string
4 | param location string = resourceGroup().location
5 | param tags object = {}
6 |
7 | module logAnalytics 'loganalytics.bicep' = {
8 | name: 'loganalytics'
9 | params: {
10 | name: logAnalyticsName
11 | location: location
12 | tags: tags
13 | }
14 | }
15 |
16 | module applicationInsights 'applicationinsights.bicep' = {
17 | name: 'applicationinsights'
18 | params: {
19 | name: applicationInsightsName
20 | location: location
21 | tags: tags
22 | dashboardName: applicationInsightsDashboardName
23 | logAnalyticsWorkspaceId: logAnalytics.outputs.id
24 | }
25 | }
26 |
27 | output applicationInsightsConnectionString string = applicationInsights.outputs.connectionString
28 | output applicationInsightsInstrumentationKey string = applicationInsights.outputs.instrumentationKey
29 | output applicationInsightsName string = applicationInsights.outputs.name
30 | output logAnalyticsWorkspaceId string = logAnalytics.outputs.id
31 | output logAnalyticsWorkspaceName string = logAnalytics.outputs.name
32 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/infra/core/ai/cognitiveservices.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param customSubDomainName string = name
6 | param deployments array = []
7 | param kind string = 'OpenAI'
8 | param publicNetworkAccess string = 'Enabled'
9 | param sku object = {
10 | name: 'S0'
11 | }
12 |
13 | resource account 'Microsoft.CognitiveServices/accounts@2022-10-01' = {
14 | name: name
15 | location: location
16 | tags: tags
17 | kind: kind
18 | properties: {
19 | customSubDomainName: customSubDomainName
20 | publicNetworkAccess: publicNetworkAccess
21 | }
22 | sku: sku
23 | }
24 |
25 | @batchSize(1)
26 | resource deployment 'Microsoft.CognitiveServices/accounts/deployments@2022-10-01' = [for deployment in deployments: {
27 | parent: account
28 | name: deployment.name
29 | properties: {
30 | model: deployment.model
31 | raiPolicyName: contains(deployment, 'raiPolicyName') ? deployment.raiPolicyName : null
32 | scaleSettings: deployment.scaleSettings
33 | }
34 | }]
35 |
36 | output endpoint string = account.properties.endpoint
37 | output id string = account.id
38 | output name string = account.name
39 |
--------------------------------------------------------------------------------
/1.call-center/app/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) Microsoft Corporation.
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE
22 |
--------------------------------------------------------------------------------
/6.azureopenai-landing-zone-accelerator/infra/core/ai/cognitiveservices.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param tags object = {}
4 |
5 | param customSubDomainName string = name
6 | param deployments array = []
7 | param kind string = 'OpenAI'
8 | param publicNetworkAccess string = 'Enabled'
9 | param sku object = {
10 | name: 'S0'
11 | }
12 |
13 | resource account 'Microsoft.CognitiveServices/accounts@2023-05-01' = {
14 | name: name
15 | location: location
16 | tags: tags
17 | kind: kind
18 | properties: {
19 | customSubDomainName: customSubDomainName
20 | publicNetworkAccess: publicNetworkAccess
21 | }
22 | sku: sku
23 | }
24 |
25 | @batchSize(1)
26 | resource deployment 'Microsoft.CognitiveServices/accounts/deployments@2023-05-01' = [for deployment in deployments: {
27 | parent: account
28 | name: deployment.name
29 | sku: deployment.sku
30 | properties: {
31 | model: deployment.model
32 | raiPolicyName: contains(deployment, 'raiPolicyName') ? deployment.raiPolicyName : null
33 | }
34 | }]
35 |
36 | output account object = account
37 | output endpoint string = account.properties.endpoint
38 | output id string = account.id
39 | output name string = account.name
40 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_buttons.scss:
--------------------------------------------------------------------------------
1 | .btn-circle {
2 | border-radius: 100%;
3 | height: 2.5rem;
4 | width: 2.5rem;
5 | font-size: 1rem;
6 | display: inline-flex;
7 | align-items: center;
8 | justify-content: center;
9 | &.btn-sm {
10 | height: 1.8rem;
11 | width: 1.8rem;
12 | font-size: 0.75rem;
13 | }
14 | &.btn-lg {
15 | height: 3.5rem;
16 | width: 3.5rem;
17 | font-size: 1.35rem;
18 | }
19 | }
20 |
21 | .btn-icon-split {
22 | padding: 0;
23 | overflow: hidden;
24 | display: inline-flex;
25 | align-items: stretch;
26 | justify-content: center;
27 | .icon {
28 | background: fade-out($black, .85);
29 | display: inline-block;
30 | padding: $btn-padding-y $btn-padding-x;
31 | }
32 | .text {
33 | display: inline-block;
34 | padding: $btn-padding-y $btn-padding-x;
35 | }
36 | &.btn-sm {
37 | .icon {
38 | padding: $btn-padding-y-sm $btn-padding-x-sm;
39 | }
40 | .text {
41 | padding: $btn-padding-y-sm $btn-padding-x-sm;
42 | }
43 | }
44 | &.btn-lg {
45 | .icon {
46 | padding: $btn-padding-y-lg $btn-padding-x-lg;
47 | }
48 | .text {
49 | padding: $btn-padding-y-lg $btn-padding-x-lg;
50 | }
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_buttons.scss:
--------------------------------------------------------------------------------
1 | .btn-circle {
2 | border-radius: 100%;
3 | height: 2.5rem;
4 | width: 2.5rem;
5 | font-size: 1rem;
6 | display: inline-flex;
7 | align-items: center;
8 | justify-content: center;
9 | &.btn-sm {
10 | height: 1.8rem;
11 | width: 1.8rem;
12 | font-size: 0.75rem;
13 | }
14 | &.btn-lg {
15 | height: 3.5rem;
16 | width: 3.5rem;
17 | font-size: 1.35rem;
18 | }
19 | }
20 |
21 | .btn-icon-split {
22 | padding: 0;
23 | overflow: hidden;
24 | display: inline-flex;
25 | align-items: stretch;
26 | justify-content: center;
27 | .icon {
28 | background: fade-out($black, .85);
29 | display: inline-block;
30 | padding: $btn-padding-y $btn-padding-x;
31 | }
32 | .text {
33 | display: inline-block;
34 | padding: $btn-padding-y $btn-padding-x;
35 | }
36 | &.btn-sm {
37 | .icon {
38 | padding: $btn-padding-y-sm $btn-padding-x-sm;
39 | }
40 | .text {
41 | padding: $btn-padding-y-sm $btn-padding-x-sm;
42 | }
43 | }
44 | &.btn-lg {
45 | .icon {
46 | padding: $btn-padding-y-lg $btn-padding-x-lg;
47 | }
48 | .text {
49 | padding: $btn-padding-y-lg $btn-padding-x-lg;
50 | }
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_buttons.scss:
--------------------------------------------------------------------------------
1 | .btn-circle {
2 | border-radius: 100%;
3 | height: 2.5rem;
4 | width: 2.5rem;
5 | font-size: 1rem;
6 | display: inline-flex;
7 | align-items: center;
8 | justify-content: center;
9 | &.btn-sm {
10 | height: 1.8rem;
11 | width: 1.8rem;
12 | font-size: 0.75rem;
13 | }
14 | &.btn-lg {
15 | height: 3.5rem;
16 | width: 3.5rem;
17 | font-size: 1.35rem;
18 | }
19 | }
20 |
21 | .btn-icon-split {
22 | padding: 0;
23 | overflow: hidden;
24 | display: inline-flex;
25 | align-items: stretch;
26 | justify-content: center;
27 | .icon {
28 | background: fade-out($black, .85);
29 | display: inline-block;
30 | padding: $btn-padding-y $btn-padding-x;
31 | }
32 | .text {
33 | display: inline-block;
34 | padding: $btn-padding-y $btn-padding-x;
35 | }
36 | &.btn-sm {
37 | .icon {
38 | padding: $btn-padding-y-sm $btn-padding-x-sm;
39 | }
40 | .text {
41 | padding: $btn-padding-y-sm $btn-padding-x-sm;
42 | }
43 | }
44 | &.btn-lg {
45 | .icon {
46 | padding: $btn-padding-y-lg $btn-padding-x-lg;
47 | }
48 | .text {
49 | padding: $btn-padding-y-lg $btn-padding-x-lg;
50 | }
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/4.company-research/.vscode/launch.json:
--------------------------------------------------------------------------------
1 | {
2 | // Use IntelliSense to learn about possible attributes.
3 | // Hover to view descriptions of existing attributes.
4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5 | "version": "0.2.0",
6 | "configurations": [
7 | {
8 | "name": "Python: Flask",
9 | "type": "python",
10 | "request": "launch",
11 | "module": "flask",
12 | "cwd": "${workspaceFolder}/app/backend",
13 | "env": {
14 | "FLASK_APP": "app.py",
15 | "FLASK_ENV": "development",
16 | "FLASK_DEBUG": "0"
17 | },
18 | "args": [
19 | "run",
20 | "--no-debugger",
21 | "--no-reload",
22 | "--host=localhost",
23 | "-p 5000"
24 | ],
25 | "console": "integratedTerminal",
26 | "justMyCode": true,
27 | "envFile": "${input:dotEnvFilePath}",
28 | }
29 | ],
30 | "inputs": [
31 | {
32 | "id": "dotEnvFilePath",
33 | "type": "command",
34 | "command": "azure-dev.commands.getDotEnvFilePath"
35 | }
36 | ]
37 | }
--------------------------------------------------------------------------------
/5.internal-document-search/infra/core/vm/vm.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param adminUsername string
4 | @secure()
5 | param adminPasswordOrKey string
6 | param vmSize string = 'Standard_D2s_v3'
7 | param nicId string
8 | param osDiskType string = 'Standard_LRS'
9 | param isPrivateNetworkEnabled bool
10 |
11 | param imageReference object = {
12 | publisher: 'MicrosoftWindowsDesktop'
13 | offer: 'Windows-11'
14 | sku: 'win11-21h2-pro'
15 | version: 'latest'
16 | }
17 |
18 | resource virtualMachine 'Microsoft.Compute/virtualMachines@2023-09-01' = if (isPrivateNetworkEnabled) {
19 | name: name
20 | location: location
21 | properties: {
22 | hardwareProfile: {
23 | vmSize: vmSize
24 | }
25 | osProfile: {
26 | computerName: name
27 | adminUsername: adminUsername
28 | adminPassword: adminPasswordOrKey
29 | }
30 | storageProfile: {
31 | osDisk: {
32 | createOption: 'FromImage'
33 | managedDisk: {
34 | storageAccountType: osDiskType
35 | }
36 | }
37 | imageReference: imageReference
38 | }
39 | networkProfile: {
40 | networkInterfaces: [
41 | {
42 | id: nicId
43 | }
44 | ]
45 | }
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/js/sb-admin-2.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * Start Bootstrap - SB Admin 2 v4.1.3 (https://startbootstrap.com/theme/sb-admin-2)
3 | * Copyright 2013-2021 Start Bootstrap
4 | * Licensed under MIT (https://github.com/StartBootstrap/startbootstrap-sb-admin-2/blob/master/LICENSE)
5 | */
6 |
7 | !function(l){"use strict";l("#sidebarToggle, #sidebarToggleTop").on("click",function(e){l("body").toggleClass("sidebar-toggled"),l(".sidebar").toggleClass("toggled"),l(".sidebar").hasClass("toggled")&&l(".sidebar .collapse").collapse("hide")}),l(window).resize(function(){l(window).width()<768&&l(".sidebar .collapse").collapse("hide"),l(window).width()<480&&!l(".sidebar").hasClass("toggled")&&(l("body").addClass("sidebar-toggled"),l(".sidebar").addClass("toggled"),l(".sidebar .collapse").collapse("hide"))}),l("body.fixed-nav .sidebar").on("mousewheel DOMMouseScroll wheel",function(e){var o;768 {
17 | const parsedAnswer = useMemo(() => parseChatAnswerToHtml(answer.answer), [answer]);
18 |
19 | const sanitizedAnswerHtml = DOMPurify.sanitize(parsedAnswer.answerHtml);
20 |
21 | return (
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 | );
34 | };
35 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/backend/task_assistant/conversation_summary.py:
--------------------------------------------------------------------------------
1 | prompt_system = """
2 | あなたはHTMLで文章を作成するアシスタントです。
3 | """
4 |
5 | prompt_user = """
6 | ユーザーは以下の目標を持っています。
7 | {theme}
8 |
9 | 私たちはこの目標を達成するための手順と詳細をユーザーとディスカッションしてきました。
10 |
11 | ディスカッションに含まれるJSONデータは以下の構成です。
12 | ・'steps' リストの各要素は、1番目が'step_num', 2番目が'content', 3番目が'variable_name', 4番目が'value'というキー。
13 | ・テーブル出力用に日本語列名を記述したheadersという配列。
14 | ・変数名は英語
15 | ・手順以外の文章は'answer'または'support'キーにセット
16 | ・'situation'はユーザーが与えた現在の状況の要約
17 | ・'support'はユーザーの回答に助けになる情報
18 | ・'answer'はユーザーに回答してもらいたい回答
19 | ・それ以外の文章は'answer'にセット
20 |
21 | いままでのやりとりを文章にして議事録形式でHTMLで出力してください。上記のJSONフォーマットでは出力しないでください。
22 |
23 | HTMLには以下の内容を含めてください。
24 | ・タイトル: お客様の目標のサマリ。20文字以内で。
25 | ・目標: お客様の目標
26 | ・目標達成までの手順と各手順をなるべく詳細に記載してください。
27 | ・具体的なアクション。スケジュールが設定されている場合はタイムラインも含む。
28 |
29 | HTMLデータの前と後に文章はつけず、必ずHTMLデータだけ返してください。HTMLタグ ,を含めたフルセットのHTMLにしてください。
30 | HTMLにはJSONデータに含まれていた'変数名'は含めないでください。
31 | HTMLタグは全て小文字にしてください。HTMLは白い背景で、テーブルを使う場合はヘッダーの背景色は薄いグレーにしてください。
32 | """
33 |
34 |
35 | def get_comversation_summary_prompt(theme, messages):
36 | prompt_user_formatted = prompt_user.format(theme=theme)
37 |
38 | return [
39 | {"role": "system", "content": prompt_system},
40 | {"role": "user", "content": prompt_user_formatted},
41 | ] + messages
42 |
--------------------------------------------------------------------------------
/4.company-research/infra/core/ai/cognitiveservices.bicep:
--------------------------------------------------------------------------------
1 | // Copyright (c) Microsoft Corporation.
2 | // Licensed under the MIT license.
3 | param name string
4 | param location string = resourceGroup().location
5 | param tags object = {}
6 |
7 | param customSubDomainName string = name
8 | param deployments array = []
9 | param kind string = 'OpenAI'
10 | param publicNetworkAccess string = 'Enabled'
11 | param sku object = {
12 | name: 'S0'
13 | }
14 |
15 | resource account 'Microsoft.CognitiveServices/accounts@2022-10-01' = {
16 | name: name
17 | location: location
18 | tags: tags
19 | kind: kind
20 | properties: {
21 | customSubDomainName: customSubDomainName
22 | publicNetworkAccess: publicNetworkAccess
23 | }
24 | sku: sku
25 | }
26 |
27 | @batchSize(1)
28 | resource deployment 'Microsoft.CognitiveServices/accounts/deployments@2023-05-01' = [for deployment in deployments: {
29 | parent: account
30 | name: deployment.name
31 | properties: {
32 | model: deployment.model
33 | raiPolicyName: contains(deployment, 'raiPolicyName') ? deployment.raiPolicyName : null
34 | }
35 | sku: contains(deployment, 'sku') ? deployment.sku : {
36 | name: 'Standard'
37 | capacity: 20
38 | }
39 | }]
40 |
41 | output endpoint string = account.properties.endpoint
42 | output id string = account.id
43 | output name string = account.name
44 |
--------------------------------------------------------------------------------
/1.call-center/app/static/themes/sb-admin/scss/_error.scss:
--------------------------------------------------------------------------------
1 | // Lucas Bebber's Glitch Effect
2 | // Tutorial and CSS from CSS Tricks
3 | // https://css-tricks.com/glitch-effect-text-images-svg/
4 |
5 | .error {
6 | color: $gray-800;
7 | font-size: 7rem;
8 | position: relative;
9 | line-height: 1;
10 | width: 12.5rem;
11 | }
12 | @keyframes noise-anim {
13 | $steps: 20;
14 | @for $i from 0 through $steps {
15 | #{percentage($i*(1/$steps))} {
16 | clip: rect(random(100)+px,9999px,random(100)+px,0);
17 | }
18 | }
19 | }
20 | .error:after {
21 | content: attr(data-text);
22 | position: absolute;
23 | left: 2px;
24 | text-shadow: -1px 0 $red;
25 | top: 0;
26 | color: $gray-800;
27 | background: $gray-100;
28 | overflow: hidden;
29 | clip: rect(0,900px,0,0);
30 | animation: noise-anim 2s infinite linear alternate-reverse;
31 | }
32 |
33 | @keyframes noise-anim-2 {
34 | $steps: 20;
35 | @for $i from 0 through $steps {
36 | #{percentage($i*(1/$steps))} {
37 | clip: rect(random(100)+px,9999px,random(100)+px,0);
38 | }
39 | }
40 | }
41 | .error:before {
42 | content: attr(data-text);
43 | position: absolute;
44 | left: -2px;
45 | text-shadow: 1px 0 $blue;
46 | top: 0;
47 | color: $gray-800;
48 | background: $gray-100;
49 | overflow: hidden;
50 | clip: rect(0,900px,0,0);
51 | animation: noise-anim-2 3s infinite linear alternate-reverse;
52 | }
53 |
--------------------------------------------------------------------------------
/2.recipe-adviser/app/backend/static/themes/sb-admin/scss/_error.scss:
--------------------------------------------------------------------------------
1 | // Lucas Bebber's Glitch Effect
2 | // Tutorial and CSS from CSS Tricks
3 | // https://css-tricks.com/glitch-effect-text-images-svg/
4 |
5 | .error {
6 | color: $gray-800;
7 | font-size: 7rem;
8 | position: relative;
9 | line-height: 1;
10 | width: 12.5rem;
11 | }
12 | @keyframes noise-anim {
13 | $steps: 20;
14 | @for $i from 0 through $steps {
15 | #{percentage($i*(1/$steps))} {
16 | clip: rect(random(100)+px,9999px,random(100)+px,0);
17 | }
18 | }
19 | }
20 | .error:after {
21 | content: attr(data-text);
22 | position: absolute;
23 | left: 2px;
24 | text-shadow: -1px 0 $red;
25 | top: 0;
26 | color: $gray-800;
27 | background: $gray-100;
28 | overflow: hidden;
29 | clip: rect(0,900px,0,0);
30 | animation: noise-anim 2s infinite linear alternate-reverse;
31 | }
32 |
33 | @keyframes noise-anim-2 {
34 | $steps: 20;
35 | @for $i from 0 through $steps {
36 | #{percentage($i*(1/$steps))} {
37 | clip: rect(random(100)+px,9999px,random(100)+px,0);
38 | }
39 | }
40 | }
41 | .error:before {
42 | content: attr(data-text);
43 | position: absolute;
44 | left: -2px;
45 | text-shadow: 1px 0 $blue;
46 | top: 0;
47 | color: $gray-800;
48 | background: $gray-100;
49 | overflow: hidden;
50 | clip: rect(0,900px,0,0);
51 | animation: noise-anim-2 3s infinite linear alternate-reverse;
52 | }
53 |
--------------------------------------------------------------------------------
/4.company-research/app/backend/static/themes/sb-admin/scss/_error.scss:
--------------------------------------------------------------------------------
1 | // Lucas Bebber's Glitch Effect
2 | // Tutorial and CSS from CSS Tricks
3 | // https://css-tricks.com/glitch-effect-text-images-svg/
4 |
5 | .error {
6 | color: $gray-800;
7 | font-size: 7rem;
8 | position: relative;
9 | line-height: 1;
10 | width: 12.5rem;
11 | }
12 | @keyframes noise-anim {
13 | $steps: 20;
14 | @for $i from 0 through $steps {
15 | #{percentage($i*(1/$steps))} {
16 | clip: rect(random(100)+px,9999px,random(100)+px,0);
17 | }
18 | }
19 | }
20 | .error:after {
21 | content: attr(data-text);
22 | position: absolute;
23 | left: 2px;
24 | text-shadow: -1px 0 $red;
25 | top: 0;
26 | color: $gray-800;
27 | background: $gray-100;
28 | overflow: hidden;
29 | clip: rect(0,900px,0,0);
30 | animation: noise-anim 2s infinite linear alternate-reverse;
31 | }
32 |
33 | @keyframes noise-anim-2 {
34 | $steps: 20;
35 | @for $i from 0 through $steps {
36 | #{percentage($i*(1/$steps))} {
37 | clip: rect(random(100)+px,9999px,random(100)+px,0);
38 | }
39 | }
40 | }
41 | .error:before {
42 | content: attr(data-text);
43 | position: absolute;
44 | left: -2px;
45 | text-shadow: 1px 0 $blue;
46 | top: 0;
47 | color: $gray-800;
48 | background: $gray-100;
49 | overflow: hidden;
50 | clip: rect(0,900px,0,0);
51 | animation: noise-anim-2 3s infinite linear alternate-reverse;
52 | }
53 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/frontend/src/components/AnalysisPanel/AnalysisPanel.module.css:
--------------------------------------------------------------------------------
1 | .thoughtProcess {
2 | font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New", monospace;
3 | word-wrap: break-word;
4 | padding-top: 12px;
5 | padding-bottom: 12px;
6 | }
7 |
8 | .stepTable {
9 | border-collapse: collapse;
10 | border: 1px solid #d3d3d3;
11 | box-shadow: 2px 2px 3px #d3d3d3;
12 | }
13 |
14 | .stepTableHeaderCell {
15 | padding: 8px;
16 | text-align: center;
17 | border-bottom: 1px solid #d3d3d3;
18 | }
19 |
20 | .stepTableColumnNo {
21 | width: 5%;
22 | text-align: center;
23 | background-color: #cccccc;
24 | border-top: 1px solid #d3d3d3;
25 | border-right: 1px solid #d3d3d3;
26 | }
27 |
28 | .stepTableColumnStep {
29 | width: 40%;
30 | background-color: #cccccc;
31 | border-top: 1px solid #d3d3d3;
32 | border-right: 1px solid #d3d3d3;
33 | }
34 |
35 | .stepTableColumnDetail {
36 | width: 55%;
37 | background-color: #cccccc;
38 | border-top: 1px solid #d3d3d3;
39 | border-right: 1px solid #d3d3d3;
40 | }
41 |
42 | .stepTableCellNo {
43 | text-align: center;
44 | border: 1px solid #cccccc;
45 | padding: 5px;
46 | }
47 |
48 | .stepTableCellStep {
49 | border: 1px solid #cccccc;
50 | padding: 5px;
51 | }
52 |
53 | .stepTableCellDetail {
54 | border: 1px solid #cccccc;
55 | padding: 5px;
56 | }
57 |
--------------------------------------------------------------------------------
/1.call-center/app/templates/template.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Microsoft AI Solutions
8 |
9 |
10 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 | {% block main %}
36 | {% endblock %}
37 |
38 |
39 |
40 |
41 |
--------------------------------------------------------------------------------
/3.goal-achievement-adviser/app/start.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | echo ""
4 | echo "Loading azd .env file from current environment"
5 | echo ""
6 |
7 | while IFS='=' read -r key value; do
8 | value=$(echo "$value" | sed 's/^"//' | sed 's/"$//')
9 | export "$key=$value"
10 | done <[KNN {n} @embeddings $vec_param AS vector_score]"
23 | query = (
24 | Query(base_query)
25 | .sort_by("vector_score")
26 | .paging(0, n)
27 | .return_fields("text", "vector_score")
28 | .dialect(2)
29 | )
30 |
31 | embedding = get_gpt_embedding(embedding_deployment, text)
32 | query_params = {"vec_param": np.array(embedding).astype(np.float32).tobytes()}
33 | redis_ret = redis_client.ft(redis_index_name).search(
34 | query, query_params=query_params
35 | )
36 | df = pd.DataFrame(
37 | [
38 | {"id": x.id, "text": x.text, "vector_score": x.vector_score}
39 | for x in redis_ret.docs
40 | ]
41 | )
42 |
43 | return df["text"].str.cat(sep=" ")
44 |
45 |
46 | def get_internal_knowledge(
47 | embedding_deployment: str,
48 | redis_client: StrictRedis,
49 | redis_index_name: str,
50 | question: str,
51 | ):
52 | return query_cache(
53 | embedding_deployment=embedding_deployment,
54 | redis_client=redis_client,
55 | redis_index_name=redis_index_name,
56 | text=question,
57 | n=3,
58 | )
59 |
--------------------------------------------------------------------------------