Using Azure OpenAI Service with Local bolt.new
Using Azure OpenAI Service with Local bolt.new bolt.new is an AI-powered full-stack web development platform. It can also be run locally from a GitHub repository. While bolt.new uses Anthropic Claude 3.5 Sonnet by default, this time, we’ll modify it to work with Azure. Implementing Azure When making code modifications, the original code will be retained as comments. Below, only the modified sections of the code are shown, while unchanged original code is abbreviated with “…”. Adding Libraries First, add the necessary library. In bolt.new/package.json , include the @ai-sdk/azure library as follows: { ... "dependencies" : { "@ai-sdk/anthropic" : "^0.0.39" , "@ai-sdk/azure" : "^1.0.5" , // <- Added ... } , ... } Setting Azure Environment Variables First, add the Azure resource name, API key, and deployment name to the bolt.new/.env.local file: ... AZURE_RESOURCE_NAME=Y