How can I create lambda function code after deploying bart transformer for summarization in sagemaker?

Yes, as mentioned above I created an example on how to do do this using AWS CDK.