|
1 | | -# Changelog | 变更日志 |
| 1 | +# Changelog |
2 | 2 |
|
3 | 3 | All notable changes to this project will be documented in this file. |
4 | 4 |
|
5 | | -本文件记录本项目的所有重要变更。 |
6 | | - |
7 | 5 | The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), |
8 | 6 | and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). |
9 | 7 |
|
10 | | -格式基于 [Keep a Changelog](https://keepachangelog.com/zh-CN/1.1.0/), |
11 | | -本项目遵循 [语义化版本](https://semver.org/lang/zh-CN/)。 |
12 | | - |
13 | 8 | ## [Unreleased] |
14 | 9 |
|
15 | | -### Added | 新增 |
16 | | -- VitePress SEO: Open Graph / Twitter Card meta tags, sitemap, cleanUrls |
17 | | -- Docs landing page: feature cards with anchor links, richer hero tagline |
18 | | -- Docs algorithms page: complexity analysis table, Huffman/Arithmetic comparison, Range Coder vs Arithmetic differences |
19 | | -- Docs getting-started: code-group tabs, Makefile command table, structured environment requirements |
20 | | -- Docs project-structure: CI/CD table, file format table, enhanced directory tree |
21 | | -- Site favicon (logo.svg) |
| 10 | +### Added |
| 11 | + |
| 12 | +#### Documentation |
| 13 | + |
| 14 | +- **Internationalization (i18n)**: Complete bilingual documentation site (English & Chinese) |
| 15 | + - New directory structure: `docs/en/` and `docs/zh/` |
| 16 | + - VitePress configuration with locale switcher |
| 17 | + - Full translations for all guide pages |
| 18 | +- Enhanced README with modern badges and improved structure |
| 19 | +- Professional changelog reorganization with detailed categorization |
| 20 | + |
| 21 | +#### Algorithms & Implementations |
| 22 | + |
22 | 23 | - Arithmetic coding Go implementation with full test suite |
23 | 24 | - Arithmetic coding Rust implementation with full test suite |
24 | 25 | - Range coder Go CLI (`range/go/cmd/main.go`) for cross-language testing |
25 | 26 | - Range coder Rust CLI (`range/rust/src/bin/rangecoder.rs`) for cross-language testing |
26 | | -- Cross-language benchmark script for Arithmetic coding (`arithmetic/benchmark/bench.py`) |
27 | | -- Cross-language benchmark script for Range coder (`range/benchmark/bench.py`) |
28 | | -- CI cross-language correctness tests for Arithmetic and Range coder (all 3 languages) |
29 | | - |
30 | | -### Changed | 变更 |
31 | | -- Pages workflow: sparse-checkout (skip algorithm source), Node 20→22, package-lock.json path trigger |
32 | | -- VitePress sidebar restructured into "入门" + "算法" groups, nav added "相关链接" dropdown |
33 | | -- README.md: fixed dead doc links (algorithms, benchmarks → guide/ paths) |
34 | | -- Upgraded Arithmetic benchmark from C++-only to cross-language (C++, Go, Rust) |
35 | | -- Overhauled Makefile with complete build/test/clean targets for all algorithms and languages |
36 | | -- Updated CI workflow: full build, test, and cross-language verification for all 4 algorithms × 3 languages |
| 27 | + |
| 28 | +#### Infrastructure |
| 29 | + |
| 30 | +- Cross-language benchmark scripts for Arithmetic coding and Range coder |
| 31 | +- CI cross-language correctness tests for all 4 algorithms × 3 languages |
| 32 | +- Input size validation (4 GiB max) to prevent frequency overflow attacks |
| 33 | +- Output size validation (1 GiB max) to prevent decompression bombs |
| 34 | +- RAII/smart pointers for memory management in C++ Huffman implementation |
| 35 | +- `-Werror` flag in Makefile for C++ builds to catch all warnings |
| 36 | + |
| 37 | +### Changed |
| 38 | + |
| 39 | +#### Documentation Site |
| 40 | + |
| 41 | +- VitePress sidebar restructured into logical groups (Overview, Guide, Reference) |
| 42 | +- README.md simplified to repository entry point with links to docs site |
| 43 | +- Updated site metadata and SEO optimization (Open Graph, Twitter Cards) |
| 44 | + |
| 45 | +#### Build & CI |
| 46 | + |
| 47 | +- Pages workflow: sparse-checkout optimization, Node 20→22, path-based triggers |
| 48 | +- CI workflow: full build, test, and cross-language verification matrix |
| 49 | +- Makefile: complete build/test/clean targets for all algorithms and languages |
| 50 | +- Arithmetic benchmark upgraded from C++-only to cross-language (C++, Go, Rust) |
| 51 | + |
| 52 | +#### Code Quality |
| 53 | + |
| 54 | +- All error messages standardized to English across all implementations |
| 55 | +- All Chinese comments translated to English for consistency |
37 | 56 | - Updated `go.work` to include `arithmetic/go` module |
38 | 57 | - Updated `range/rust/Cargo.toml` to include `rangecoder` CLI binary |
39 | | -- Updated `.gitignore` for new binaries and file extensions |
40 | | -- Updated `run_all_bench.py` to use unified cross-language benchmark scripts |
41 | | -- Updated README: algorithm table, project structure, Go version badge (1.21+), roadmap |
42 | | - |
43 | | -### Fixed | 修复 |
44 | | -- README badge URL: `docs.yml` → `pages.yml` (both EN & ZH READMEs) |
45 | | -- README algorithm table: "LZ77" → "Range Coder" (matched actual project directory) |
46 | | -- README project structure: `lz77/` → `range/` |
| 58 | + |
| 59 | +### Fixed |
| 60 | + |
| 61 | +- README badge URL: `docs.yml` → `pages.yml` |
| 62 | +- README algorithm table: corrected "LZ77" → "Range Coder" |
| 63 | +- README project structure: corrected `lz77/` → `range/` |
47 | 64 | - `.gitignore`: removed bare `Makefile` pattern that could shadow root Makefile |
48 | | -- Fixed Makefile `build-range` target (was running `go test` instead of building CLI) |
49 | | -- Fixed Makefile `clean` target (replaced fragile Python one-liner with proper `rm` commands) |
| 65 | +- Makefile `build-range` target: fixed incorrect `go test` call |
| 66 | +- Makefile `clean` target: replaced fragile Python one-liner with proper `rm` commands |
| 67 | +- Huffman cross-language compatibility: unified tree building tie-breaking across C++, Go, Rust |
| 68 | +- CI Python setup: removed invalid `cache: pip` option |
| 69 | +- CI Range coder tests: using 100KB test file to work around decode performance issue |
| 70 | + |
| 71 | +### Security |
| 72 | + |
| 73 | +- Added input size limits to prevent frequency overflow attacks |
| 74 | +- Added output size limits to prevent decompression bomb attacks |
| 75 | +- All implementations now validate file sizes before processing |
| 76 | + |
| 77 | +--- |
50 | 78 |
|
51 | 79 | ## [1.0.0] - 2026-01-07 |
52 | 80 |
|
53 | | -### Added | 新增 |
| 81 | +### Added |
| 82 | + |
| 83 | +#### Core Algorithms |
| 84 | + |
| 85 | +- **Huffman Coding**: Implementation in C++, Go, and Rust |
| 86 | + - Prefix-code based lossless compression |
| 87 | + - Cross-language file format compatibility |
| 88 | + - Benchmark suite |
| 89 | + |
| 90 | +- **Arithmetic Coding**: Implementation in C++ |
| 91 | + - Interval subdivision based compression |
| 92 | + - Near-optimal compression efficiency |
54 | 93 |
|
55 | | -#### Algorithms | 算法 |
56 | | -- Huffman encoding implementation in C++, Go, and Rust |
57 | | -- Arithmetic coding implementation in C++ |
58 | | -- Range coder implementation in C++, Go, and Rust |
59 | | -- Run-Length Encoding (RLE) implementation in C++, Go, and Rust |
| 94 | +- **Range Coder**: Implementation in C++, Go, and Rust |
| 95 | + - Integer-based arithmetic coding equivalent |
| 96 | + - Library API for Go and Rust |
| 97 | + - CLI tools for all languages |
| 98 | + |
| 99 | +- **Run-Length Encoding (RLE)**: Implementation in C++, Go, and Rust |
| 100 | + - Simple (count, value) pair encoding |
| 101 | + - Optimized for repetitive data |
| 102 | + |
| 103 | +#### Features |
60 | 104 |
|
61 | | -#### Features | 功能 |
62 | 105 | - Unified CLI interface across all implementations (`encode`/`decode` commands) |
63 | 106 | - Cross-language file format compatibility |
64 | 107 | - Benchmark scripts for performance comparison |
65 | | -- Test data generation scripts |
| 108 | +- Test data generation scripts (Python) |
| 109 | + |
| 110 | +#### Documentation |
66 | 111 |
|
67 | | -#### Documentation | 文档 |
68 | 112 | - Comprehensive README with bilingual (Chinese/English) content |
69 | | -- Algorithm comparison table |
70 | | -- Quick start guide |
| 113 | +- Algorithm comparison table with complexity analysis |
| 114 | +- Quick start guide with build instructions |
71 | 115 | - Project structure documentation |
72 | 116 |
|
73 | | -#### Open Source Infrastructure | 开源基础设施 |
| 117 | +#### Open Source Infrastructure |
| 118 | + |
74 | 119 | - MIT License |
75 | | -- Contributing guidelines (CONTRIBUTING.md) |
76 | | -- Code of Conduct (CODE_OF_CONDUCT.md) |
77 | | -- Security policy (SECURITY.md) |
| 120 | +- Contributing guidelines (CONTRIBUTING.md) - bilingual |
| 121 | +- Code of Conduct (CODE_OF_CONDUCT.md) - bilingual |
| 122 | +- Security policy (SECURITY.md) - bilingual |
78 | 123 | - GitHub Issue templates (bug report, feature request) |
79 | 124 | - GitHub Pull Request template |
80 | | -- GitHub Actions CI/CD pipeline |
| 125 | + |
| 126 | +#### CI/CD Pipeline |
| 127 | + |
| 128 | +- GitHub Actions CI workflow |
81 | 129 | - Multi-platform C++ builds (Ubuntu, macOS) |
82 | 130 | - Go build and lint checks |
83 | 131 | - Rust build and clippy checks |
84 | 132 | - Encode/decode correctness verification |
85 | 133 | - Required files check |
| 134 | +- GitHub Actions Pages workflow for documentation deployment |
| 135 | + |
| 136 | +### Technical Specifications |
| 137 | + |
| 138 | +#### File Formats |
86 | 139 |
|
87 | | -### Technical Details | 技术细节 |
| 140 | +| Algorithm | Magic | Header | Data | |
| 141 | +|-----------|-------|--------|------| |
| 142 | +| Huffman | `HFMN` | Frequency table (257×4 bytes) | Bit stream | |
| 143 | +| Arithmetic | `AENC` | Frequency table (257×4 bytes) | Bit stream | |
| 144 | +| Range Coder | `RCNC` | Frequency table (257×4 bytes) | Byte stream | |
| 145 | +| RLE | None | None | (count, value) pairs | |
88 | 146 |
|
89 | | -#### File Formats | 文件格式 |
90 | | -- Huffman: Magic header `HFMN`, frequency table, bit-encoded data |
91 | | -- RLE: `(count, value)` pairs with 4-byte little-endian count |
| 147 | +#### Build Requirements |
92 | 148 |
|
93 | | -#### Build Requirements | 构建要求 |
94 | | -- C++17 compatible compiler |
95 | | -- Go 1.21+ |
96 | | -- Rust 1.70+ |
97 | | -- Python 3.8+ (for scripts) |
| 149 | +| Language | Version | Compiler/Tool | |
| 150 | +|----------|---------|---------------| |
| 151 | +| C++ | C++17 | g++ 9+ or clang++ 10+ | |
| 152 | +| Go | 1.21+ | go 1.21+ | |
| 153 | +| Rust | 1.70+ | rustc 1.70+ | |
| 154 | +| Python | 3.8+ | python3 3.8+ | |
98 | 155 |
|
99 | 156 | --- |
100 | 157 |
|
101 | | -## Version History Summary | 版本历史摘要 |
| 158 | +## Version History Summary |
102 | 159 |
|
103 | 160 | | Version | Date | Highlights | |
104 | 161 | |---------|------|------------| |
105 | | -| 1.0.0 | 2026-01-07 | Initial release with 4 algorithms, 3 languages, full open source setup | |
| 162 | +| [Unreleased] | - | Documentation i18n, security improvements, complete test coverage | |
| 163 | +| [1.0.0] | 2026-01-07 | Initial release with 4 algorithms, 3 languages, full open source setup | |
106 | 164 |
|
107 | 165 | --- |
108 | 166 |
|
| 167 | +## Release Comparison |
| 168 | + |
109 | 169 | [Unreleased]: https://github.com/LessUp/encoding/compare/v1.0.0...HEAD |
110 | 170 | [1.0.0]: https://github.com/LessUp/encoding/releases/tag/v1.0.0 |
| 171 | + |
| 172 | +--- |
| 173 | + |
| 174 | +## Contributing |
| 175 | + |
| 176 | +When adding changes to this changelog, please follow the categorization: |
| 177 | + |
| 178 | +- `Added` - New features |
| 179 | +- `Changed` - Changes in existing functionality |
| 180 | +- `Deprecated` - Soon-to-be removed features |
| 181 | +- `Removed` - Now removed features |
| 182 | +- `Fixed` - Bug fixes |
| 183 | +- `Security` - Security-related changes |
| 184 | +- `Performance` - Performance improvements |
0 commit comments