Agent skill

Opencode Mistral Cache Key

by OnlyTerp in OnlyTerp/prompt-cache-skills

OpenCode doesn't set promptcachekey for Mistral models, missing the documented 10% cached-token discount.

Custom licenceAuto-check passedAI & LLM Engineering

Install Opencode Mistral Cache Key

skills CLI
$ npx skills add OnlyTerp/prompt-cache-skills --skill opencode-mistral-cache-key -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install OnlyTerp/prompt-cache-skills opencode-mistral-cache-key --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/OnlyTerp/prompt-cache-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/opencode-mistral-cache-key .claude/skills/opencode-mistral-cache-key && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
opencode-mistral-cache-key
GitHub stars
114
Token cost
~638 tokens
SKILL.md length
212 words
Files
1
Skills in repo
13
Repo updated
First seen
Licence
Custom licence

At a glance

OpenCode doesn't set promptcachekey for Mistral models, missing the documented 10% cached-token discount.

  • Works in 6 steps: Configure OpenCode with… → Send two identical prompts. → Capture wire to Mistral. → …
  • Tasks that involve LLM cost and token optimization
  • SKILL.md covers Target, Symptom, Fix and Verify, plus 1 more section
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Opencode Mistral Cache Key is an agent skill from OnlyTerp/prompt-cache-skills. OpenCode doesn't set promptcachekey for Mistral models, missing the documented 10% cached-token discount.

Its SKILL.md is about 640 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in AI & LLM Engineering, covering LLM cost and token optimization. It works with Mistral AI and OpenAI. The repository describes itself as: Drop-in prompt-caching fixes for the LLM agent harness you use. Point your AI coding agent at this repo and it ships the patches.

When your agent uses it

  • Tasks that involve LLM cost and token optimization

Example prompts

  • “/opencode-mistral-cache-key”

Workflow steps

6 steps, taken from the first numbered list in SKILL.md.

  1. Configure OpenCode with mistral-large-latest or similar.
  2. Send two identical prompts.
  3. Capture wire to Mistral.
  4. Before fix: request body has no prompt_cache_key field.
  5. After fix: prompt_cache_key field present and identical
  6. Inspect response usage for cached-token indicators (Mistral

What it can do on your machine

Read from SKILL.md and the folder at commit 5b58ae2. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are diff).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Opencode Mistral Cache Key loads about 638 tokens when it runs. Until then it costs about 34 tokens; SKILL.md has 212 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~34
When it runs · the whole SKILL.md, loaded when a task matches
~638

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 212 words (~638 tokens).

name
opencode-mistral-cache-key
target_harness
OpenCode
target_repo
sst/opencode
target_files
packages/opencode/src/provider/transform.ts
target_commit
dev branch @ a9ef5a0f
estimated_savings
90% input discount on Mistral cached tokens (currently 0%)

Read the full SKILL.md on GitHub

Files

Just SKILL.md in skills/opencode-mistral-cache-key of OnlyTerp/prompt-cache-skills.

Open the folder on GitHubat commit 5b58ae2

Compare with similar skills

Opencode Mistral Cache Key next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Opencode Mistral Cache Key compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Opencode Mistral Cache Key this skillOnlyTerp/prompt-cache-skills114—~638Automated safety check: PassCustom licence
Embeddings via 9Routerdecolua/9router30k—~604Automated safety check: PassMIT
Agents Best PracticesDenisSergeevitch/agents-best-practices2.4k—~7.4kAutomated safety check: PassMIT
Bridgic LLMsbitsky-tech/bridgic155—~839Automated safety check: NotesMIT
Vibepcx-wave/vibe-skill119—~7.2kAutomated safety check: NotesMIT
Keiroutermydisha/keirouter147—~995Automated safety check: PassMIT

Similar skills

  • Embeddings via 9Router

    decolua/9router

    Generates vector embeddings through the 9Router /v1/embeddings endpoint, using models from providers such as OpenAI, Gemini, Mistral and Voyage for RAG and semantic search.

    30k GitHub stars~604 tokensUpdated 6 days ago
    AI & LLM EngineeringAuto-check passed
  • Agents Best Practices

    DenisSergeevitch/agents-best-practices

    A skill your agent uses when designing, generating an MVP blueprint for, auditing, troubleshooting, refactoring, or explaining an agentic harness for any domain.

    2.4k GitHub stars~7.4k tokensUpdated 2 days ago
    AI & LLM EngineeringAuto-check passed
  • Bridgic LLMs

    bitsky-tech/bridgic

    LLM provider initialization for bridgic projects. An agent skill from bitsky-tech/bridgic.

    155 GitHub stars~839 tokensUpdated 2 mo ago
    AI & LLM EngineeringAuto-check: notes
  • Vibe

    pcx-wave/vibe-skill

    Delegate a coding task to Mistral Vibe and supervise the result via git diff.

    119 GitHub stars~7.2k tokensUpdated 6 days ago
    AI & LLM EngineeringAuto-check: notes
  • Keirouter

    mydisha/keirouter

    Entry point for KeiRouter — local/remote AI gateway with OpenAI-compatible REST for chat, image, TTS, embeddings, web search, web fetch.

    147 GitHub stars~995 tokensUpdated 26 days ago
    AI & LLM EngineeringAuto-check passed
  • Keirouter Chat

    mydisha/keirouter

    Chat / code generation via KeiRouter using OpenAI /v1/chat/completions or Anthropic /v1/messages format with streaming + auto-fallback combos.

    147 GitHub stars~859 tokensUpdated 26 days ago
    AI & LLM EngineeringAuto-check passed

More from OnlyTerp/prompt-cache-skills

All 13 skills in this repo
  • Aider One-Hour Cache TTL

    OnlyTerp/prompt-cache-skills

    Patches Aider to request Anthropic's one-hour prompt cache lifetime, so long pauses between turns no longer expire the cache or need paid keepalive pings.

    114 GitHub stars~990 tokensUpdated 1 mo ago
    Auto-check passed
  • Aider Prompt Caching Default

    OnlyTerp/prompt-cache-skills

    Patch recipe that turns on Aider's --cache-prompts by default for models that support caching, with a verification procedure against the wire request.

    114 GitHub stars~638 tokensUpdated 1 mo ago
    Auto-check passed
  • Cline Prompt Cache Ladder Check

    OnlyTerp/prompt-cache-skills

    Verifies how Cline marks Anthropic prompt-cache breakpoints on the wire, then adds a tools breakpoint and tunes the cache TTL in its AI SDK code.

    114 GitHub stars~2k tokensUpdated 1 mo ago
    Auto-check passed
  • Cline OpenAI Prompt Cache Key Fix

    OnlyTerp/prompt-cache-skills

    Patch guide for adding a stable per-task prompt_cache_key to Cline's OpenAI native provider so cached token counts stop reading as zero.

    114 GitHub stars~868 tokensUpdated 1 mo ago
    Auto-check passed
  • Cline Pin Timestamp

    OnlyTerp/prompt-cache-skills

    Cline's system prompt includes a timestamp that may be recomputed per request, invalidating the system-prompt cache.

    114 GitHub stars~751 tokensUpdated 1 mo ago
    Auto-check passed
  • Continue Enable Defaults

    OnlyTerp/prompt-cache-skills

    Continue's prompt caching is opt-in via config and off by default.

    114 GitHub stars~977 tokensUpdated 1 mo ago
    Auto-check passed

Questions about Opencode Mistral Cache Key

What does Opencode Mistral Cache Key do?

OpenCode doesn't set promptcachekey for Mistral models, missing the documented 10% cached-token discount. Opencode Mistral Cache Key is an agent skill from OnlyTerp/prompt-cache-skills. OpenCode doesn't set promptcachekey for Mistral models, missing the documented 10% cached-token discount.

When should I use Opencode Mistral Cache Key?

Opencode Mistral Cache Key fits situations like: tasks that involve LLM cost and token optimization.

How do I install Opencode Mistral Cache Key in Claude Code?

Run `npx skills add OnlyTerp/prompt-cache-skills --skill opencode-mistral-cache-key -a claude-code`. Or copy the skill folder (skills/opencode-mistral-cache-key in OnlyTerp/prompt-cache-skills) into .claude/skills/opencode-mistral-cache-key in your project. Claude Code loads it when a task matches its description.

How do I install Opencode Mistral Cache Key in Codex?

Run `npx skills add OnlyTerp/prompt-cache-skills --skill opencode-mistral-cache-key -a codex`. Or copy the skill folder (skills/opencode-mistral-cache-key in OnlyTerp/prompt-cache-skills) into .agents/skills/opencode-mistral-cache-key in your project. Codex loads it when a task matches its description.

Can I use Opencode Mistral Cache Key in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add OnlyTerp/prompt-cache-skills --skill opencode-mistral-cache-key -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/opencode-mistral-cache-key, .gemini/skills/opencode-mistral-cache-key, .github/skills/opencode-mistral-cache-key and .opencode/skills/opencode-mistral-cache-key in your project.

What does Opencode Mistral Cache Key need to run?

SKILL.md names no scripts, command-line tools or credentials: Opencode Mistral Cache Key is instructions for the agent only.

Does Opencode Mistral Cache Key access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Opencode Mistral Cache Key safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Opencode Mistral Cache Key use?

Opencode Mistral Cache Key has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does Opencode Mistral Cache Key use?

About 638 tokens (SKILL.md is roughly 2.6k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Opencode Mistral Cache Key?

Skills that share tags, products or a category with Opencode Mistral Cache Key: Embeddings via 9Router (decolua/9router, 30k stars), Agents Best Practices (DenisSergeevitch/agents-best-practices, 2.4k stars), Bridgic LLMs (bitsky-tech/bridgic, 155 stars) and Vibe (pcx-wave/vibe-skill, 119 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Opencode Mistral Cache Key?

OnlyTerp (a GitHub user) maintains it in OnlyTerp/prompt-cache-skills, which has 114 GitHub stars. The repository holds 13 skills in this directory. The repository was last updated on August 29, 2026.

Source: OnlyTerp/prompt-cache-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.