aril 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. aril-0.1.0/.github/workflows/release.yml +81 -0
  2. aril-0.1.0/.gitignore +21 -0
  3. aril-0.1.0/.python-version +1 -0
  4. aril-0.1.0/PKG-INFO +108 -0
  5. aril-0.1.0/README.md +95 -0
  6. aril-0.1.0/examples/example.txt +1 -0
  7. aril-0.1.0/examples/inspect_prediction.py +12 -0
  8. aril-0.1.0/pyproject.toml +21 -0
  9. aril-0.1.0/secret +3 -0
  10. aril-0.1.0/src/aril/__init__.py +3 -0
  11. aril-0.1.0/src/aril/__main__.py +4 -0
  12. aril-0.1.0/src/aril/_micromixer/LICENSE +199 -0
  13. aril-0.1.0/src/aril/_micromixer/NOTICE +4 -0
  14. aril-0.1.0/src/aril/_micromixer/__init__.py +1 -0
  15. aril-0.1.0/src/aril/_micromixer/model_v37_qag.py +1565 -0
  16. aril-0.1.0/src/aril/_micromixer/model_v46_3_pure_mixer.py +449 -0
  17. aril-0.1.0/src/aril/_micromixer/model_v67_contentpool.py +753 -0
  18. aril-0.1.0/src/aril/_micromixer/model_v71_rtm.py +841 -0
  19. aril-0.1.0/src/aril/_micromixer/model_v72_glumixer.py +393 -0
  20. aril-0.1.0/src/aril/_micromixer/model_v75_rpc.py +691 -0
  21. aril-0.1.0/src/aril/_micromixer/model_v76_rpg.py +728 -0
  22. aril-0.1.0/src/aril/_micromixer/model_v82_gcr.py +841 -0
  23. aril-0.1.0/src/aril/_micromixer/model_v83_ccd.py +1003 -0
  24. aril-0.1.0/src/aril/_micromixer/model_v87_final.py +872 -0
  25. aril-0.1.0/src/aril/archive.py +454 -0
  26. aril-0.1.0/src/aril/cli.py +228 -0
  27. aril-0.1.0/src/aril/codec.py +75 -0
  28. aril-0.1.0/src/aril/context_codec.py +188 -0
  29. aril-0.1.0/src/aril/grouped.py +275 -0
  30. aril-0.1.0/src/aril/jpeg.py +63 -0
  31. aril-0.1.0/src/aril/micromixer.py +32 -0
  32. aril-0.1.0/src/aril/predictor.py +58 -0
  33. aril-0.1.0/src/aril/preflate.py +73 -0
  34. aril-0.1.0/src/aril/range_codec.py +145 -0
  35. aril-0.1.0/src/aril/solid.py +92 -0
  36. aril-0.1.0/src/aril/transforms.py +52 -0
  37. aril-0.1.0/tools/preflate/Cargo.lock +459 -0
  38. aril-0.1.0/tools/preflate/Cargo.toml +8 -0
  39. aril-0.1.0/tools/preflate/src/main.rs +64 -0
  40. aril-0.1.0/uv.lock +1161 -0
@@ -0,0 +1,81 @@
1
+ name: Build and publish Aril
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ release:
8
+ types: [published]
9
+
10
+ permissions:
11
+ contents: read
12
+
13
+ jobs:
14
+ build:
15
+ runs-on: ubuntu-latest
16
+
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+
20
+ - uses: astral-sh/setup-uv@v6
21
+ with:
22
+ enable-cache: true
23
+
24
+ - name: Set up Python
25
+ run: uv python install 3.13
26
+
27
+ - name: Build package
28
+ run: uv build --no-sources
29
+
30
+ - name: Test installation
31
+ run: |
32
+ uv tool install dist/*.whl
33
+ aril --help
34
+
35
+ - name: Upload distributions
36
+ uses: actions/upload-artifact@v4
37
+ with:
38
+ name: distributions
39
+ path: dist/
40
+
41
+ publish:
42
+ if: github.event_name == 'release'
43
+ needs: build
44
+ runs-on: ubuntu-latest
45
+ environment: pypi
46
+
47
+ permissions:
48
+ id-token: write
49
+ contents: read
50
+
51
+ steps:
52
+ - uses: actions/download-artifact@v4
53
+ with:
54
+ name: distributions
55
+ path: dist/
56
+
57
+ - uses: astral-sh/setup-uv@v6
58
+
59
+ - name: Publish to PyPI
60
+ run: uv publish --trusted-publishing always
61
+
62
+ release-assets:
63
+ if: github.event_name == 'release'
64
+ needs: publish
65
+ runs-on: ubuntu-latest
66
+
67
+ permissions:
68
+ contents: write
69
+
70
+ steps:
71
+ - uses: actions/download-artifact@v4
72
+ with:
73
+ name: distributions
74
+ path: dist/
75
+
76
+ - name: Attach release assets
77
+ env:
78
+ GH_TOKEN: ${{ github.token }}
79
+ GH_REPO: ${{ github.repository }}
80
+ TAG: ${{ github.event.release.tag_name }}
81
+ run: gh release upload "$TAG" dist/*
aril-0.1.0/.gitignore ADDED
@@ -0,0 +1,21 @@
1
+ .venv/
2
+ __pycache__/
3
+ dist/
4
+ circleos-grouped.aril
5
+ circleos-adaptive.aril
6
+
7
+ tools/preflate/target/
8
+
9
+ # Local benchmarks and downloaded compression corpora
10
+ benchmark/
11
+ enwik1m
12
+ enwik1m.aril
13
+ enwik8.zip
14
+ enwik8
15
+
16
+ # Temporary archives and scratch checkouts
17
+ tmp*/
18
+ work/
19
+
20
+ # Generated ARIL archives
21
+ *.aril
@@ -0,0 +1 @@
1
+ 3.13
aril-0.1.0/PKG-INFO ADDED
@@ -0,0 +1,108 @@
1
+ Metadata-Version: 2.5
2
+ Name: aril
3
+ Version: 0.1.0
4
+ Summary: Lossless text compression with a byte-level language model
5
+ Requires-Python: >=3.13
6
+ Requires-Dist: accelerate==1.16.0
7
+ Requires-Dist: huggingface-hub==2.4.0
8
+ Requires-Dist: safetensors==0.8.0
9
+ Requires-Dist: torch==2.15.0
10
+ Requires-Dist: tqdm==4.70.1
11
+ Requires-Dist: transformers==5.23.0
12
+ Description-Content-Type: text/markdown
13
+
14
+ # ARIL
15
+
16
+ ARIL is a compression method that takes advantage of context, not just content.
17
+
18
+ Compression is inefficient. Encoding a text such as lorum ipsum in ascii produces `01001100 01101111 01110010 01110101 01101101 00100000 01101001 01110000 01110011 01110101 01101101`. Now, this is pretty long. If you were to talk to another person, and say "What word comes after lorum", they'll probably be able to tell you that it's ipsum. So, this program takes advantage of that, and, using a LLM, predicts the next word. This means you can then represent every single phrase, word, and file using a single float between 0 and 1. I explained that really poorly, but [this video](https://www.youtube.com/watch?v=qbsb9DpdZ6s) explains it better. This program, on 1 MiB of wikipedia, performed better than .zip and .gz. However, it isn't perfect yet, and it still loses to bzip2 and xz.
19
+
20
+ ## Setup
21
+
22
+ Requirements: Python 3.13+, [uv](https://docs.astral.sh/uv/), and (optionally) Rust/Cargo for Git Preflate support.
23
+
24
+ ```sh
25
+ git clone github.com/code2344/aril
26
+ cd aril
27
+ uv sync
28
+ ```
29
+
30
+ Run ARIL directly from the checkout:
31
+
32
+ ```sh
33
+ uv run aril --help
34
+ ```
35
+
36
+ To install the command as a user-level tool instead:
37
+
38
+ ```sh
39
+ uv tool install .
40
+ aril --help
41
+ ```
42
+
43
+ ## Files and folders
44
+
45
+ ```sh
46
+ uv sync
47
+ uv run aril compress notes/ -o notes.aril
48
+ uv run aril list notes.aril
49
+ uv run aril decompress notes.aril -o restored/
50
+ ```
51
+
52
+ `-o` is to set output, can be a directory or file name.
53
+
54
+ Use `--model microgen` or `--model micromixer` for full neural compression. These modes predict every byte and are intended for small experiments. The archive records how to decode each block, so extraction needs no model flag.
55
+
56
+ The first operation that uses a predictor downloads its checkpoint from hugging face. MicroMixer downloads about 4 MB of weights.
57
+
58
+ ## Solid compression
59
+
60
+ ```sh
61
+ uv run aril compress notes/ --model solid -o notes-solid.aril
62
+ uv run aril decompress notes-solid.aril -o restored/
63
+ ```
64
+
65
+ Solid mode compresses file contents and archive metadata together in independent 1 MiB groups. Files in the same group can share compression context. It uses LZMA2 and serves as a model-free baseline for ARIL's neural modes.
66
+
67
+ ## Context-mixing experiments
68
+
69
+ ```sh
70
+ uv run aril compress notes/ --model context-neural -o notes-context.aril
71
+ uv run aril decompress notes-context.aril -o restored/
72
+ ```
73
+
74
+ These profiles share a bounded match history across files. `context-flat` models the contents as a single byte stream. `context` adds file type and indentation context. `context-neural` uses the same predictors and adapts their weights online with an integer neural mixer. `context-selective` bypasses that mixer during sustained exact matches. The mixer learns while encoding or decoding and needs no weight download. These modes are experimental and run in Python. `context-neural` uses raw or DEFLATE blocks for Git metadata, binary data, and blocks that DEFLATE shrinks to one-sixth of their original size. For other text, `context-neural` compares the actual neural and conventional payload sizes and keeps the smaller result. Run with `--stats` to see input bytes by compression decision. Use `context-neural-full` to run the mixer on every block.
75
+
76
+ ## Grouped compression
77
+
78
+ ```sh
79
+ uv run aril compress project/ --model grouped --stats -o project.aril
80
+ uv run aril decompress project.aril -o restored/
81
+ ```
82
+
83
+ Grouped mode compares solid LZMA2 with the neural mixer on related text files. C/C++ sources and headers, JavaScript and TypeScript, Python sources and stubs, and assembly sources and includes share file-family groups within each directory. Numbered text files in frame directories also get a previous-frame delta trial. Git metadata and other binary data use conventional compression.
84
+
85
+ Compiled inputs (ELF, Mach-O, PE, WebAssembly, and common object/library suffixes) also get an automatic reversible BCJ filter trial before LZMA2. The filtered stream is kept only when it is smaller than the ordinary grouped candidate, so unrelated binaries cannot regress.
86
+
87
+ Use `--group-size 1`, `4`, or `8` to set the solid group size in MiB. The default is 1 MiB. Neural candidate groups stay bounded at 256 KiB.
88
+
89
+ Use `--jpeg-xl` to try reversible JPEG recompression on JPEG files up to 1 MiB. Compression requires `cjxl` and `djxl` on PATH. ARIL verifies reconstruction of the original JPEG byte-for-byte and keeps the transformed group only if it beats solid compression of the original files. Extraction of a JPEG XL group requires `djxl`.
90
+
91
+ The terminal shows the active route, the file at the group boundary, and an estimate for the current group as progress becomes available.
92
+
93
+ ## Git loose objects
94
+
95
+ Build the optional Preflate helper with Cargo:
96
+
97
+ ```sh
98
+ cargo build --release --locked --manifest-path tools/preflate/Cargo.toml
99
+ uv run aril compress ../repository -o repository.aril --stats
100
+ ```
101
+
102
+ ARIL looks for `aril-preflate` on PATH or under `tools/preflate/target/release` in the checkout. With the helper available, it automatically tries Preflate on loose objects in Git repositories and in grouped mode. The helper verifies the original object bytes before ARIL can keep the candidate. Packfiles use the conventional route. Extraction requires the helper only when an archive contains a Preflate group.
103
+
104
+ Use `--no-preflate` to disable the trial or `--preflate` to require the helper. Loose objects up to 8 MiB can be transformed. An object larger than the configured group size gets its own group.
105
+
106
+ ## Interactive text
107
+
108
+ Run `uv run aril` for the text prompt. It uses `digits:byte_count:binary_prefix` codes. The `decompress` command can also restore files from those codes.
aril-0.1.0/README.md ADDED
@@ -0,0 +1,95 @@
1
+ # ARIL
2
+
3
+ ARIL is a compression method that takes advantage of context, not just content.
4
+
5
+ Compression is inefficient. Encoding a text such as lorum ipsum in ascii produces `01001100 01101111 01110010 01110101 01101101 00100000 01101001 01110000 01110011 01110101 01101101`. Now, this is pretty long. If you were to talk to another person, and say "What word comes after lorum", they'll probably be able to tell you that it's ipsum. So, this program takes advantage of that, and, using a LLM, predicts the next word. This means you can then represent every single phrase, word, and file using a single float between 0 and 1. I explained that really poorly, but [this video](https://www.youtube.com/watch?v=qbsb9DpdZ6s) explains it better. This program, on 1 MiB of wikipedia, performed better than .zip and .gz. However, it isn't perfect yet, and it still loses to bzip2 and xz.
6
+
7
+ ## Setup
8
+
9
+ Requirements: Python 3.13+, [uv](https://docs.astral.sh/uv/), and (optionally) Rust/Cargo for Git Preflate support.
10
+
11
+ ```sh
12
+ git clone github.com/code2344/aril
13
+ cd aril
14
+ uv sync
15
+ ```
16
+
17
+ Run ARIL directly from the checkout:
18
+
19
+ ```sh
20
+ uv run aril --help
21
+ ```
22
+
23
+ To install the command as a user-level tool instead:
24
+
25
+ ```sh
26
+ uv tool install .
27
+ aril --help
28
+ ```
29
+
30
+ ## Files and folders
31
+
32
+ ```sh
33
+ uv sync
34
+ uv run aril compress notes/ -o notes.aril
35
+ uv run aril list notes.aril
36
+ uv run aril decompress notes.aril -o restored/
37
+ ```
38
+
39
+ `-o` is to set output, can be a directory or file name.
40
+
41
+ Use `--model microgen` or `--model micromixer` for full neural compression. These modes predict every byte and are intended for small experiments. The archive records how to decode each block, so extraction needs no model flag.
42
+
43
+ The first operation that uses a predictor downloads its checkpoint from hugging face. MicroMixer downloads about 4 MB of weights.
44
+
45
+ ## Solid compression
46
+
47
+ ```sh
48
+ uv run aril compress notes/ --model solid -o notes-solid.aril
49
+ uv run aril decompress notes-solid.aril -o restored/
50
+ ```
51
+
52
+ Solid mode compresses file contents and archive metadata together in independent 1 MiB groups. Files in the same group can share compression context. It uses LZMA2 and serves as a model-free baseline for ARIL's neural modes.
53
+
54
+ ## Context-mixing experiments
55
+
56
+ ```sh
57
+ uv run aril compress notes/ --model context-neural -o notes-context.aril
58
+ uv run aril decompress notes-context.aril -o restored/
59
+ ```
60
+
61
+ These profiles share a bounded match history across files. `context-flat` models the contents as a single byte stream. `context` adds file type and indentation context. `context-neural` uses the same predictors and adapts their weights online with an integer neural mixer. `context-selective` bypasses that mixer during sustained exact matches. The mixer learns while encoding or decoding and needs no weight download. These modes are experimental and run in Python. `context-neural` uses raw or DEFLATE blocks for Git metadata, binary data, and blocks that DEFLATE shrinks to one-sixth of their original size. For other text, `context-neural` compares the actual neural and conventional payload sizes and keeps the smaller result. Run with `--stats` to see input bytes by compression decision. Use `context-neural-full` to run the mixer on every block.
62
+
63
+ ## Grouped compression
64
+
65
+ ```sh
66
+ uv run aril compress project/ --model grouped --stats -o project.aril
67
+ uv run aril decompress project.aril -o restored/
68
+ ```
69
+
70
+ Grouped mode compares solid LZMA2 with the neural mixer on related text files. C/C++ sources and headers, JavaScript and TypeScript, Python sources and stubs, and assembly sources and includes share file-family groups within each directory. Numbered text files in frame directories also get a previous-frame delta trial. Git metadata and other binary data use conventional compression.
71
+
72
+ Compiled inputs (ELF, Mach-O, PE, WebAssembly, and common object/library suffixes) also get an automatic reversible BCJ filter trial before LZMA2. The filtered stream is kept only when it is smaller than the ordinary grouped candidate, so unrelated binaries cannot regress.
73
+
74
+ Use `--group-size 1`, `4`, or `8` to set the solid group size in MiB. The default is 1 MiB. Neural candidate groups stay bounded at 256 KiB.
75
+
76
+ Use `--jpeg-xl` to try reversible JPEG recompression on JPEG files up to 1 MiB. Compression requires `cjxl` and `djxl` on PATH. ARIL verifies reconstruction of the original JPEG byte-for-byte and keeps the transformed group only if it beats solid compression of the original files. Extraction of a JPEG XL group requires `djxl`.
77
+
78
+ The terminal shows the active route, the file at the group boundary, and an estimate for the current group as progress becomes available.
79
+
80
+ ## Git loose objects
81
+
82
+ Build the optional Preflate helper with Cargo:
83
+
84
+ ```sh
85
+ cargo build --release --locked --manifest-path tools/preflate/Cargo.toml
86
+ uv run aril compress ../repository -o repository.aril --stats
87
+ ```
88
+
89
+ ARIL looks for `aril-preflate` on PATH or under `tools/preflate/target/release` in the checkout. With the helper available, it automatically tries Preflate on loose objects in Git repositories and in grouped mode. The helper verifies the original object bytes before ARIL can keep the candidate. Packfiles use the conventional route. Extraction requires the helper only when an archive contains a Preflate group.
90
+
91
+ Use `--no-preflate` to disable the trial or `--preflate` to require the helper. Loose objects up to 8 MiB can be transformed. An object larger than the configured group size gets its own group.
92
+
93
+ ## Interactive text
94
+
95
+ Run `uv run aril` for the text prompt. It uses `digits:byte_count:binary_prefix` codes. The `decompress` command can also restore files from those codes.
@@ -0,0 +1 @@
1
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
@@ -0,0 +1,12 @@
1
+ from aril.predictor import byte_cdf
2
+
3
+ prefix = b"Once upon a tim"
4
+ cdf = byte_cdf(prefix)
5
+
6
+ assert len(cdf) == 257
7
+ assert cdf[0] == 0 and cdf[-1] == 65_536
8
+ assert all(lo < hi for lo, hi in zip(cdf, cdf[1:]))
9
+
10
+ b = ord("e")
11
+ print(f"Next-byte interval for 'e': [{cdf[b]}, {cdf[b + 1]})")
12
+ print(f"Probability used by ARIL: {(cdf[b + 1] - cdf[b]) / cdf[-1]:.2%}")
@@ -0,0 +1,21 @@
1
+ [project]
2
+ name = "aril"
3
+ version = "0.1.0"
4
+ description = "Lossless text compression with a byte-level language model"
5
+ readme = "README.md"
6
+ requires-python = ">=3.13"
7
+ dependencies = [
8
+ "accelerate==1.16.0",
9
+ "huggingface-hub==2.4.0",
10
+ "safetensors==0.8.0",
11
+ "torch==2.15.0",
12
+ "tqdm==4.70.1",
13
+ "transformers==5.23.0",
14
+ ]
15
+
16
+ [project.scripts]
17
+ aril = "aril.cli:main"
18
+
19
+ [build-system]
20
+ requires = ["hatchling"]
21
+ build-backend = "hatchling.build"
aril-0.1.0/secret ADDED
@@ -0,0 +1,3 @@
1
+ 0.283717852498863063
2
+ 18
3
+ 8
@@ -0,0 +1,3 @@
1
+ from .codec import compress, decompress
2
+
3
+ __all__ = ["compress", "decompress"]
@@ -0,0 +1,4 @@
1
+ from .cli import main
2
+
3
+ if __name__ == "__main__":
4
+ main()
@@ -0,0 +1,199 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to the Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by the Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding any notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. Please also get an original
185
+ on:
186
+
187
+ Copyright [yyyy] [name of copyright owner]
188
+
189
+ Licensed under the Apache License, Version 2.0 (the "License");
190
+ you may not use this file except in compliance with the License.
191
+ You may obtain a copy of the License at
192
+
193
+ http://www.apache.org/licenses/LICENSE-2.0
194
+
195
+ Unless required by applicable law or agreed to in writing, software
196
+ distributed under the License is distributed on an "AS IS" BASIS,
197
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
198
+ implied. See the License for the specific language governing
199
+ permissions and limitations under the License.
@@ -0,0 +1,4 @@
1
+ MicroMixer-4 by llaa33219
2
+ https://github.com/llaa33219/MicroMixer-4
3
+ Source revision: 8300d64843dd9e0baa9270600632c25e5aa15dc5
4
+ Licensed under Apache 2.0. Imports were made package-relative and sys.path overrides removed.
@@ -0,0 +1 @@
1
+ """Pinned MicroMixer-4 inference implementation."""