Agent skill

Xz Lzma Format

by adamhathcock in adamhathcock/sharpcompress

Reference the XZ container format and LZMA/LZMA2 decoder behavior.

MITAuto-check passed

Install Xz Lzma Format

skills CLI
$ npx skills add adamhathcock/sharpcompress --skill xz-lzma-format -a claude-code

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

GitHub CLI
$ gh skill install adamhathcock/sharpcompress xz-lzma-format --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/adamhathcock/sharpcompress.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/xz-lzma-format .claude/skills/xz-lzma-format && 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
xz-lzma-format
GitHub stars
2.6k
Token cost
~513 tokens
SKILL.md length
233 words
Files
2 (incl. references)
Skills in repo
5
Repo updated
First seen
Licence
MIT

At a glance

Reference the XZ container format and LZMA/LZMA2 decoder behavior.

  • Works in 5 steps: Identify the layer involved: XZ stream… → Open references/xz-lzma-format.md and… → For XZ checksum work, verify the stream… → …
  • An AI agent needs to answer questions
  • SKILL.md covers Reference and Workflow
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Xz Lzma Format is an agent skill from adamhathcock/sharpcompress. Reference the XZ container format and LZMA/LZMA2 decoder behavior. Use when an AI agent needs to answer questions or make code changes involving XZ headers, blocks, indexes, checks, CRC64/XZ, LZMA2 chunks, LZMA end markers, corrupt .xz test files, or SharpCompress XZ/LZMA parsing and decompression behavior.

Its SKILL.md is about 510 tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including reference files (for example `references/xz-lzma-format.md`).

The repository describes itself as: SharpCompress is a fully managed C library to deal with many compression types and formats. The licence is MIT.

When your agent uses it

  • An AI agent needs to answer questions
  • Make code changes involving XZ headers
  • LZMA end markers
  • Corrupt .xz test files

Example prompts

  • “/xz-lzma-format”

Workflow steps

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

  1. Identify the layer involved: XZ stream header/footer, block header, compressed data padding, block check, index, filter chain, LZMA2 chunk…
  2. Open references/xz-lzma-format.md and cross-check the relevant spec/source section before changing parser or decoder code.
  3. For XZ checksum work, verify the stream check type from the XZ header. Use CRC32, CRC64/XZ, SHA-256, or no check according to the header…
  4. For LZMA2 corruption work, compare SharpCompress behavior against the XZ Utils test corpus notes and liblzma decoder state model.
  5. Test both sync and async paths. Relevant files are XZBlock.cs, XZBlock.Async.cs, XZStream.cs, XZStream.Async.cs, LzmaStream.cs…

What it can do on your machine

Read from SKILL.md and the folder at commit eab8154. 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.

    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

Xz Lzma Format loads about 513 tokens when it runs, and up to ~2.7k if it reads all its reference files. Until then it costs about 81 tokens; SKILL.md has 233 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~81
When it runs · the whole SKILL.md, loaded when a task matches
~513
With references · SKILL.md plus every file in references/, read only if the agent opens them
~2.7k

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

The full file from adamhathcock/sharpcompress at commit eab8154, republished under its MIT licence (© adamhathcock). 233 words, ~513 tokens.

Download SKILL.mdSave it as .claude/skills/xz-lzma-format/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
xz-lzma-format
description
Reference the XZ container format and LZMA/LZMA2 decoder behavior. Use when an AI agent needs to answer questions or make code changes involving XZ headers, blocks, indexes, checks, CRC64/XZ, LZMA2 chunks, LZMA end markers, corrupt .xz test files, or SharpCompress XZ/LZMA parsing and decompression behavior.

XZ and LZMA Format

Use this skill for work at the boundary between the XZ container and the LZMA/LZMA2 compression streams. It captures the key details needed for SharpCompress XZ block parsing, XZ integrity checks, and LZMA2 decoder corruption handling.

Reference

  • Read references/xz-lzma-format.md when the task depends on XZ binary layout, XZ block checks, CRC64/XZ parameters, LZMA2 chunk control bytes, LZMA end-of-payload markers, or XZ Utils bad-file expectations.
  • Treat XZ as a container around filter chains. Do not assume raw LZMA/LZMA2 behavior is equivalent to XZ stream validation.
  • Use the linked XZ Utils/liblzma sources in the reference when matching corruption behavior. The test corpus contains intentionally bad files that must throw even when they can produce all expected output bytes.

Workflow

  1. Identify the layer involved: XZ stream header/footer, block header, compressed data padding, block check, index, filter chain, LZMA2 chunk framing, or raw LZMA range decoding.
  2. Open references/xz-lzma-format.md and cross-check the relevant spec/source section before changing parser or decoder code.
  3. For XZ checksum work, verify the stream check type from the XZ header. Use CRC32, CRC64/XZ, SHA-256, or no check according to the header, not according to a test fixture assumption.
  4. For LZMA2 corruption work, compare SharpCompress behavior against the XZ Utils test corpus notes and liblzma decoder state model.
  5. Test both sync and async paths. Relevant files are XZBlock.cs, XZBlock.Async.cs, XZStream.cs, XZStream.Async.cs, LzmaStream.cs, LzmaStream.Async.cs, LzmaDecoder.cs, and LzmaDecoder.Async.cs.

© adamhathcock, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (references) in .agents/skills/xz-lzma-format of adamhathcock/sharpcompress.

  • SKILL.md
  • references/xz-lzma-format.md

Open the folder on GitHubat commit eab8154

Compare with similar skills

Xz Lzma Format 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.

Xz Lzma Format compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Xz Lzma Format this skilladamhathcock/sharpcompress2.6k—~513Automated safety check: PassMIT
Apple Containersickn33/agentic-awesome-skills47k1 repos~2.5kAutomated safety check: PassApache-2.0
Container Security Hardeningsickn33/agentic-awesome-skills47k1 repos~1kAutomated safety check: NotesMIT
Container Queriesthedaviddias/Front-End-Checklist74k—~526Automated safety check: PassMIT
CSS Containmentthedaviddias/Front-End-Checklist74k—~512Automated safety check: PassMIT
Detecting Container Escape Attemptsmukul975/Anthropic-Cybersecurity-Skills34k—~2.9kAutomated safety check: PassApache-2.0

Similar skills

  • Apple Container

    sickn33/agentic-awesome-skills

    Build, run, and manage OCI/Linux containers as lightweight per-container VMs on Apple-silicon macOS using Apple's open-source container CLI, no Docker daemon required.

    47k GitHub starsUsed in 1 repo~2.5k tokens
    DevOps & CloudAuto-check passed
  • Container Security Hardening

    sickn33/agentic-awesome-skills

    Harden Docker/container images and runtime deployments with secure base images, non-root users, CVE scanning, SBOM/signing, seccomp/AppArmor, and Kubernetes pod security controls.

    47k GitHub starsUsed in 1 repo~1k tokens
    SecurityAuto-check: notes
  • Container Queries

    thedaviddias/Front-End-Checklist

    A skill your agent uses when reviewing stylesheets, component styles, and responsive behavior related to Use container queries for component-level responsiveness.

    74k GitHub stars~526 tokensUpdated 4 days ago
    Frontend & DesignAuto-check passed
  • CSS Containment

    thedaviddias/Front-End-Checklist

    A skill your agent uses when reviewing stylesheets, component styles, and responsive behavior related to Use CSS containment to limit repaint scope.

    74k GitHub stars~512 tokensUpdated 4 days ago
    Frontend & DesignAuto-check passed
  • Detecting Container Escape Attempts

    mukul975/Anthropic-Cybersecurity-Skills

    Detects container escape at runtime across tooling - namespace manipulation, capability abuse, kernel exploits, sensitive host mounts, and anomalous syscalls - and explains which signals matter…

    34k GitHub stars~2.9k tokensUpdated 1 mo ago
    DevOps & CloudAuto-check passed
  • Performing Container Escape Detection

    mukul975/Anthropic-Cybersecurity-Skills

    Audits container and pod configuration for escape-enabling misconfiguration using the Kubernetes Python client - privileged flags, dangerous capability grants, host path mounts, shared namespaces…

    34k GitHub stars~648 tokensUpdated 1 mo ago
    SecurityAuto-check passed

More from adamhathcock/sharpcompress

  • Rar Format

    adamhathcock/sharpcompress

    Reference the RAR/RAR5 archive container format and UnRAR source behavior.

    2.6k GitHub stars~633 tokensUpdated yesterday
    Auto-check passed
  • Tar Format

    adamhathcock/sharpcompress

    Reference the Tar/USTAR/PAX/GNU tar archive container format.

    2.6k GitHub stars~499 tokensUpdated yesterday
    Auto-check passed
  • Zip Format

    adamhathcock/sharpcompress

    Reference the ZIP/ZIP64/PKWARE APPNOTE archive container format.

    2.6k GitHub stars~613 tokensUpdated yesterday
    Auto-check passed
  • Sevenzip Format

    adamhathcock/sharpcompress

    Reference the 7z/7zip archive container format. An agent skill from adamhathcock/sharpcompress.

    2.6k GitHub stars~422 tokensUpdated yesterday
    Auto-check passed

Questions about Xz Lzma Format

What does Xz Lzma Format do?

Reference the XZ container format and LZMA/LZMA2 decoder behavior. Xz Lzma Format is an agent skill from adamhathcock/sharpcompress. Reference the XZ container format and LZMA/LZMA2 decoder behavior.

When should I use Xz Lzma Format?

Xz Lzma Format fits situations like: an AI agent needs to answer questions; make code changes involving XZ headers; LZMA end markers; corrupt .xz test files.

How do I install Xz Lzma Format in Claude Code?

Run `npx skills add adamhathcock/sharpcompress --skill xz-lzma-format -a claude-code`. Or copy the skill folder (.agents/skills/xz-lzma-format in adamhathcock/sharpcompress) into .claude/skills/xz-lzma-format in your project. Claude Code loads it when a task matches its description.

How do I install Xz Lzma Format in Codex?

Run `npx skills add adamhathcock/sharpcompress --skill xz-lzma-format -a codex`. Or copy the skill folder (.agents/skills/xz-lzma-format in adamhathcock/sharpcompress) into .agents/skills/xz-lzma-format in your project. Codex loads it when a task matches its description.

Can I use Xz Lzma Format 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 adamhathcock/sharpcompress --skill xz-lzma-format -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/xz-lzma-format, .gemini/skills/xz-lzma-format, .github/skills/xz-lzma-format and .opencode/skills/xz-lzma-format in your project.

What does Xz Lzma Format need to run?

SKILL.md names no scripts, command-line tools or credentials: Xz Lzma Format is instructions for the agent only.

Does Xz Lzma Format 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 Xz Lzma Format 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 Xz Lzma Format use?

Xz Lzma Format is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Xz Lzma Format use?

About 513 tokens (SKILL.md is roughly 2.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 2.1k tokens, read only when the agent opens those files.

What are the alternatives to Xz Lzma Format?

Skills that share tags, products or a category with Xz Lzma Format: Apple Container (sickn33/agentic-awesome-skills, 47k stars), Container Security Hardening (sickn33/agentic-awesome-skills, 47k stars), Container Queries (thedaviddias/Front-End-Checklist, 74k stars) and CSS Containment (thedaviddias/Front-End-Checklist, 74k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Xz Lzma Format?

adamhathcock (a GitHub user) maintains it in adamhathcock/sharpcompress, which has 2,589 GitHub stars. The repository holds 5 skills in this directory. The repository was last updated on October 9, 2026.

Source: adamhathcock/sharpcompress on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.