> For the complete documentation index, see [llms.txt](https://docs.teleskope.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.teleskope.ai/the-platform/api-service/scanning-api/v1-classify-verbose.md).

# v1/classify-verbose

Classifies text and returns detailed match-level diagnostics for each candidate, including accepted and rejected matches with scores, regex patterns, and validation results. Use this endpoint when debugging classification results or tuning filters. To classify without diagnostics, use [v1/classify](/the-platform/api-service/scanning-api/v1-classify.md).

{% openapi src="/files/cGyOSqpybs6wM3Oy8JMJ" path="/v1/classify-verbose" method="post" %}
[{"openapi":"3.12.json](https://2383928706-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FgO8NOoWqwRd6MduHoEy7%2Fuploads%2Fgit-blob-8868525e0357b58fd3f49b11e1b4d888773e49fc%2F%7B%22openapi%22%3A%223.12.json?alt=media)
{% endopenapi %}

## Body options

| Field               | Type      | Description                                                                                                                          |
| ------------------- | --------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| `content`           | string    | Text to classify. Required.                                                                                                          |
| `filters`           | string\[] | Allow-list of element labels to report. Omit to report every supported element.                                                      |
| `excludeFilters`    | string\[] | Deny-list of element labels to skip. Takes precedence over `filters`.                                                                |
| `sensitivityLevels` | string\[] | Restrict results to these tiers: `low`, `medium`, `high`, `critical`. Elements with no assigned tier are always included.            |
| `focusEntity`       | string    | Restrict verbose diagnostics to matches for this element label. Other elements are still classified and appear in `classifications`. |
| `focusStart`        | integer   | Byte offset into `content` to begin verbose tracking. Defaults to 0.                                                                 |
| `focusEnd`          | integer   | Byte offset into `content` to end verbose tracking. Defaults to end of content.                                                      |

`useML` and `treatAsJSON` are not supported on this endpoint.

***

## Response fields

| Field                | Type              | Description                                                                                                    |
| -------------------- | ----------------- | -------------------------------------------------------------------------------------------------------------- |
| `content`            | string            | The original content submitted.                                                                                |
| `classifications`    | Classification\[] | Accepted matches, same shape as [v1/classify](/the-platform/api-service/scanning-api/v1-classify.md) response. |
| `accepted_matches`   | VerboseMatch\[]   | All candidates that passed scoring, validation, and overlap resolution.                                        |
| `rejected_matches`   | VerboseMatch\[]   | Candidates that were considered but did not make the final result.                                             |
| `ml_classifier_used` | boolean           | Whether the ML classifier ran.                                                                                 |
| `scanner_version`    | string            | Version of the scanner that produced the result.                                                               |
| `focus_entity`       | string            | The `focusEntity` value echoed back, if provided.                                                              |
| `focus_offset_start` | integer           | The `focusStart` value echoed back, if provided.                                                               |
| `focus_offset_end`   | integer           | The `focusEnd` value echoed back, if provided.                                                                 |

### VerboseMatch fields

Each object in `accepted_matches` and `rejected_matches` describes one candidate.

| Field                  | Type      | Description                                                                                                                                           |
| ---------------------- | --------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| `entity`               | string    | Element label for this candidate.                                                                                                                     |
| `start_byte`           | integer   | Byte offset of the match within `content`.                                                                                                            |
| `end_byte`             | integer   | Byte offset of the end of the match within `content`.                                                                                                 |
| `text`                 | string    | Matched text, if available.                                                                                                                           |
| `score`                | float     | Confidence score.                                                                                                                                     |
| `is_accepted`          | boolean   | `true` if this candidate is also in `classifications`.                                                                                                |
| `regex_used`           | string    | The regex pattern that matched, if any.                                                                                                               |
| `regex_id`             | integer   | ID of the matched regex rule.                                                                                                                         |
| `regex_quality`        | string    | Quality tier of the matched regex.                                                                                                                    |
| `context_matches`      | string\[] | Context keywords that boosted or triggered the match.                                                                                                 |
| `context_score`        | float     | Combined context score.                                                                                                                               |
| `validation_tests`     | string\[] | Names of validation checks applied.                                                                                                                   |
| `validation_passed`    | boolean   | Whether all validation checks passed.                                                                                                                 |
| `exclusion_reason`     | string    | Reason this candidate was excluded, if rejected.                                                                                                      |
| `exclusion_details`    | string    | Additional detail about the exclusion.                                                                                                                |
| `context_exclusion_id` | integer   | ID of the context exclusion rule that dropped this match, if any.                                                                                     |
| `regex_exclusion_id`   | integer   | ID of the regex exclusion rule that dropped this match, if any.                                                                                       |
| `is_ml_classified`     | boolean   | Whether the ML classifier contributed to this candidate.                                                                                              |
| `ml_confidence`        | float     | ML model confidence score, if applicable.                                                                                                             |
| `overlapped_by`        | object    | Present when this candidate was dropped because a longer overlapping match won. Contains `entity`, `start_byte`, and `end_byte` of the winning match. |
| `processing_stage`     | string    | Pipeline stage at which this candidate was dropped, if rejected.                                                                                      |

Fields marked as optional are omitted from the response when empty or zero.

***

## Related

* [v1/classify](/the-platform/api-service/scanning-api/v1-classify.md) — classify without diagnostics.
* [v1/classify-file](/the-platform/api-service/scanning-api/v1-classify-file.md) — classify an uploaded file.
* [Entity Taxonomy](/specifications/entity-taxonomy-v2.md) — valid element labels for `filters`, `excludeFilters`, and `focusEntity`.
