---
title: "Suggest example rows to train on"
method: POST
path: "/agent-training/saved-agents/{saved_agent_id}/sample-rows/"
tags: ["agent-training"]
---

# Suggest example rows to train on

`POST /agent-training/saved-agents/{saved_agent_id}/sample-rows/`

## Request

- Base URL: `https://api.getoneprofile.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.getoneprofile.ai/agent-training/saved-agents/{saved_agent_id}/sample-rows/`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Example input rows to fill the training grid with, so the author is not asked to invent test data for an agent they have not run. Real values are read from one of the org's own tables when a table's columns can feed every input; otherwise they are written from the agent's prompt and the workspace's business context. The set is remembered on the agent, so asking again offers the same rows until `regenerate` is sent or the agent's inputs change. Read-only against the workspace: no session, no runs, no credits.

## Path parameters

- `saved_agent_id` string, uuid, required

## Request body

- SampleRowsRequestSchema: A request for example rows to fill the training grid with.
  - `count` integer: How many examples to offer.
  - `regenerate` boolean: Skip the agent's remembered examples and find fresh ones, replacing what was stored. What 'Suggest different examples' asks for; the default replays the set so training the same agent twice offers the same rows.

## Response `200`

Successful Response

- SampleRowsResponseSchema: Example rows to fill the grid with, and where they came from.
  - `inputs_changed` boolean: A remembered set was discarded because the agent's inputs no longer matched it, so these are fresh.
  - `origin` 'table' | 'generated', required: Where an agent's remembered example rows were found.
  - `remembered` boolean: These were replayed from the agent rather than found afresh.
  - `rows` object[], required: One set of input values per example, in offer order.
  - `table_name` string, nullable: The table the values came from; null when they were generated.

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `404`: Saved agent not found
- `422`: Invalid request made to the API.
- `500`: Internal server error.
- `502`: Bad gateway error.
- `503`: Service unavailable.

---

[API](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile.md) · [All operations](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile/llms.txt) · [OpenAPI document](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile/revisions/4a6bd71e3f02?raw)
