Skip to content

Instantly share code, notes, and snippets.

View pertrai1's full-sized avatar
🏠
Working from home

Rob Simpson pertrai1

🏠
Working from home
View GitHub Profile
@pertrai1
pertrai1 / llm-wiki.md
Created June 15, 2026 17:32 — 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.

Oh my zsh.

Oh My Zsh

Install ZSH.

sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh

Install Oh my ZSH.

@pertrai1
pertrai1 / actionlist.vim
Created March 10, 2024 23:32 — forked from zchee/actionlist.vim
IdeaVim actionlist
--- Actions ---
$Copy <M-C>
$Cut <M-X> <S-Del>
$Delete <Del> <BS> <M-BS>
$LRU
$Paste <M-V>
$Redo <M-S-Z> <A-S-BS>
$SearchWeb <A-S-G>
$SelectAll <M-A>
$Undo <M-Z>
@pertrai1
pertrai1 / ohmyposhv3-v2.json
Last active October 24, 2021 02:15 — forked from shanselman/ohmyposhv3-v2.json
ohmyposhv3-v2
{
"final_space": true,
"console_title": true,
"console_title_style": "folder",
"blocks": [
{
"type": "prompt",
"alignment": "left",
"horizontal_offset": 0,
"vertical_offset": 0,
@pertrai1
pertrai1 / example01.js
Created April 25, 2018 09:02 — forked from mpj/example01.js
Code for the async/await episode of Fun Fun Function.
const response = await fetch(`https://catappapi.herokuapp.com/users/${userId}`)
const data = await response.json()
return data.imageUrl
}
@pertrai1
pertrai1 / runfile.js
Created October 19, 2016 02:20 — forked from pawelgalazka/runfile.js
Example of runfile.js (for medium article)
import { run } from 'runjs'
const task = {
'clean': () => {
run('rm -rf node_modules')
run('rm -rf build')
},
'build:clean': () => {
run('rm -rf build')
run('mkdir build')
@pertrai1
pertrai1 / package.json
Created October 19, 2016 02:19 — forked from pawelgalazka/package.json
Example of npm scripts
"scripts": {
"clean": "rimraf dist/*",
"prebuild": "npm run clean -s",
"build": "npm run build:scripts -s && npm run build:styles -s && npm run build:markup -s",
"build:scripts": "browserify -d assets/scripts/main.js -p [minifyify --compressPath . --map main.js.map --output dist/main.js.map] | hashmark -n dist/main.js -s -l 8 -m assets.json 'dist/{name}{hash}{ext}'",
"build:styles": "stylus assets/styles/main.styl -m -o dist/ && hashmark -s -l 8 -m assets.json dist/main.css 'dist/{name}{hash}{ext}'",
"build:markup": "jade assets/markup/index.jade --obj assets.json -o dist",
"test": "karma start --singleRun",
"watch": "parallelshell 'npm run watch:test -s' 'npm run watch:build -s'",
"watch:test": "karma start",
@pertrai1
pertrai1 / tmux.md
Created October 6, 2016 16:40 — forked from andreyvit/tmux.md
tmux cheatsheet

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

@pertrai1
pertrai1 / tm2iterm.rb
Created September 14, 2016 06:06 — forked from maxim/tm2iterm.rb
Convert TextMate themes into iTerm 2 color schemes.
#!/usr/bin/env ruby
#
# This script is an astonishing feat of top notch
# rockstar craftsmanship. It totally uses artificial
# intelligence to extract colors out of tmTheme and
# build an itermcolors scheme file for iTerm2.
#
# I know this sounds crazy, but it actually knows
# approximately what colors should be used in the
# ANSI list, and tries to find nearest colors from
@pertrai1
pertrai1 / quick-git-reference.md
Created May 24, 2016 06:25 — forked from vecano/quick-git-reference.md
Quick Git Reference

Quick Git Reference

Configuring

git config --global user.name "<First Last>"
git config --global user.email <johndoe@example.com>
git config --global core.editor <vim>

git config --global color.ui true