Command line usage dictionary_generator #301

Closed
opened 2026-01-29 20:41:39 +00:00 by claunia · 1 comment
Owner

Originally created by @Ludea on GitHub (Jan 13, 2020).

Hello,

I success to build Brotli and dictionary_generator with Bazel.
But how to create dictionary ? There is no example into cpp file.
I try dictionary_generator.exe DICTIONARY but help says there is not enough argument.

Maybe can you provide some full examples ?

Originally created by @Ludea on GitHub (Jan 13, 2020). Hello, I success to build Brotli and dictionary_generator with Bazel. But how to create dictionary ? There is no example into cpp file. I try `dictionary_generator.exe DICTIONARY` but help says there is `not enough argument`. Maybe can you provide some full examples ?
Author
Owner

@eustas commented on GitHub (Jul 10, 2023):

It has been improved.

Usage: dictionary_generator [OPTION]... DICTIONARY [SAMPLE]...
Options:
  --dm       use 'deorummolae' engine
  --distill  rewrite samples; unique text parts are removed
  --dsh      use 'durchschlag' engine (default)
  --purify   rewrite samples; unique text parts are zeroed out
  --sieve    use 'sieve' engine
  -b#, --block_len=#
             set block length for 'durchschlag'; default: 1024
  -s#, --slice_len=#
             set slice length for 'distill', 'durchschlag', 'purify'
             and 'sieve'; default: 16
  -t#, --target_dict_len=#
             set target dictionary length (limit); default: 16K
  -u#, --min_slice_pop=#
             set minimum slice population (for rewrites); default: 2
  -c#, --chunk_len=#
             if positive, samples are cut into chunks of this length;
             default: 0; cannot mix with 'rewrite samples'
  -o#, --overlap_len=#
             set chunk overlap length; default 0
# is a decimal number with optional k/K/m/M suffix.
WARNING: 'distill' and 'purify' will overwrite original samples!
         Completely unique samples might become empty files.
@eustas commented on GitHub (Jul 10, 2023): It has been improved. ``` Usage: dictionary_generator [OPTION]... DICTIONARY [SAMPLE]... Options: --dm use 'deorummolae' engine --distill rewrite samples; unique text parts are removed --dsh use 'durchschlag' engine (default) --purify rewrite samples; unique text parts are zeroed out --sieve use 'sieve' engine -b#, --block_len=# set block length for 'durchschlag'; default: 1024 -s#, --slice_len=# set slice length for 'distill', 'durchschlag', 'purify' and 'sieve'; default: 16 -t#, --target_dict_len=# set target dictionary length (limit); default: 16K -u#, --min_slice_pop=# set minimum slice population (for rewrites); default: 2 -c#, --chunk_len=# if positive, samples are cut into chunks of this length; default: 0; cannot mix with 'rewrite samples' -o#, --overlap_len=# set chunk overlap length; default 0 # is a decimal number with optional k/K/m/M suffix. WARNING: 'distill' and 'purify' will overwrite original samples! Completely unique samples might become empty files. ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/brotli#301