Logo di Caveman Token Reduction

Caveman Token Reduction

Organizzazione
UitbreidenOS
caveman-token-reduction

Claude Code Caveman mode: token-efficient communication, compressed responses, minimal output for context-heavy sessions, terse acknowledgments, and context budget optimization

Add to TypingMind

Panoramica

Pubblicato daUitbreidenOS
RepositoryUitKit
Nome della skillcaveman-token-reduction
Stelle
14
Fork
5
File inclusi
Solo istruzioni
Link
  • Istruzioni in Markdown

    Un file SKILL.md che il modello carica quando serve, consumando token solo quando una richiesta è effettivamente pertinente.

  • Funziona con qualsiasi LLM

    Le skill IA sono in semplice Markdown, non in codice specifico di un fornitore, quindi funzionano con GPT, Claude, Gemini, Grok o un modello locale.

  • Tutto nelle istruzioni

    Tutto ciò che serve al modello è nelle istruzioni: nessun file aggiuntivo da sincronizzare.

  • Open source

    Pubblicata da UitbreidenOS su GitHub. Leggi i sorgenti prima di installarla.

Installazione

Installa la skill IA Caveman Token Reduction in TypingMind per usarla con qualsiasi LLM, oppure copiala in un altro agente in grado di leggere SKILL.md.

1

Installa in TypingMind

TypingMind installa una skill direttamente dalla sua cartella GitHub: legge SKILL.md, raccoglie i file delle risorse e salva il risultato in locale.

  1. Apri l'app e vai su Plugin → Skill.
  2. Scegli "Installa da GitHub".
  3. Incolla l'URL della cartella della skill riportato qui sotto e conferma.
    https://github.com/UitbreidenOS/UitKit/tree/main/plugins/uitkit-ai-engineering/skills/caveman-token-reduction
  4. Attiva la skill in ogni chat in cui vuoi averla a disposizione.
Plugin → Skill → Aggiungi skill → Da URL GitHub, poi incolla l'URL della cartella e premi Continua.
2

Installa in un altro agente

Qualsiasi agente che legge il formato Agent Skills può usare questa skill: copia la cartella della skill nella directory delle skill di quell'agente.

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/caveman-token-reduction .claude/skills/caveman-token-reduction
Dopo la copia, riavvia Claude Code per caricare la nuova skill.

Usala in TypingMind

Attiva Caveman Token Reduction in qualsiasi chat di TypingMind e al resto pensa il modello. Il nome e la descrizione della skill sono nel prompt di sistema e, non appena arriva una richiesta pertinente, il modello carica da solo le istruzioni complete: non devi mai richiamarla manualmente e non consuma token finché non viene effettivamente usata.

Il modello carica automaticamente Caveman Token Reduction non appena riceve una richiesta pertinente.

Funziona con qualsiasi modello IA

Le skill IA sono semplici istruzioni in Markdown, non codice specifico di un fornitore, quindi Caveman Token Reduction non è vincolata al modello per cui è stata scritta. Installala una sola volta in TypingMind e usala con GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama o un modello locale che esegui tu, sempre con le tue chiavi API.

  • Caricata solo quando serve

    Il prompt di sistema contiene solo il nome e la descrizione. Le istruzioni vengono recuperate alla prima richiesta pertinente, quindi una skill inutilizzata non costa nulla.

  • Cambia modello durante la chat

    Poiché la skill è composta da istruzioni e non da codice, continua a funzionare anche se cambi modello: il nuovo modello legge lo stesso file SKILL.md.

Istruzioni della skill

Questo è il contenuto di SKILL.md che il modello carica. Leggilo prima dell'installazione: una skill è un insieme di istruzioni che il tuo modello seguirà.

Caveman — Token Reduction Mode

When to activate

  • Context window is above 70% capacity and you need to extend the session
  • Working on a large codebase where tool outputs (file reads, grep results) dominate context
  • Multi-step tasks where intermediate responses waste context budget
  • User explicitly requests terse/minimal responses
  • Running cost-sensitive sessions where token usage matters
  • Long debugging sessions where you need maximum context for logs and traces

When NOT to use

  • First interaction on a new session with plenty of context headroom
  • When the user is learning and needs detailed explanations
  • Documentation generation or tutorial writing (verbosity is the product)
  • When communicating with stakeholders who need full context
  • Complex architectural discussions that require nuanced reasoning

Instructions

1. Response Compression Levels

LevelNameTokens/responseUse when
0Normal200-500Default, ample context
1Concise50-150Context > 50%, routine tasks
2Terse15-50Context > 70%, repetitive operations
3Caveman5-15Context > 85%, emergency mode

2. Level 1: Concise Mode

Normal response:

I've reviewed the authentication middleware in src/auth/middleware.ts. 
There are three issues I found:
1. The JWT verification on line 23 doesn't check the token expiration, 
   which means expired tokens will still be accepted.
2. The error handler on line 45 catches all errors but returns a generic 
   500 instead of distinguishing between auth failures and server errors.
3. The CORS configuration allows all origins, which is too permissive 
   for production.

I recommend fixing these in order of severity. Want me to proceed?

Concise response:

src/auth/middleware.ts — 3 issues:
1. L23: JWT expiry not checked (expired tokens accepted)
2. L45: Generic 500 for all errors (should be 401 vs 500)
3. L12: CORS allows all origins (too permissive for prod)

Fix in order?

3. Level 2: Terse Mode

auth/middleware.ts: 3 bugs
- L23: no expiry check
- L45: 500 for all errors (need 401/500 split)
- L12: CORS wildcard (prod risk)
Fix?

4. Level 3: Caveman Mode

auth fix: 3 bugs (L12,L23,L45). Fix all?

5. Acknowledgment Compression

FullConciseTerseCaveman
"I've completed the task and all tests are passing.""Done. Tests pass.""Done ✓""✓"
"I've read the file and understand the structure.""Read.""Read""👁"
"That file doesn't exist, let me search for it.""Not found. Searching...""Missing, searching""∅→🔍"
"I've made the requested changes and committed them.""Committed.""Committed""git✓"

6. Tool Output Compression

Compress grep/read results before including in response:

yaml
compression_rules:
  file_reads:
    - omit_lines: "unchanged/import/header"
    - show_only: "modified + context (3 lines)"
    - max_lines: 30  # never show more than 30 lines from a read
    
  grep_results:
    - max_matches: 10  # summarize beyond this
    - group_by: "file"
    - format: "file:line:match (not full line content)"
    
  bash_output:
    - tail_lines: 20   # last 20 lines of output
    - on_success: "exit 0"  # just the exit code
    - on_failure: "last 20 lines + exit code"

7. Context Budget Management

Monitor and report context usage:

yaml
context_monitor:
  check_every: 10_turns
  thresholds:
    50_percent: "switch to concise"
    70_percent: "switch to terse, summarize old context"
    85_percent: "switch to caveman, aggressively compress"
    95_percent: "suggest handoff to new session"
  
  report_format: "ctx: 72% | mode: terse | ~45 turns remaining"

Automatic context cleanup:

yaml
auto_cleanup:
  when: "context > 70%"
  actions:
    - summarize_conversation: "compress turns 1-50 into 10-line summary"
    - drop_tool_results: "keep only most recent 5 tool outputs in full"
    - compress_file_reads: "replace full reads with line-range references"

8. Batch Operation Compression

Instead of reporting each step in a batch:

Normal:
  1/10: Created src/api/users.ts ✓
  2/10: Created src/api/products.ts ✓
  3/10: Created src/api/orders.ts ✓
  ...

Caveman:
  10/10 files created ✓

Instead of confirming each file read:

Normal:
  Read package.json (45 lines)
  Read tsconfig.json (22 lines)
  Read .eslintrc.json (18 lines)

Caveman:
  Read 3 configs ✓

9. When to Expand Back

Automatically return to normal verbosity when:

  • User asks a conceptual question ("Why did you choose X?")
  • User says "explain" or "more detail"
  • A critical error occurs that needs full context
  • Context usage drops below 40% (after summarization/cleanup)
  • Starting a new task within the same session

Example

Long debugging session in caveman mode:

User: "The API is returning 500 on /users endpoint. Debug it."

Agent (normal): Read error logs, identified 3 issues in the request chain...
User: "Go caveman mode, we have a lot to debug"

Agent: "logs: 3 errs. L47 null ref in userRepo. Fix?"
User: "yes"
Agent: "fixed. Test?"
User: "still failing"
Agent: "err2: L82 missing await. Fix?"
User: "yes"  
Agent: "fixed. ctx:68% mode:terse ~60 turns left"
User: "next error?"
Agent: "L115: unhandled promise reject in cache. wrap try/catch?"
User: "do it"
Agent: "✓ /users returns 200. All 3 fixed."

Anti-Patterns

  • Caveman by default: Starting every session in caveman mode hurts onboarding and discoverability — use only when context pressure is real
  • Losing meaning: Compressing so aggressively that the response becomes ambiguous — "fix?" is fine, "?" alone is not
  • Ignoring user preference: Staying in caveman mode when user asks for details — always expand when asked
  • Compression without context: Using caveman mode with a new user who doesn't understand the abbreviations — match the user's familiarity level
  • Premature summarization: Summarizing tool outputs that you'll need in full later — only compress results you've already processed
  • Silent context overflow: Not warning the user when context is critical — always report context status at terse/caveman levels

Domande frequenti

Cosa fa la skill IA Caveman Token Reduction?

Claude Code Caveman mode: token-efficient communication, compressed responses, minimal output for context-heavy sessions, terse acknowledgments, and context budget optimization

Perché usare Caveman Token Reduction su TypingMind?

Perché la installi una volta e la usi con qualsiasi modello. Caveman Token Reduction è scritta in semplice Markdown anziché in codice specifico di un fornitore, quindi la stessa skill funziona con GPT-5, Claude, Gemini, Grok o un modello locale, e puoi cambiare modello durante la chat senza che la skill smetta di funzionare. TypingMind usa le tue chiavi API, quindi paghi direttamente i fornitori anziché un abbonamento per posto utente, e le tue skill e chat restano nel tuo spazio di archiviazione.

Come installo Caveman Token Reduction in TypingMind?

Apri Plugin → Skill → Installa da GitHub in TypingMind e incolla https://github.com/UitbreidenOS/UitKit/tree/main/plugins/uitkit-ai-engineering/skills/caveman-token-reduction. TypingMind legge il file SKILL.md e installa la skill, che puoi abilitare per ogni singola chat.

Quali modelli IA possono usare Caveman Token Reduction?

Qualsiasi modello che colleghi a TypingMind. Le skill IA sono semplici istruzioni in Markdown anziché codice specifico di un fornitore, quindi GPT, Claude, Gemini, Grok e i modelli locali possono tutti caricare questa skill quando una richiesta corrisponde al suo scopo.

Quanti modelli IA posso usare con Caveman Token Reduction?

Quanti ne vuoi. Se un modello supporta le skill, puoi usarlo con Caveman Token Reduction: GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama e molti altri, tutti su TypingMind con le tue chiavi API.

La skill IA Caveman Token Reduction è gratuita?

È pubblicata su GitHub da UitbreidenOS. Consulta il repository per i termini di licenza. Paghi solo il tuo fornitore IA per i token che usi.

Cosa sono le skill IA?

Una skill IA è un pacchetto di istruzioni riutilizzabili che insegna a un modello IA come svolgere un'attività specifica. Segue il formato aperto Agent Skills: un file SKILL.md con un nome e una descrizione, più eventuali script, template o file di riferimento di cui il modello potrebbe aver bisogno. Il modello legge le istruzioni solo quando la tua richiesta corrisponde alla skill, quindi una skill installata non comporta costi finché non viene usata.

In cosa si differenziano le skill IA dai plugin o dai server MCP?

Un plugin o un server MCP fornisce a un modello nuovi strumenti da richiamare: codice che viene eseguito da qualche parte e restituisce un risultato. Una skill IA, invece, fornisce al modello conoscenze e procedure: come affrontare un'attività, quali passaggi seguire e quali caratteristiche deve avere un buon output. Le skill sono semplici istruzioni in Markdown, quindi non richiedono server, chiavi API né ambienti di esecuzione e funzionano con qualsiasi modello.

Elenco completo

Crea subito il tuo spazio di lavoro AI

Iscriviti alla nostra newsletter per ricevere aggiornamenti sulle nuove funzionalità e sulle prossime iniziative a premi 👇