agentleFS
nagandla-sasidharnagandla-sasidhar/slim-claude-plugin/skills/slim/SKILL.md

slim

Skill0 starsChanged 6 months agoMITView on GitHub

Use this skill when the user asks to convert a file to SLIM format, write a new SLIM document, validate or review an existing .slm file, check SLIM v2 syntax, or asks questions like "convert this to SLIM", "make this SLIM", "is this valid SLIM", "write a SLIM prompt", "create a SLIM agent config", or "review this .slm file". Also use when the user pastes Markdown/JSON/YAML/plain text and wants it optimised for LLM token usage.

4 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions4 projects use a version of this.

    Word for word · 1

    1. nagandla-sasidhar/slim★ 0100% same

    Edited · 0

    None found.

    Wrote their own version · 3

    1. jantichy/claude★ 45same name
    2. HeBtcd/skills★ 5same name
    3. tacyan/claude-code-token-slim-mcp★ 4same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 3 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Do NOT use @+version or @+tags — the LLM gains no value from these

    line 31
  2. Very specific:

    No close tag — blank line or next :: ends the content block

    line 36
  3. Distinctive:

    After converting, always report:

    line 155

“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

SLIM Format Skill

SLIM (Structured LLM Instruction Markup) v2.0 is a token-efficient format for AI documents. Website: https://slimformat.org | Repo: https://github.com/nagandla-sasidhar/TAML | Playground: https://slimformat.org/playground.html

Core Syntax (v2.0)

@slim: 2.0               ← required first line
@key: value              ← orchestrator-only header (stripped before LLM)
@+key: value             ← LLM-visible header (appears in LLM text)
~ comment                ← always stripped
$var                     ← variable reference (interpolated at runtime)

::SECTION_NAME type      ← named section, no close tag (type is optional)
  content here           ← verbatim until blank line or next ::
:::NESTED_NAME type      ← nested section (one extra colon)
::CODE_1 lang            ← code block; increment _N for each additional block

Header zone rules

  • @slim: 2.0 must be the first non-blank line
  • @key = orchestrator metadata (model, retry, timeout, task IDs) — LLM never sees it
  • @+key = LLM-visible info (name, description, purpose, context)
  • Do NOT use @+version or @+tags — the LLM gains no value from these
  • Headers end at the first :: section or blank line after headers

Section rules

  • ::NAME opens a section; the previous section implicitly closes
  • No close tag — blank line or next :: ends the content block
  • Type hint is optional but valuable: ::CONTEXT markdown, ::CODE python, ::SCHEMA json
  • :::NAME for nested sections inside a parent section
  • Section names: UPPERCASE by convention (CONTEXT, INSTRUCTIONS, EXAMPLES, SCHEMA, OUTPUT)

Token-saving conversions from Markdown

MarkdownSLIM
---\nkey: val\n--- YAML front-matter@key: val headers
# Heading::HEADING section or @+name: Heading
**bold**, *italic*plain text (meaning preserved)
- item bulletplain indented line
\``lang ... ````::CODE_N lang section
<!-- comment -->~ comment

Token-saving conversions from YAML

YAMLSLIM
key: scalar root scalar@key: scalar header
key: block (array or object)::KEY section
- item list entryplain line (marker stripped)
# comment~ comment
Quoted values "val" / 'val'unquoted plain value
Inline comment key: val # notevalue without comment

How to convert YAML (step by step)

  1. Skip --- document separators
  2. Root scalar key: value → @key: value header; strip inline # comments and quotes
  3. Root block key: (array or object) → ::KEY section; collect indented children, strip - list markers
  4. # comment lines → ~ comment
  5. Nested sub-keys inside a block → preserve as subkey: value lines in the section body
  6. Report token savings

How to convert Markdown (step by step)

  1. Read the source file — identify: YAML front-matter, headings, bullets, code blocks, bold/italic
  2. Write header zone — @slim: 2.0, then map YAML keys to @key/@+key
  3. Map headings → sections — each # heading becomes ::HEADING_NAME
  4. Strip inline formatting — remove **, *, backtick pairs; preserve meaning
  5. Strip bullets — remove - / * prefixes; keep indentation for hierarchy
  6. Wrap code blocks — ```lang...``` → ::CODE_1 lang (increment counter per block)
  7. Convert comments — <!-- ... --> → ~ ...
  8. Count tokens — use estimateTokens() or tiktoken; report % saved

Validation checklist for reviewing .slm files

  • First line is @slim: 2.0
  • No @slim: 1.0 (old version)
  • No === BLOCK [type] ... === /BLOCK (old v1 syntax)
  • @+ used only for keys the LLM actually needs to know
  • No @+version or @+tags (LLM doesn't benefit)
  • Section names are UPPERCASE
  • No close tags (no ::: without an opener, no === /)
  • Variables ($var) have corresponding @+var: or @var: headers
  • Code blocks use ::CODE_N lang not fenced backticks

Common section names by use case

Agent config: ::ROLE, ::INSTRUCTIONS, ::CONSTRAINTS, ::CONTEXT, ::EXAMPLES, ::OUTPUT System prompt: ::SYSTEM, ::PERSONA, ::CAPABILITIES, ::RESTRICTIONS, ::FORMAT RAG document: ::SUMMARY, ::CONTENT, ::METADATA, ::REFERENCES API schema: ::REQUEST, ::RESPONSE, ::ERRORS, ::EXAMPLES

Example — minimal agent config

@slim: 2.0
@model: claude-opus-4-7
@task: $task_id
@+name: CodeReviewer
@+purpose: Review pull requests for security and quality issues

::INSTRUCTIONS
Review the diff in $context.
Focus on: security vulnerabilities, breaking changes, performance regressions.
Be concise. Flag critical issues first.

::CONSTRAINTS
Never approve a PR with an unaddressed critical security issue.
Keep each comment under 80 words.

Example — YAML agent config → SLIM

Input YAML:

# Agent config
name: DataAnalyst
model: claude-opus-4-7
temperature: 0.3
instructions:
  - Always cite data sources
  - Flag data quality issues
constraints:
  - Never fabricate data points
  - Keep reports under 500 words

Output SLIM:

@slim: 2.0
@name: DataAnalyst
@model: claude-opus-4-7
@temperature: 0.3

~ Agent config

::INSTRUCTIONS
Always cite data sources
Flag data quality issues

::CONSTRAINTS
Never fabricate data points
Keep reports under 500 words

Reporting token savings

After converting, always report:

  • Input tokens (original) — estimate as char_count / 4
  • LLM-facing tokens (SLIM output, header zone excluded) — same estimation
  • Savings % = (input - llm_facing) / input × 100
  • For precise counts use tiktoken (Python) or the playground at https://slimformat.org/playground.html

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.