Skip to content

Instantly share code, notes, and snippets.

View wklken's full-sized avatar
😄
Coding

wklken wklken

😄
Coding
View GitHub Profile

工作哲学

你是这个项目的工程协作者,不是待命的助手。参考以下风格:

  • John Carmack 的 .plan 文件风格:做完事情之后报告你做了什么、 为什么这么做、遇到了什么权衡。不问"要不要我做"——你已经做了。
  • BurntSushi 在 GitHub 上的 PR 风格:一次交付是一个完整的、 自洽的、可以被评审的单位。不是"我先试一个你看看",而是 "这是我的方案,理由如下,欢迎指出问题"。
  • Unix 哲学:做一件事,做完,然后闭嘴。过程中的汇报不是礼貌,

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.

@non-static
non-static / status_code_analysis.lua
Last active November 4, 2023 07:56
Lua script for wrk2 to count response code and a particular header
wrk.method = "POST"
local f = io.open("data.json", "r")
wrk.body = f:read("*all")
wrk.headers["Content-Type"] = "application/json"
wrk.headers["Host"] = "foo.bar.net"
local counter = 1
local threads = {}
package main
import (
"fmt"
"log"
"os"
"sync"
"time"
)
@treyhunner
treyhunner / choice_enum.py
Created April 9, 2018 23:49
Enum for use with Django ChoiceField
from enum import Enum, EnumMeta
class ChoiceEnumMeta(EnumMeta):
def __iter__(self):
return ((tag, tag.value) for tag in super().__iter__())
class ChoiceEnum(Enum, metaclass=ChoiceEnumMeta):
"""
@sumanmukherjee03
sumanmukherjee03 / cipher_encryption_decryption.go
Last active June 10, 2025 11:08
AES GCM example in python and go
package main
import (
"crypto/aes"
"crypto/cipher"
"fmt"
"reflect"
"strconv"
"time"
)
@zhiguangwang
zhiguangwang / README.md
Last active March 29, 2026 16:39
Installing and running shadowsocks on Ubuntu Server

Installing and running shadowsocks on Ubuntu Server

16.10 yakkety and above

  1. Install the the shadowsocks-libev package from apt repository.

     sudo apt update
     sudo apt install shadowsocks-libev
    
  2. Save ss.json as /etc/shadowsocks-libev/config.json.

@magnetikonline
magnetikonline / README.md
Last active May 8, 2026 14:00
Bash string manipulation cheatsheet.

Bash string manipulation cheatsheet

Assignment
Assign value to variable if variable is not already set, value is returned.

Combine with a : no-op to discard/ignore return value.
${variable="value"}
: ${variable="value"}
@myusuf3
myusuf3 / delete_git_submodule.md
Created November 3, 2014 17:36
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule
@kelvinn
kelvinn / cmd.sh
Created July 24, 2014 02:55
Example of using Apache Bench (ab) to POST JSON to an API
# post_loc.txt contains the json you want to post
# -p means to POST it
# -H adds an Auth header (could be Basic or Token)
# -T sets the Content-Type
# -c is concurrent clients
# -n is the number of requests to run in the test
ab -p post_loc.txt -T application/json -H 'Authorization: Token abcd1234' -c 10 -n 2000 http://example.com/api/v1/locations/