We've moved! Please find the latest version of this solution in the AI-in-a-Box repository: https://aka.ms/ai-in-a-box This repository will be archived on February 2024.
This project deploys an extensible Semantic Kernel bot template to Azure.
The solution architecture is described in the diagram below.
The flow of messages is as follows:
For running locally:
For deploying to Azure:
azd auth login
git clone https://github.com/Azure/AI-in-a-Box
cd semantic-kernel-bot-in-a-box
Deploy resources:
azd up
You will be prompted for a subcription, region and model information. Keep regional model availability when proceeding.
Test on Web Chat - go to your Azure Bot resource on the Azure portal and look for the Web Chat feature on the left side menu.
After running the deployment template, you may also run the application locally for development and debugging.
AI Developer
role at the resource group level is recommended.src
directory and look for the appsettings.example.json
file. Rename it to appsettings.json
and fill out the required service endpoints and configurationsdotnet run
The application has the ability to consume information from GPT-4 itself, Cognitive Search, SQL and documents uploaded by the end user directly. Each of these data sources will be preloaded with some sample data, but you may use the connections as templates to connect your own data sources.
You may ask about the following topics to test each functionality
General knowledge questions
Retrieval-augmented generation (SearchPlugin)
Structured data retrieval (SQLPlugin)
Upload documents as context (UploadPlugin)
Generate images (DALLEPlugin)
This project comes with a few plugins, which may be found in the Plugins/ directory. You may use these as examples when developing your own plugins.
To create a custom plugin:
And you're done! Redeploy your app and Semantic Kernel will now use your plugin whenever the user's questions call for it.
To deploy a Web Chat version of your app:
Please note that doing so will make your bot public, unless you implement authentication / SSO.
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.
This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow Microsoft's Trademark & Brand Guidelines. Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies.