Claude Batch logo

Claude Batch

Organization
UitbreidenOS
claude-batch

Run large-scale batch processing with Claude API for bulk text analysis, classification, and generation

Overview

PublisherUitbreidenOS
RepositoryUitKit
Skill nameclaude-batch
Stars
14
Forks
5
Bundled files
Instructions only
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by UitbreidenOS on GitHub. Read the source before you install it.

Installation

Install the Claude Batch AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/UitbreidenOS/UitKit/tree/main/plugins/uitkit-ai-engineering/skills/claude-batch
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/UitbreidenOS/UitKit.git /tmp/UitKit
mkdir -p .claude/skills
cp -r /tmp/UitKit/plugins/uitkit-ai-engineering/skills/claude-batch .claude/skills/claude-batch
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Claude Batch in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Claude Batch on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Claude Batch is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Claude Batch

When to activate

Processing large volumes of prompts (10 or more), non-time-sensitive workloads, or when the user wants to reduce API costs for bulk operations like document processing, evaluations, or dataset annotation.

When NOT to use

  • Real-time or latency-sensitive applications — batch processing takes up to 24 hours
  • Workflows where each result must feed the next request — use synchronous streaming instead
  • Fewer than 10 requests — synchronous API overhead is negligible at that scale

Instructions

Batch API Overview

  • Submit up to 10,000 requests per batch
  • 50% cost discount vs synchronous Messages API
  • Processing completes within 24 hours (usually much faster for small batches)
  • Results delivered as a JSONL stream when processing completes
  • Failed individual requests do not fail the batch

Request Format

Each item in the batch has:

  • custom_id: your identifier — used to match results back to inputs
  • params: standard Messages API parameters (model, max_tokens, messages, system, tools, etc.)
python
import anthropic

client = anthropic.Anthropic()

requests = [
    {
        "custom_id": f"doc-{i}",
        "params": {
            "model": "claude-opus-4-5",
            "max_tokens": 1024,
            "messages": [
                {"role": "user", "content": f"Summarize this document: {doc}"}
            ],
        },
    }
    for i, doc in enumerate(documents)
]

Submitting a Batch

python
batch = client.messages.batches.create(requests=requests)
print(batch.id)           # msgbatch_...
print(batch.processing_status)  # "in_progress"

Polling for Completion

python
import time

def wait_for_batch(batch_id: str) -> anthropic.MessageBatch:
    while True:
        batch = client.messages.batches.retrieve(batch_id)
        if batch.processing_status == "ended":
            return batch
        print(f"Status: {batch.processing_status} — waiting 30s")
        time.sleep(30)

batch = wait_for_batch(batch.id)
print(f"Request counts: {batch.request_counts}")
# RequestCounts(canceled=0, errored=1, expired=0, processing=0, succeeded=199)

Retrieving Results

python
# Results stream as JSONL — iterate without loading all into memory
for result in client.messages.batches.results(batch.id):
    if result.result.type == "succeeded":
        message = result.result.message
        print(f"{result.custom_id}: {message.content[0].text[:100]}")
    elif result.result.type == "errored":
        error = result.result.error
        print(f"{result.custom_id}: ERROR {error.type} — {error.message}")
    elif result.result.type == "expired":
        print(f"{result.custom_id}: EXPIRED — resubmit")

Result Types

TypeMeaningAction
succeededNormal completionUse result.message
erroredAPI-level error (invalid params, content policy)Log and skip or retry
expired24-hour window elapsed before processingResubmit the request

Canceling a Batch

python
client.messages.batches.cancel(batch.id)
# Already-completed requests are not rolled back — partial results may exist

Rate Limits

  • 10,000 requests per batch
  • 100 concurrent batches (in-progress at once)
  • Batch rate limits are separate from synchronous API rate limits — submitting batches does not count against your synchronous quota

Use Cases and Sizing

Use caseTypical batch sizeEst. turnaround
Document summarization100–5,000Minutes–hours
Eval run over test set500–10,000Hours
Dataset annotation1,000–10,000Hours
Bulk content generation50–2,000Minutes–hours

Production Pattern: Queue + Batch

For ongoing high-volume workloads, combine a job queue with the batch API:

  1. Enqueue items as they arrive
  2. Every N minutes (or when queue hits 500+), flush queue into a batch
  3. Store batch_id → custom_id[] mapping in a database
  4. Poll batch status on a cron, write results to DB when processing_status == "ended"
  5. Expose results via an API to downstream consumers

Example

Annotating 2,000 customer support tickets with sentiment and category:

python
tickets = load_tickets_from_db()  # 2,000 rows

requests = [
    {
        "custom_id": str(ticket["id"]),
        "params": {
            "model": "claude-haiku-4-5",
            "max_tokens": 64,
            "system": "Respond with JSON only: {\"sentiment\": \"positive|neutral|negative\", \"category\": \"billing|technical|general\"}",
            "messages": [{"role": "user", "content": ticket["text"]}],
        },
    }
    for ticket in tickets
]

batch = client.messages.batches.create(requests=requests)
batch = wait_for_batch(batch.id)

results = {}
for result in client.messages.batches.results(batch.id):
    if result.result.type == "succeeded":
        import json
        data = json.loads(result.result.message.content[0].text)
        results[result.custom_id] = data

save_annotations_to_db(results)
# Total cost: ~50% less than running 2,000 synchronous calls

Frequently asked questions

What does the Claude Batch AI skill do?

Run large-scale batch processing with Claude API for bulk text analysis, classification, and generation

Why use Claude Batch on TypingMind?

Because you install it once and use it with any model. Claude Batch is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Claude Batch in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/UitbreidenOS/UitKit/tree/main/plugins/uitkit-ai-engineering/skills/claude-batch. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Claude Batch?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Claude Batch?

As many as you like. As long as a model supports skills, you can use Claude Batch with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Claude Batch AI skill free?

It is published on GitHub by UitbreidenOS. Check the repository for licensing terms. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇