Skip to content

Instantly share code, notes, and snippets.

View sundbry's full-sized avatar
⚡
lightning before the thunder

Ryan R Sundberg sundbry

⚡
lightning before the thunder
View GitHub Profile
@mischief
mischief / spacemit-llama.md
Created July 12, 2026 18:01
spacemit k3 llama.cpp

llama.cpp on the SpacemiT K3 Pico-ITX (RISC-V) — Reproduction Guide

Tested 2026-07-11 on: SpacemiT K3 pico-ITX, 32GB RAM SKU, Bianbu 4.0.1 (Resolute Raccoon), kernel 6.18.3, GCC 15.2. 16 cores (8× perf @2.2GHz, 8× @1.8GHz). End result: Qwen3-30B-A3B MoE served at ~38 tok/s prompt processing / ~8-11 tok/s generation, CPU-only, via the SpacemiT IME (integrated matrix engine) instructions.

TL;DR

@oliyh
oliyh / clj-sse.clj
Last active June 19, 2025 07:41
Clojure client for Server Sent Events (SSE)
(require '[clj-http.client :as http])
(require '[clojure.core.async :as a])
(require '[clojure.string :as string])
(require '[clojure.java.io :as io])
(import '[java.io InputStream])
(def event-mask (re-pattern (str "(?s).+?\r\n\r\n")))
(defn- parse-event [raw-event]
(->> (re-seq #"(.*): (.*)\n?" raw-event)
@Rud5G
Rud5G / gist:5604323
Created May 18, 2013 12:57
Gerrit Code Review - Mass Abandon or Mass Approve
# create alias for cli gerrit requests
alias gerrit='ssh -p 29418 gerrit.yourdomain.com gerrit'
# get tempfile for the ids
tmpfileids=$(tempfile -d /tmp)
# get all commit number ids for the project YOUR_PROJECT_NAME
gerrit query 'status:open project:YOUR_PROJECT_NAME' | egrep '^\ +number' | cut -d' ' -f4- > $tmpfileids
# do mass abandon