Skip to content

Instantly share code, notes, and snippets.

View ron-wolf's full-sized avatar
🙌
Open for work!

Ron Wolf ron-wolf

🙌
Open for work!
View GitHub Profile
@xeubie
xeubie / next-gen-sqlite.md
Last active June 19, 2026 00:30
The next-gen SQLite won't look like SQLite

SQLite was thought of as a toy for many years until we all realized it was actually nice to use a database as a library, even server-side. And yet...

  1. It's a big dependency, despite what you think. In no universe is 150,000 lines of C code "lightweight".
  2. Like with all SQL databases, you have an impedance mismatch: the way you store data in memory is completely different than the table structure a SQL database forces on you, leading to tons of glue code.
  3. It's mutable, so it can't undo or time travel, and it can't read while a write is happening (even in WAL mode...reads can't happen during checkpointing!).

To solve these problems, I'm building a database called xitdb:

  1. At only about 4,000 lines of code with no dependencies, xitdb is actually lightweight. You could reimplement it in another language pretty easily.
  2. It exposes rich data structures rather than a SQL interface, so the API is very similar to the in-memory data structures you already use in your program.
@rendello
rendello / _unicode_roundtrip_unsafe.txt
Last active November 25, 2024 00:55
Unicode roundtrip-unsafe characters. They change to different characters (or sets of characters) when case is changed and then changed back.
Uppercase -> lowercase -> uppercase:
İ i̇ İ LATIN CAPITAL LETTER I WITH DOT ABOVE -> LATIN SMALL LETTER I, COMBINING DOT ABOVE -> LATIN CAPITAL LETTER I, COMBINING DOT ABOVE
Ω ω Ω OHM SIGN -> GREEK SMALL LETTER OMEGA -> GREEK CAPITAL LETTER OMEGA
ẞ ß SS LATIN CAPITAL LETTER SHARP S -> LATIN SMALL LETTER SHARP S -> LATIN CAPITAL LETTER S, LATIN CAPITAL LETTER S
K k K KELVIN SIGN -> LATIN SMALL LETTER K -> LATIN CAPITAL LETTER K
Å å Å ANGSTROM SIGN -> LATIN SMALL LETTER A WITH RING ABOVE -> LATIN CAPITAL LETTER A WITH RING ABOVE
ϴ θ Θ GREEK CAPITAL THETA SYMBOL -> GREEK SMALL LETTER THETA -> GREEK CAPITAL LETTER THETA
Lowercase -> uppercase -> lowercase:
ῗ Ϊ͂ ῗ GREEK SMALL LETTER IOTA WITH DIALYTIKA AND PERISPOMENI -> GREEK CAPITAL LETTER IOTA, COMBINING DIAERESIS, COMBINING GREEK PERISPOMENI -> GREEK SMALL LETTER IOTA, COMBINING DIAERESIS, COMBINING GREEK PERISPOMENI
@rendello
rendello / _utf8_case_data.rs
Last active December 25, 2025 23:54
Unicode codepoints that expand or contract when case is changed in UTF-8. Good for testing parsers. Includes the data `utf8_case_data.rs` and the script to generate it, `generate_utf8.py`.
/*
Copyright (c) 2024 Rendello
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
@tristandruyen
tristandruyen / calibration_data_v5_rc.txt
Last active June 28, 2026 22:46 — forked from bartowski1182/calibration_datav3.txt
Adapted from bartowskis v3, added more languages for sparse moe models like qwen 57B-A14B. Calibration data provided by Dampf, combines his own efforts on top of Kalomaze's. Used for calibrating GGUF imatrix files
===========
; A072257: a(n) = ((6*n-17)*4^n - 1)/3.
; -6,-15,-27,21,597,4437,25941,136533,677205,3233109,15029589,68506965,307582293,1364546901,5995058517,26127717717,113100805461,486762960213,2084490794325,8887718991189,37749899220309,159795689903445,674367131702613,2838206015165781,11915774014084437,49914895870022997,208666782734832981,870695927958295893,3626898899909039445,15084056351939581269,62642068416972019029,259791645704742851925,1076060070966390510933,4451814236455238456661,18397552756179659478357,75951394266153460520277,313250310030353132508501,1290780171984369691743573,5314236415389307413812565,21861408571364544242603349,89863485924687435319825749,369125350255666774676952405,1515187027250335232298407253,6215490613912013463556019541,25480932475290743991673640277,104399609979733736516492809557,427501960233217988265164232021,1749621922190004121857428903253,7156944013788545162616803513685,29261601355268295351215565657429,119581706621529640207855669040469,488468031287944396043396301804885,1994436944359
@bartowski1182
bartowski1182 / calibration_datav3.txt
Last active June 4, 2026 23:13
Calibration data provided by Dampf, combines his own efforts on top of Kalomaze's. Used for calibrating GGUF imatrix files
In addition to a significant decrease in hepatic lipid accumulation in the IOE group, which inhibited energy intake by propionate enrichment, hepatic lipids were also significantly reduced in the mice in the IOP group, which was largely enriched with butyrate. Compared with the IOE group, IOP had a stronger regulatory effect on hepatic metabolism and triglyceride metabolism and higher levels of TCA cycle in the host. In addition, butyrate has the ability to promote browning of white adipose tissue (WAT) to brown adipose tissue (BAT).^[@ref39],[@ref40]^ WAT stores energy, whereas BAT uses energy for heating and consequently host energy expenditure increases.^[@ref41],[@ref42]^ However, adipose tissue weight does not change after WAT browning.^[@ref43]^ Therefore, the weight of adipose tissue of mice in the IOP group dominated by butyrate was greater than that of the mice in the IOE group dominated by propionate.
In conclusion ([Figure [7](#fig7){ref-type="fig"}](#fig7){ref-type="fig"}C), the improvement of ob
From e4db4f07e77feb1c126e7afbf441e9eae34b4e57 Mon Sep 17 00:00:00 2001
From: Kelvie Wong <kelvie@kelvie.ca>
Date: Sun, 2 Oct 2022 13:23:25 -0700
Subject: [PATCH] Add a lockdown_hibernate parameter
This allows the user to tell the kernel that they know better (namely,
they secured their swap properly), and that it can enable hibernation.
Signed-off-by: Kelvie Wong <kelvie@kelvie.ca>
---
@jbott
jbott / install.sh
Last active October 19, 2025 02:48 — forked from mx00s/install.sh
NixOS install script based on @grahamc's "Erase Your Darlings" blog post
#!/usr/bin/env bash
#
# NixOS install script synthesized from:
#
# - Erase Your Darlings (https://grahamc.com/blog/erase-your-darlings)
# - ZFS Datasets for NixOS (https://grahamc.com/blog/nixos-on-zfs)
# - NixOS Manual (https://nixos.org/nixos/manual/)
# - Original gist by @nuxeh (https://gist.github.com/nuxeh/35fb0eca2af4b305052ca11fe2521159)
#
@DavidBuchanan314
DavidBuchanan314 / widevine_fixup.py
Last active April 3, 2026 23:35
Patch aarch64 widevine blobs from ChromeOS to work on non-ChromeOS linux, including platforms with 16K page size like Apple Silicon / Asahi Linux
"""
MIT License
Copyright (c) 2023 David Buchanan
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
@cedrickchee
cedrickchee / LLMs.md
Last active January 24, 2024 06:16 — forked from yoavg/LLMs.md
Fix typos and grammar of the original writing.

Some remarks on Large Language Models

Yoav Goldberg, January 2023

Audience: I assume you heard of ChatGPT, maybe played with it a little, and was impressed by it (or tried very hard not to be). And that you also heard that it is "a large language model". And maybe that it "solved natural language understanding". Here is a short personal perspective of my thoughts of this (and similar) models, and where we stand with respect to language understanding.

Intro

Around 2014-2017, right within the rise of neural-network based methods for NLP, I was giving a semi-academic-semi-popsci lecture, revolving around the story that achieving perfect language modeling is equivalent to being as intelligent as a human. Somewhere around the same time I was also asked in an academic panel "what would you do if you were given infinite compute and no need to worry about labor costs" to which I cockily responded "I would train a really huge language model, just to show that it doesn't solve everything!". We

@kelvie
kelvie / 0001-Add-a-lockdown_hibernate-parameter.patch
Created October 2, 2022 23:39
Enable hibernate during lockdown
From e4db4f07e77feb1c126e7afbf441e9eae34b4e57 Mon Sep 17 00:00:00 2001
From: Kelvie Wong <kelvie@kelvie.ca>
Date: Sun, 2 Oct 2022 13:23:25 -0700
Subject: [PATCH] Add a lockdown_hibernate parameter
This allows the user to tell the kernel that they know better (namely,
they secured their swap properly), and that it can enable hibernation.
Signed-off-by: Kelvie Wong <kelvie@kelvie.ca>
---