lean-zstd-patterns

Implement Zstandard decompression patterns in Lean 4.

112|9|Updated Feb 17, 2026
One-click install
npx skills add https://github.com/kim-em/lean-zip --skill lean-zstd-patterns
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: lean-zstd-patterns
Source: https://github.com/kim-em/lean-zip/tree/main/.claude/skills/lean-zstd-patterns
Command: npx skills add https://github.com/kim-em/lean-zip --skill lean-zstd-patterns

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides guidance and patterns for implementing Zstandard (Zstd) decompression features, helping developers understand and build robust decompression pipelines.

Core Features & Use Cases

  • Zstd Decompression Logic: Detailed explanations of FSE table construction, backward bitstream reading, Huffman decoding, and sequence execution.
  • Testing Strategies: Guidance on writing conformance, component, and integration tests for Zstd features.
  • Use Case: A developer working on a Lean 4 project needs to implement Zstd decompression for archive files and requires best practices and implementation details to ensure correctness and efficiency.

Quick Start

Consult the patterns for implementing Zstd decompression logic in Lean 4.

Frequently Asked Questions about lean-zstd-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement Zstd decompression in Lean 4?

Implement Zstd decompression in Lean 4 by following established patterns for FSE table construction, backward bitstream reading, Huffman decoding, and sequence execution to ensure correct data extraction from compressed archives.

What is backward bitstream reading in Zstandard RFC 8878?

Backward bitstream reading in Zstandard RFC 8878 is a decompression mechanism where the bitstream is parsed from the end towards the beginning, requiring specific bit-manipulation patterns to correctly decode compressed data.

How do I build FSE tables for Zstd decompression?

Build FSE tables for Zstd decompression by initializing state machines from normalized frequency counts, a necessary step before decoding literals and sequences from the compressed bitstream.

What testing strategies should I use for Zstd decompression features?

Use conformance, component, and integration testing strategies for Zstd decompression features to verify Huffman decoding accuracy, sequence execution correctness, and overall pipeline robustness against RFC 8878 specifications.

Does this Skill provide patterns for Huffman decoding in Lean 4?

Yes, this Skill provides implementation patterns for Huffman decoding in Lean 4, detailing how to construct decode tables and execute symbol lookups during the Zstd decompression pipeline.