<commit_before>(ns panpan.sasuga
  (:require
    [clojure.string  :as str]
    [jubot.scheduler :as js]
    [jubot.handler   :as jh]
    [jubot.brain     :as jb]))

(def ^:const SASUGA_KEY "sasugaore")

(defn- get-sasuga-count
  []
  (if-let [i (jb/get SASUGA_KEY)] i 0))

(defn sasuga-handler
  [{:keys [user] :as arg}]
  (jh/regexp arg
    #"^s$"
    (fn [& _]
      (let [i (get-sasuga-count)]
        (jb/set SASUGA_KEY (inc i))
        (str "さすが俺" (str/join (repeat i "！")))))))

(def sasuga-schedule
  (js/schedules
    "0 0 9 * * * *"
    (fn [& _]
      (str "昨日は " (get-sasuga-count) "さすが だったよ")
      (jb/set SASUGA_KEY 0))))<commit_msg>update sasuga<commit_after>(ns panpan.sasuga
  (:require
    [clojure.string  :as str]
    [jubot.scheduler :as js]
    [jubot.handler   :as jh]
    [jubot.brain     :as jb]))

(def ^:const SASUGA_KEY "sasugaore")

(defn- get-sasuga-count
  []
  (if-let [i (jb/get SASUGA_KEY)] i 0))

(defn sasuga-handler
  [{:keys [user] :as arg}]
  (jh/regexp arg
    #"^sasuga"
    (fn [& _]
      (let [i (get-sasuga-count)]
        (jb/set SASUGA_KEY (inc i))
        (str "さすが俺" (str/join (repeat i "！")))))))

(def sasuga-schedule
  (js/schedules
    "0 0 9 * * * *"
    (fn [& _]
      (let [i (get-sasuga-count)]
        (jb/set SASUGA_KEY 0)
        (str "昨日は " i "さすが だったよ")))))
{'fraction_non_alphanumeric': 0.19166666666666668, 'fraction_numerical': 0.007575757575757576, 'mean_word_length': 2.4490861618798956, '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': '6473043', 'n_tokens_mistral': 651, 'n_tokens_neox': 610, 'n_words': 131}