Module 5 · step 3 of 6 · Deploying and testing
Test predictions
Send test rows to your endpoint, read the response and see the request your own code would send.
App8 min
In this step you will send test rows to your endpoint from the app and read the answers. It matters because a deployed model is only trustworthy once you have asked it questions: wrong types, missing fields and extreme probabilities show up here, before real traffic finds them.
The idea
The Test tab calls the same endpoint your own application would call. The card Test a prediction holds a JSON array of rows, pre-filled with one real example from the training data. For each row the response gives a Prediction and, for classifiers, the probability of each class (P(class)), plus latency and a request ID. Preprocessing lives inside the model, so you send raw values.
Every call to the endpoint, including this card, is logged for drift checks. A handful of test rows is far too few to measure drift, but it is the first traffic your monitor sees.
Step by step
- Select Deployments, open your endpoint and select the Test tab.
- In the card Test a prediction, read Rows (JSON array). The hint says how many features the model expects. Change a value, for example make a customer's tenure much shorter.
- Select Send request. In the Response area read the latency in milliseconds, the request ID and a table with the Prediction and P(class).
- Add a second object to the array with very different values and send again. Compare the probabilities of the two rows.
- Open the Overview tab and read Predictions, p50 latency, p95 latency and Recent predictions.
- On Overview, open Use this endpoint and its code tabs (curl, Python, JavaScript). The payload uses your model's real feature columns. This is the request your own code would send; the response has one entry per row with
prediction,probabilitiesfor models that score classes, andlatency_ms.
What you should see in the numbers
Two rows with clearly different inputs should not receive identical probabilities. If they do, check that you really changed the fields the model uses.
Common mistakes
- Sending invalid JSON or misspelled field names. The call fails and the Response area shows the error instead of a table; compare your keys with the feature columns in the hint.
- Testing with one typical row. Probe the edges too: a very short tenure, a rare category, a missing optional value.
- Reading a single prediction as proof of quality. Quality comes from the run's metrics; this test only checks that the endpoint behaves.
As a data scientist
Check that the answer moves in the direction you expect when you change one field at a time; it is the cheapest sanity test you will ever run. Keep the sample payload from Use this endpoint with your project notes so the next person can smoke-test after a rollback. Scoring a whole file is the next lesson.
Checkpoint
You should see a Response with a Prediction and P(class) probabilities, and the Predictions counter on the Overview tab going up.