# Retrieving Results

The <mark style="color:red;">`results`</mark> endpoint retrieves the outcomes and insights of a prediction task using a specified job\_id and job\_code. This endpoint provides access to a variety of prediction results, including core results that apply to all prediction types and extended results that offer additional details for specific prediction models, such as psr (partial sample regression) and maxfit.

Use this endpoint to request and analyze the outcomes of a completed prediction task, gaining a deeper understanding of how features were weighed and the final predictions generated.

## Core Results

The core results are common across all prediction tasks, including grid predictions and base response cases. These include essential metrics like the prediction outcomes, fit, adjusted fit, variable importance, and the prediction weights across observations. The core results provide a foundational understanding of the prediction outcomes and model performance for all types of predictions.

{% openapi src="<https://raw.githubusercontent.com/CambridgeSportsAnalytics/prediction_engine/refs/heads/main/docs/api_specs/basic.json>" path="/results" method="get" %}
<https://raw.githubusercontent.com/CambridgeSportsAnalytics/prediction_engine/refs/heads/main/docs/api_specs/basic.json>
{% endopenapi %}

## Extended

The extended results section details additional objects included in the response for specific endpoints, such as psr and maxfit. These results offer deeper insights into the behavior and performance evaluation of the prediction task, providing metrics such as relevance, similarity, and informativeness that are specific to each task.

{% openapi src="<https://raw.githubusercontent.com/CambridgeSportsAnalytics/prediction_engine/refs/heads/main/docs/api_specs/extended.json>" path="/results" method="get" %}
<https://raw.githubusercontent.com/CambridgeSportsAnalytics/prediction_engine/refs/heads/main/docs/api_specs/extended.json>
{% endopenapi %}

```json
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.csanalytics.io/prediction-engine/results.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
