---
title: "List Benchable Documents"
method: GET
path: "/internal/evals/requirements-extraction/documents"
tags: ["internal"]
---

# List Benchable Documents

`GET /internal/evals/requirements-extraction/documents`

## Request

- Base URL: `https://api.kobaltlabs.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.kobaltlabs.com/internal/evals/requirements-extraction/documents`
- Auth: none declared

Guideline documents already in the platform, so a run can be started without uploading.

Deliberately **not** scoped to the caller's company: tuning a prompt means running it over the
guideline documents that exist, whoever they belong to. That is only acceptable because this
router is not mounted outside `DEVELOPMENT` — see `backend/api/internal/__init__.py`.

Restricted in SQL to the types `is_guideline_document` accepts, because the alternative is a
list where `limit` is spent on vendor contracts that happen to sort first and the guideline
documents never appear. A guideline stored under a type that hides it here is still benchable
by uploading it.

No text search, deliberately. The picker is a Tremor `SearchSelect`, which always filters its own
children client-side with a literal substring test on the rendered label; a server-side `ILIKE`
on top of that is a second filter with different rules, and the two disagreed on any query with
edge whitespace or a `LIKE` metacharacter — the server matched rows the client then hid, showing
no dropdown and no reason. The whole (bounded) list goes to the client and it filters once.

## Query parameters

- `marketing_only` boolean: Only documents whose type is a marketing one.
- `limit` integer

## Response `200`

Successful Response

- BenchableDocument[]
  - `upload_id` string, required
  - `company_name` string, required
  - `filename` string, required
  - `document_type` string, nullable
  - `page_count` integer, nullable
  - `suggested_profile` 'regulatory' | 'marketing': Which product's guidance to extract with.

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/kobaltlabs/apis/kobaltlabs-api.md) - [All operations](https://skmtc.dev/kobaltlabs/apis/kobaltlabs-api/llms.txt) - [OpenAPI document](https://skmtc.dev/kobaltlabs/apis/kobaltlabs-api/revisions/8587332d5e43?raw)
