Skip to content

Instantly share code, notes, and snippets.

View turboBasic's full-sized avatar
🔮
Focusing

andriy melnyk turboBasic

🔮
Focusing
View GitHub Profile
@turboBasic
turboBasic / llm-wiki.md
Created June 26, 2026 22:40 — 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.

@turboBasic
turboBasic / list_github_org.py
Last active April 22, 2026 14:38
List GitHub teams in an organization #github
#!/usr/bin/env python3
"""List GitHub organization teams and print matching team names.
Usage:
export GITHUB_TOKEN="<token-with-read:org>"
python3 list_github_org.py --org your-org-name find-teams-with-members --user-names user1,user2
Notes:
- For private org/team visibility, the token needs at least `read:org` scope.
- Fine-grained tokens must include organization members/teams read permissions.
@turboBasic
turboBasic / Web page code snippets.md
Created April 17, 2026 07:24
Code snippets for browser's console #javascript #js #browser

Code snippets for querying web pages in a browser's console

Select contents of all elements of <span>1234567</span> format

[...document.querySelectorAll('span')]
  .filter(el => /^\d+$/.test(el.textContent.trim()))
  .map(el => el.textContent.trim())
@turboBasic
turboBasic / awesome-sashiko-en.md
Last active November 22, 2025 08:35
Awesome list of resources about #sashiko, #kantha and #visible_mending. Список ресурсів про сашіко, кантха і visible mending

About

This is an awesome list or resources on sashiko, kantha, visible mending and other related techniques.

Overview

Techniques related to sashiko

@turboBasic
turboBasic / redirect-stdin-and-stdout-to-terminal.zsh
Last active June 21, 2025 14:32
Forcefully read text from terminal even when in pipeline #zsh #shell
#!/usr/bin/env zsh
## Save initial state
exec {saved_stdin}<&0 # save initial stdin
exec {saved_stdout}>&1 # save initial stdout
## Redirect initial stdin and stdout to terminal
@turboBasic
turboBasic / locale-demo.zsh
Last active June 12, 2025 12:18
Locale comparison functions #zsh #bash
# Usage: compare-locales LC_TIME POSIX de_DE.UTF-8 'date'
function compare-locales() {
local -r category="$1"
local -r locale1="$2"
local -r locale2="$3"
local -r command="$4"
#echo "=== Comparing '$command' in $locale1 and $locale2 ==="
printf "Output in %-15s %s\n" "$locale1:" "$(
export "$category=$locale1"
@turboBasic
turboBasic / git-commit-size
Last active June 10, 2025 08:55 — forked from kobake/git-commit-size.sh
Calculate size of a git commit object #git
# Calculate the size of a git commit in bytes.
function git-commit-size() {
# This script calculates the size of a git commit in bytes.
# Usage: git-commit-size.sh <commit hash>
#
# Example:
# git-commit-size.sh 1234567
#
# Output:
# The total size of the commit in bytes, formatted with thousands separators.
@turboBasic
turboBasic / aws.zsh
Last active May 20, 2025 10:39
Helpers for AWS CLI #aws #zsh
# List running EC2 instances filtered by `Name` tag
#
# params:
# $1 - optional string. Filters output by instances with `Name` tag containing the string
function aws-ec2() {
aws ec2 describe-instances \
--filter "Name=instance-state-name,Values=running" \
--filter "Name=tag:Name,Values=*$1*" \
--query "Reservations[].Instances[].{
id: InstanceId,
@turboBasic
turboBasic / bw-get-field
Last active April 4, 2025 15:54
Get field from Bitwarden item #zsh
#!/bin/sh
item=$1
field=$2
bw get item "$1" \
| jq --raw-output '.fields[] | select(.name == "'"$field"'") | .value'
@turboBasic
turboBasic / .zshrc
Last active May 6, 2023 03:05
Zshrc file for zdharma-continuum/zinit framework #zsh #zinit #dotfiles
## Global vars
export LESS='--buffers=128 --HILITE-UNREAD --ignore-case --LONG-PROMPT --max-back-scroll=15 --no-init --quiet --quit-at-eof --quit-if-one-screen --RAW-CONTROL-CHARS --status-column --tabs=4 --window=-4'
export FZF_DEFAULT_COMMAND='rg --files --no-ignore --hidden --follow --glob "!.git/*"'
export FZF_DEFAULT_OPTS='--height 50% --ansi --info=inline'
export EDITOR='/usr/local/bin/nvim'
## zinit
source ~/.zinit/bin/zinit.zsh