Showing results for 
Search instead for 
Did you mean: 

What's the API endpoint for Compute Predictions?

What's the API endpoint for Compute Predictions?

In "API Enabled" model -> "Predict" tab -> "Make Predictions" pane -> "Prediction Datasets" -> "Training Data" there's a drop-down where I can choose All, Validation and Holdout and Holdout next to "Compute Predictions". What's the API endpoint for this feature? I've been searching the documentation for the word "holdout" and this page is the closest I can find related to my question: But using Chrome's debugger I can see that the POST call that is initiated once I click "Computer Predictions" looks like this:{id1}/model/{id2}/{id3} I can guess that id1 is predictionId, id2 is modelId but what is id3 then? Thanks.

2 Replies

I just experimented with the endpoints in the article that I found (the Training Predictions) and it seems to be what I'm looking for; we will stay away from using the "internal app API". Thanks for quick response!

0 Kudos
DataRobot Employee
DataRobot Employee

What you've found in the Chrome debugger is an internal "app" API which is in use by the UI. It's undocumented and subject to changes and deprecation at any point. So I wouldn't recommend to use it for anything critical.

But to answer your question. The third ID is the dataset ID. For training data, that's the training dataset ID retrieved from the project metadata. The mentioned route can be used for other datasets than just the training dataset. For example if you uploaded a CSV dataset to predict. That's why it has a dataset ID parameter.

It's comparable to using the Public API route you found in the Public API docs - just the training dataset ID doesn't need to be passed, because the Public API route is dedicated to training predictions only.

Had you instead uploaded a CSV file or used a data source for predictions, you would go through these routes instead: