CreateScoreRequest.DatasetRunId not working? #9363
Replies: 3 comments 2 replies
|
In Langfuse, the Score object can be associated with a Your observation is correct: there is no documented Scoring with only 📚 Sources: Have another question? Just tag @inkeep. |
|
Yes, there is a DatasetRun object in Langfuse. The data model defines a DatasetRun as an object with attributes including id, name, description, metadata, and datasetId, and it represents a run of a dataset through your LLM application(1). The OpenAPI schema also includes a DatasetRunWithItems object, which contains properties such as id, name, datasetId, and an array of datasetRunItems(2). However, DatasetRun objects are typically created automatically as a side effect when you create a DatasetRunItem and specify a new run name(3). The documented workflow is that creating a DatasetRunItem with a new run name will create (or update) the associated DatasetRun if it does not already exist(3). This means you cannot create a DatasetRun in isolation via OpenAPI; it is always tied to at least one DatasetRunItem(3). So, while you cannot create a DatasetRun without at least one DatasetRunItem, you also cannot create a DatasetRunItem without a DatasetRun being created or referenced as a side effect—there is always a DatasetRun associated with every DatasetRunItem(1)(2)(3). 📚 Sources: Have another question? Just tag @inkeep. |
|
The CreateScoreRequest.DatasetRunId field in POST /api/public/scores is used to associate a score with an entire dataset run, not with individual dataset run items or traces. This allows you to record a single score that represents the overall evaluation or result for a full dataset run. If you want to score specific items (rows) within a dataset run, you should use the traceId field instead, as trace-level scores are linked to individual traces corresponding to dataset run items. DatasetRunId is not intended for per-item scoring—it is for run-level aggregation or summary scores(1), (2). 📚 Sources: Have another question? Just tag @inkeep. |

The CreateScoreRequest.DatasetRunId field in POST /api/public/scores is used to associate a score with an entire dataset run, not with individual dataset run items or traces. This allows you to record a single score that represents the overall evaluation or result for a full dataset run. If you want to score specific items (rows) within a dataset run, you should use the traceId field instead, as trace-level scores are linked to individual traces corresponding to dataset run items. DatasetRunId is not intended for per-item scoring—it is for run-level aggregation or summary scores(1), (2).
📚 Sources:
Have anot…