---
title: "Prediction Create"
method: POST
path: "/v2/{entity}/{project}/predictions"
tags: ["Predictions"]
---

# Prediction Create

`POST /v2/{entity}/{project}/predictions`

## Request

- Base URL: `https://trace.wandb.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://trace.wandb.ai/v2/{entity}/{project}/predictions`
- Auth: none declared

Create a prediction.

## Path parameters

- `entity` string, required
- `project` string, required

## Request body

- PredictionCreateBody: Request body for creating a Prediction via REST API. This model excludes project_id since it comes from the URL path in RESTful endpoints.
  - `model` string, required: The model reference (weave:// URI)
  - `inputs` object, required: The inputs to the prediction
  - `output` unknown, required
  - `evaluation_run_id` string, nullable: Optional evaluation run ID to link this prediction as a child call
  - `genai_span_ref` GenAISpanRef[], nullable: Optional GenAI span reference(s) produced by this prediction.
    - `trace_id` string, required
    - `span_id` string, required

## Response `200`

Successful Response

- PredictionCreateRes
  - `prediction_id` string, required: The prediction ID

## Other responses

- `422`: Validation Error

## Changes

- **2026-10-16** `dd89fadfe4e4`: 4 info
  - the endpoint scheme security `HTTPBasic` was removed from the API
  - added the new optional request property `genai_span_ref`
  - added the optional property `detail/items/ctx` to the response with the `422` status
  - added the optional property `detail/items/input` to the response with the `422` status
- **2026-02-02** `56745769989b`: 1 info
  - endpoint added
- **2026-01-07** `3758bf263a5e`: 1 breaking
  - api path removed without deprecation
- **2026-01-07** `d6e39f7c717d`: 1 info
  - api operation id `prediction_create` removed and replaced with `prediction_create_v2__entity___project__predictions_post`
- **2025-11-14** `e444bf379e61`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/wandb/apis/weights-biases-weave-stainless-api/changes/v2/:entity/:project/predictions/post.md)

---

[API](https://skmtc.dev/wandb/apis/weights-biases-weave-stainless-api.md) - [All operations](https://skmtc.dev/wandb/apis/weights-biases-weave-stainless-api/llms.txt) - [OpenAPI document](https://skmtc.dev/wandb/apis/weights-biases-weave-stainless-api/revisions/f7643c49bf2e?raw)
