Skip to main content
Glama

Classify texts into one label each

classify_texts

Sort up to 1,000 texts into exactly one of your own labels each, with confidence per answer. Use this when you have many items to triage, route, filter or bucket and do not want to read them all: search results before opening them, tickets, log lines, changed files, feedback. Do not use it for fewer than about five items you can already see — just decide. For default Jev, confidence is calibrated (answers >= 0.9 are right ~82-92% of the time; < 0.5 about 30-60%); these measurements do not apply to experimental Laya. so act on the sure ones and look at the rest yourself, or pass tier "smart" to have the unsure ones re-asked of a reasoning model.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoScrape one public URL instead of inputs/items. Requires funded workspace access. Context.dev costs $0.0022 per billed attempt plus classification; long articles need Fast. Errors disclose retained charges. No automatic scrape retries.
tierNofast (default) or smart, which re-asks answers under 0.7 confidence of a reasoning model (slower, single-label only). Independent of the Laya processing lane.
modelNoJev is default. Default/explicit jev inputs over 32,000 characters use paid Fast-only long context: up to 250,000 original cl100k_base context tokens total, 20 documents, 32 decisions and a 1 MB body. Requires paid workspace balance or active paid subscription, not signup credit. $0.084/M original context tokens counted once across inputs, independent of dimensions. Final Jev uses selected evidence; eligible chunks may be omitted, disclosed in usage.long_context. No evidence returns 422 long_context_no_evidence without charge. Explicit 'chunklaya' retains legacy opt-in (4,000,000 characters/input, 20 inputs, subject to body limit). 'laya' (512-token context) and 'kev' (8K context) remain experimental alternatives.
inputsNo1 to 1,000 texts to classify. Results come back in the same order.
labelsYes2 to 100 category names. Descriptive names classify better: "urgent bug" beats "p0". Add a label like "none of these" when none-of-the-above is a real outcome.
includeNoWith url: return article.markdown and/or article.html at no extra scrape cost. Omit for compact output.
processingNoOptional. Implies Laya if model is omitted; has no effect with explicit Jev. With Laya, omit to select fast for one decision or bulk for batches automatically. Explicit fast accepts one decision. Shared capacity limits can return 429.
share_dataNoSynchronous classification request text, labels, instructions and model results are retained for model training and operator review in private Cloudflare storage by default. Shared requests receive double per-minute and daily classification quotas. Set share_data: false or X-Classifier-Share-Data: false to opt out and use standard limits. Share only data you have permission to contribute; do not include confidential or personal information. Redaction is best effort. Billing, spending caps and input-size limits still apply.
instructionsNoOptional extra criteria, e.g. "judge only the service, ignore the food".

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
tierNo
modelNo
usageNo
resultsYesOne per input, in input order.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / share_data / default
      Previous value: -falseNew value: +true
    • changedInput schema / properties / share_data / description
      Previous value: -"Opt in to retaining this request's text, labels, instructions and model results for model training and operator review in private Cloudflare storage. Doubles per-minute and daily classification quotas. Off by default. Share only data you have permission to contribute; do not include confidential or personal information. Redaction is best effort. Billing, spending caps and input-size limits still apply."New value: +"Synchronous classification request text, labels, instructions and model results are retained for model training and operator review in private Cloudflare storage by default. Shared requests receive double per-minute and daily classification quotas. Set share_data: false or X-Classifier-Share-Data: false to opt out and use standard limits. Share only data you have permission to contribute; do not include confidential or personal information. Redaction is best effort. Billing, spending caps and input-size limits still apply."
  2. Changed1 schema field changed
    • addedInput schema / properties / share_data
      Added value: +{
      +  "default": false,
      +  "description": "Opt in to retaining this request's text, labels, instructions and model results for model training and operator review in private Cloudflare storage. Doubles per-minute and daily classification quotas. Off by default. Share only data you have permission to contribute; do not include confidential or personal information. Redaction is best effort. Billing, spending caps and input-size limits still apply.",
      +  "type": "boolean"
      +}
  3. Changed4 schema fields changed
    • addedInput schema / oneOf
      Added value: +[
      +  {
      +    "not": {
      +      "required": [
      +        "url"
      +      ]
      +    },
      +    "required": [
      +      "inputs"
      +    ]
      +  },
      +  {
      +    "not": {
      +      "required": [
      +        "inputs"
      +      ]
      +    },
      +    "required": [
      +      "url"
      +    ]
      +  }
      +]
    • addedInput schema / properties / include
      Added value: +{
      +  "description": "With url: return article.markdown and/or article.html at no extra scrape cost. Omit for compact output.",
      +  "items": {
      +    "enum": [
      +      "markdown",
      +      "html"
      +    ],
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / url
      Added value: +{
      +  "description": "Scrape one public URL instead of inputs/items. Requires funded workspace access. Context.dev costs $0.0022 per billed attempt plus classification; long articles need Fast. Errors disclose retained charges. No automatic scrape retries.",
      +  "maxLength": 8192,
      +  "pattern": "^https?://",
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "inputs",
      -  "labels"
      -]New value: +[
      +  "labels"
      +]
  4. Changed1 schema field changed
    • changedInput schema / properties / model / description
      Previous value: -"Optional models: 'laya' (ModernBERT-large, 512-token context) or 'kev' (Qwen2.5-0.5B with a pointer head, 8K context), or 'chunklaya', our long-document model (up to 4,000,000 characters, 20 inputs per request), which is also chosen automatically for any input over 32,000 characters. Jev remains the default."New value: +"Jev is default. Default/explicit jev inputs over 32,000 characters use paid Fast-only long context: up to 250,000 original cl100k_base context tokens total, 20 documents, 32 decisions and a 1 MB body. Requires paid workspace balance or active paid subscription, not signup credit. $0.084/M original context tokens counted once across inputs, independent of dimensions. Final Jev uses selected evidence; eligible chunks may be omitted, disclosed in usage.long_context. No evidence returns 422 long_context_no_evidence without charge. Explicit 'chunklaya' retains legacy opt-in (4,000,000 characters/input, 20 inputs, subject to body limit). 'laya' (512-token context) and 'kev' (8K context) remain experimental alternatives."
  5. Changed2 schema fields changed
    • changedInput schema / properties / model / description
      Previous value: -"Optional Beam-hosted models: 'laya' (ModernBERT-large, 512-token context) or 'kev' (Qwen2.5-0.5B with a pointer head, 8K context). Jev remains the default."New value: +"Optional models: 'laya' (ModernBERT-large, 512-token context) or 'kev' (Qwen2.5-0.5B with a pointer head, 8K context), or 'chunklaya', our long-document model (up to 4,000,000 characters, 20 inputs per request), which is also chosen automatically for any input over 32,000 characters. Jev remains the default."
    • changedInput schema / properties / model / enum
      Previous value: -[
      -  "jev",
      -  "laya",
      -  "kev"
      -]New value: +[
      +  "jev",
      +  "laya",
      +  "kev",
      +  "chunklaya"
      +]
  6. Changed2 schema fields changed
    • changedInput schema / properties / model / description
      Previous value: -"Optional Laya trial with automatic English/multilingual checkpoint routing; Jev remains the default."New value: +"Optional Beam-hosted models: 'laya' (ModernBERT-large, 512-token context) or 'kev' (Qwen2.5-0.5B with a pointer head, 8K context). Jev remains the default."
    • changedInput schema / properties / model / enum
      Previous value: -[
      -  "jev",
      -  "laya"
      -]New value: +[
      +  "jev",
      +  "laya",
      +  "kev"
      +]
  7. Changed1 schema field changed
    • changedInput schema / properties / processing / description
      Previous value: -"Laya only: fast accepts one decision; bulk handles batches. Shared capacity limits can return 429."New value: +"Optional. Implies Laya if model is omitted; has no effect with explicit Jev. With Laya, omit to select fast for one decision or bulk for batches automatically. Explicit fast accepts one decision. Shared capacity limits can return 429."
  8. Changed1 schema field changed
    • changedInput schema / properties / model / description
      Previous value: -"Optional English Laya trial; Jev remains the default."New value: +"Optional Laya trial with automatic English/multilingual checkpoint routing; Jev remains the default."
  9. Changed4 schema fields changed
    • addedInput schema / properties / model
      Added value: +{
      +  "description": "Optional English Laya trial; Jev remains the default.",
      +  "enum": [
      +    "jev",
      +    "laya"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / processing
      Added value: +{
      +  "description": "Laya only: fast accepts one decision; bulk handles batches. Shared capacity limits can return 429.",
      +  "enum": [
      +    "fast",
      +    "bulk"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / tier / description
      Previous value: -"fast (default, ~1s per 1,000) or smart, which re-asks answers under 0.7 confidence of a reasoning model (slower, single-label only)."New value: +"fast (default) or smart, which re-asks answers under 0.7 confidence of a reasoning model (slower, single-label only). Independent of the Laya processing lane."
    • changedOutput schema / properties / results / items / properties / confidence / description
      Previous value: -"0-1, calibrated. Null when the provider returns no score or the smart tier replaces the scored answer."New value: +"0-1; calibration measurements cover Jev, not experimental Laya. Null when the provider returns no score or the smart tier replaces the scored answer."
  10. Changed2 schema fields changed
    • changedOutput schema / properties / results / items / properties / confidence / description
      Previous value: -"0-1, calibrated. Null for unreadable inputs or smart-escalated answers without comparable probabilities."New value: +"0-1, calibrated. Null when the provider returns no score or the smart tier replaces the scored answer."
    • changedOutput schema / properties / results / items / properties / scores / description
      Previous value: -"Probability per label; sums to 1."New value: +"Model preference per supplied label; sums to 1. Does not validate the input or guarantee correctness."
  11. Changed1 schema field changed
    • changedOutput schema / properties / results / items / properties / confidence / description
      Previous value: -"0-1, calibrated. Null when the input does not read as natural language."New value: +"0-1, calibrated. Null for unreadable inputs or smart-escalated answers without comparable probabilities."
  12. First observed

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Adds substantial behavior beyond the annotations: calibrated confidence bands for the default model (>=0.9 right ~82-92%, <0.5 about 30-60%), the caveat that these do not apply to Laya, and the 'smart' tier re-asking low-confidence answers. Annotations only say openWorld/not-idempotent/not-destructive, so the calibration and routing guidance is genuinely new information.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose and scope are front-loaded in the first clause, and most sentences carry load-bearing content. The final sentence is a long run-on beginning with lowercase 'so' and mixes calibration, action advice, and tier behavior, which slightly hurts readability.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 9-parameter, single-label classifier with an output schema, the description covers the decision-relevant essentials: batching limits, confidence interpretation, tier/model implications, and the share_data training caveat. Return values are already covered by the output schema, so nothing critical is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3, but the description adds actionable meaning: it explains what to do with the confidence values ('act on the sure ones... or pass tier "smart"'), which complements rather than repeats the schema's per-parameter text.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (sort/classify), the resource (texts), and the exact cardinality constraint: up to 1,000 texts into exactly one label each with confidence. The 'exactly one' phrasing implicitly distinguishes it from the multi-label and dimensions siblings, so an agent can select it without consulting them.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives concrete use cases (triage, route, filter, bucket; search results, tickets, log lines, changed files, feedback) and an explicit exclusion threshold ('do not use it for fewer than about five items you can already see'). It never names a sibling tool as the alternative for those cases, which is the only gap.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.