https://github.com/nethermindeth/cairo_zstd
Cairo v1 port of a Zstandard decompressor (WIP)
https://github.com/nethermindeth/cairo_zstd
nubia
Last synced: 4 months ago
JSON representation
Cairo v1 port of a Zstandard decompressor (WIP)
- Host: GitHub
- URL: https://github.com/nethermindeth/cairo_zstd
- Owner: NethermindEth
- License: apache-2.0
- Created: 2023-11-01T02:11:01.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-06-20T09:51:55.000Z (12 months ago)
- Last Synced: 2025-10-11T00:39:07.833Z (8 months ago)
- Topics: nubia
- Language: Cairo
- Homepage:
- Size: 9.34 MB
- Stars: 11
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# cairo-zstd
This is a Cairo v1 port of a zstd decompressor. The code is heavily and purposely based on the [zstd-rs](https://github.com/KillingSpark/zstd-rs)
project, except that it's now [Cairo](https://github.com/starkware-libs/cairo).
STARK-provable decompression here we go!
Still a WIP.
### Current development state
- [x] Main implementation porting
- [x] Decoding tests
- [ ] Dictionary support
- [ ] Optimizations and benchmarking
### Testing
In order to generate the decode corpus test files, first run the test
generation script:
```
node ./script/generate_decode_corpus_tests.js
```
This will generate a decoding test for each of the files in
`data/decode_corpus` which are at or below the set file size in the script.
The test generation is a temporary workaround to embed the original/compressed
file contents in a cairo file while we're not using a runner that supports a
read file-like cheatcode for testing.
At this point, simply run:
```
scarb test
```