Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial model prediction runtime with support for presigned model get and output post URLS #1

Merged
merged 3 commits into from
Apr 19, 2023

Conversation

pschork
Copy link
Contributor

@pschork pschork commented Apr 15, 2023

Numerai Model Prediction Docker Environment

Presigned GET and POST urls are used to ensure that only the specified model is downloaded during execution
and that model prediction uploads from other models are not accessed or tampered with.

Presigned S3 model URL

The --model arg is designed to accept a pre-signed S3 GET URL generated via boto3

params = dict(Bucket='numerai-user-models', Key='integration_test')
presigned_model_url = s3_client.generate_presigned_url("get_object", params, ExpiresIn=600)

Presigned S3 post URL

The --post_url and --post_data args are designed to accept a pre-signed S3 POST URL + urlencoded data dictionary
generated via boto3

presigned_post = s3_client.generate_presigned_post(Bucket='numerai-user-models', Key='integration_test', ExpiresIn=600)
post_url = presigned_post['url']
post_data = urllib.parse.urlencode(presigned_post['fields'])

@pschork pschork merged commit 70d0c3e into master Apr 19, 2023
@pschork pschork deleted the pschork/v1 branch June 1, 2023 17:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant