Skip to content

Instantly share code, notes, and snippets.

View slachiewicz's full-sized avatar

Sylwester Lachiewicz slachiewicz

View GitHub Profile

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.

@ngxson
ngxson / FAQ.md
Last active August 5, 2025 17:29
convert ARM NEON to WASM SIMD prompt

Why did you do this?

Relax, I only have one Sunday to work on idea, literally my weekend project. So I tried Deepseek to see if it can help. Surprisingly, it works and it saves me another weekend...

What is your setup?

Just chat.deepseek.com (cost = free) with prompts adapted from this gist.

Does it work in one-shot or I have to prompt it multiple times?

@gnodet
gnodet / Maven4Migration.java
Created January 8, 2025 20:44
JBang script to startup migrating a plugin to the Maven 4 API
///usr/bin/env jbang "$0" "$@" ; exit $?
//DEPS com.github.javaparser:javaparser-core:3.25.7
//DEPS org.apache.commons:commons-lang3:3.14.0
//DEPS info.picocli:picocli:4.7.5
//DEPS org.dom4j:dom4j:2.1.4
//JAVA 17
import com.github.javaparser.JavaParser;
import com.github.javaparser.ast.CompilationUnit;
import com.github.javaparser.ast.ImportDeclaration;
@gnodet
gnodet / plugin-migration.md
Last active September 21, 2025 17:02
Migrating a plugin to Maven 4

Script

The below rules and steps are mostly automated by simply running the Maven4Migration.java jbang script in the plugin directory.

Rules

The rules are quite simple

  • the plugin can only depend on org.apache.maven:maven-api-* artifacts (no any other maven related artifacts) at compile time
  • avoid plexus artifacts at compile time
  • mojo annotations are now in org.apache.maven.api.plugin.annotations package
from uuid import uuid4
from argparse import ArgumentParser
from datetime import datetime, timedelta
# avro stuff
from avro.datafile import DataFileWriter
from avro.io import DatumWriter, BinaryEncoder
# kafka stuff
from confluent_kafka import Producer, Consumer
@adrienbrault
adrienbrault / llama2-mac-gpu.sh
Last active April 8, 2025 13:49
Run Llama-2-13B-chat locally on your M1/M2 Mac with GPU inference. Uses 10GB RAM. UPDATE: see https://twitter.com/simonw/status/1691495807319674880?s=20
# Clone llama.cpp
git clone https://github.com/ggerganov/llama.cpp.git
cd llama.cpp
# Build it
make clean
LLAMA_METAL=1 make
# Download model
export MODEL=llama-2-13b-chat.ggmlv3.q4_0.bin
@int128
int128 / README.md
Last active April 12, 2025 13:02
Example of Envoy TCP Proxy
@machuu
machuu / WSL2_VPN_Workaround_Instructions.md
Last active May 5, 2026 16:15
Workaround for WSL2 network broken on VPN

Overview

Internet connection and DNS routing are broken from WSL2 instances, when some VPNs are active.

The root cause seems to be that WSL2 and the VPN use the same IP address block, and the VPN routing clobbers WSL2's network routing.

This problem is tracked in multiple microsoft/WSL issues including, but not limited to:

@milindchawre
milindchawre / cka-ckad-bookmarks
Created December 14, 2020 10:57
Bookmarks for cka and ckad exam
<!DOCTYPE NETSCAPE-Bookmark-file-1>
<!-- This is an automatically generated file.
It will be read and overwritten.
DO NOT EDIT! -->
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
<TITLE>Bookmarks</TITLE>
<H1>Bookmarks</H1>
<DL><p>
<DT><H3 ADD_DATE="1604897638" LAST_MODIFIED="0" PERSONAL_TOOLBAR_FOLDER="true">Bookmarks bar</H3>
<DL><p>