Model/backend/lambda/handler.py
2025-04-16 16:42:12 +01:00

13 lines
302 B
Python

import json
def handler(event, context):
"""
This is an ascynchonous lambda handler that will run the model engine
:param event:
:param context:
:return:
"""
for record in event["Records"]:
body = json.loads(record["body"])
asyncio.run(model_engine(body))