<commit_before>(ns ^{:no-doc true} onyx.state.serializers.windowing-key-encoder
  (:import [org.agrona.concurrent UnsafeBuffer]
           [java.nio.ByteOrder]))

;; TODO: try to remove the extra allocation in get-bytes
;; It would be preferable to directly write from the buffer into LMDB
(defprotocol PEncoder
  (set-state-idx [this idx])
  (set-group-id [this group-id])
  (set-min-extent [this] "Set the minimum extent representable in lexicographic order to allow for iteration.")
  (set-extent [this extent])
  (get-bytes [this])
  (wrap-impl [this bs])
  (length [this]))
<commit_msg>Fix invalid :import caught with Clojure 1.10 specs (#881)<commit_after>(ns ^{:no-doc true} onyx.state.serializers.windowing-key-encoder
  (:import [org.agrona.concurrent UnsafeBuffer]
           [java.nio ByteOrder]))

;; TODO: try to remove the extra allocation in get-bytes
;; It would be preferable to directly write from the buffer into LMDB
(defprotocol PEncoder
  (set-state-idx [this idx])
  (set-group-id [this group-id])
  (set-min-extent [this] "Set the minimum extent representable in lexicographic order to allow for iteration.")
  (set-extent [this extent])
  (get-bytes [this])
  (wrap-impl [this bs])
  (length [this]))

{'fraction_non_alphanumeric': 0.12561174551386622, 'fraction_numerical': 0.004893964110929853, 'mean_word_length': 4.1991525423728815, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7244567', 'n_tokens_mistral': 402, 'n_tokens_neox': 385, 'n_words': 131}