Skip to content

Instantly share code, notes, and snippets.

View dingsdax's full-sized avatar
🔭

Johannes Daxböck dingsdax

🔭
  • Vienna
View GitHub Profile
@dingsdax
dingsdax / gist:ad517d63fbf7b5bd29c4
Last active September 28, 2015 12:47
Ruby NLP resources

Ruby NLP resources

require "bundler/inline"
# allows for declaring a Gemfile inline in a ruby script
# optionally installing any gems that aren't already installed
gemfile(true) do
source "https://rubygems.org"
gem "rails", "6.1.4.1"
gem "sqlite3"
gem "graphql", "~> 1.12"
@dingsdax
dingsdax / tiny_prolog.rb
Last active February 27, 2025 21:56
tiny_prolog.rb
# Ruby archeology: sources:
# https://web.archive.org/web/20070226052918/http://codezine.jp/a/article.aspx?aid=461
# https://web.archive.org/web/20061216170428/http://www.okisoft.co.jp/esc/prolog/in-ruby.html
# Ruby による簡単な Prolog 処理系 h18.9/8 (鈴)
# Simple Prolog processing system using Ruby h18.9/8 (Rin)
# Prolog の述語 (predicate)
class Pred
attr_reader :defs
@dingsdax
dingsdax / Makefile
Created February 27, 2025 22:12 — forked from lnznt/Makefile
Mini Prolog Parser (for Ruby with Racc)
RACC := racc
RACCFLAGS := -g
SOURCES := prolog_parser.ry
TARGETS := ${patsubst %.ry, %.rb, ${SOURCES}}
.SUFFIXES : .rb .ry
%.rb : %.ry
@dingsdax
dingsdax / sentry_queue_test.rb
Created January 15, 2026 13:50
Sentry Queue Time Test Generator
#!/usr/bin/env ruby
# frozen_string_literal: true
# Sentry Queue Time Test Generator
#
# USAGE:
# export SENTRY_DSN='https://your-key@o123.ingest.us.sentry.io/456'
# export SENTRY_SKIP_SSL_VERIFY=true # if you get SSL errors
# ruby sentry_queue_test.rb [duration_minutes] [requests_per_minute] [pattern]
#
@dingsdax
dingsdax / llm-wiki.md
Created April 6, 2026 14:36 — forked from karpathy/llm-wiki.md
llm-wiki

LLM Wiki

A pattern for building personal knowledge bases using LLMs.

This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.

The core idea

Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.