[{"data":1,"prerenderedAt":66},["ShallowReactive",2],{"pattern-apigw-lambda-bedrock-sam-java":3},{"id":4,"title":5,"architectureURL":6,"cleanup":7,"contributors":10,"deploy":12,"description":16,"extension":17,"framework":18,"gitHub":19,"highlight":6,"introBox":25,"language":32,"level":33,"meta":34,"patternArch":35,"resources":53,"s3URL":6,"services":6,"stem":61,"testing":62,"videoId":6,"__hash__":65},"patterns\u002Fpatterns\u002Fapigw-lambda-bedrock-sam-java.json","Invoking Amazon Bedrock Mistral 7B LLM using Java based AWS Lambda",null,{"text":8},[9],"Delete the stack: \u003Ccode>sam delete\u003C\u002Fcode>.",[11],"content\u002Fcontributors\u002Fbiswanath-mukherjee.json",{"text":13},[14,15],"mvn clean package","sam deploy --guided","This project deploys an Amazon API Gateway REST API with an AWS Lambda, written in Java, to call Amazon Bedrock API for Mistral 7B Instruct V0.2.","json","AWS SAM",{"template":20},{"repoURL":21,"templateURL":22,"projectFolder":23,"templateFile":24},"https:\u002F\u002Fgithub.com\u002Faws-samples\u002Fserverless-patterns\u002Ftree\u002Fmain\u002Fapigw-lambda-bedrock-sam-java","serverless-patterns\u002Fapigw-lambda-bedrock-sam-java","apigw-lambda-bedrock-sam-java","template.yaml",{"headline":26,"text":27},"How it works",[28,29,30,31],"Amazon API Gateway receives the HTTP POST request containing the prompt.","AWS Lambda is triggered by the API Gateway, this function forwards the prompt to Amazon Bedrock Java API. It uses Mistral 7B Instruct V0.2 model and sets other required parameters to fixed values for simplicity.","Based on the given prompt, using Mistral 7B Instruct V0.2 model, Amazon Bedrock generates the content and returns the response to the Lambda function.","The Lambda function processes the Bedrock API response and sends it back to the user via the API Gateway.","Java","200",{},{"icon1":36,"icon2":41,"icon3":44,"line1":48,"line2":51},{"x":37,"y":38,"service":39,"label":40},20,50,"apigw","API Gateway REST API",{"x":38,"y":38,"service":42,"label":43},"lambda","AWS Lambda",{"x":45,"y":38,"service":46,"label":47},80,"bedrock","Amazon Bedrock",{"from":49,"to":50},"icon1","icon2",{"from":50,"to":52},"icon3",{"bullets":54},[55,58],{"text":56,"link":57},"Amazon Bedrock Model Access","https:\u002F\u002Fdocs.aws.amazon.com\u002Fbedrock\u002Flatest\u002Fuserguide\u002Fmodel-access.html",{"text":59,"link":60},"Mistral AI on Amazon Bedrock","https:\u002F\u002Faws.amazon.com\u002Fbedrock\u002Fmistral\u002F","patterns\u002Fapigw-lambda-bedrock-sam-java",{"text":63},[64],"See the GitHub repo for detailed testing instructions.","eM2mpKDtExySYoBfKqEfhi6boYcs461yKrnL-z14pMM",1778846882091]