Skip to content

Instantly share code, notes, and snippets.

View fritzprix's full-sized avatar
🎯
Focusing

Doowoong(David) Lee fritzprix

🎯
Focusing
View GitHub Profile
@fritzprix
fritzprix / llm-commit.sh
Last active March 25, 2025 08:10
🤖 Generate git commit messages automatically using local LLM (Ollama). Simple bash script that analyzes your git diff and creates meaningful commit messages. No API keys, no cloud - runs locally with Ollama.
#!/bin/bash
# Get the git diff and save it to a temporary file
git diff --cached > /tmp/git_diff.txt
# If there's no diff, exit
if [ ! -s /tmp/git_diff.txt ]; then
echo "No staged changes to commit"
exit 1
fi
@karpathy
karpathy / min-char-rnn.py
Last active April 7, 2025 15:38
Minimal character-level language model with a Vanilla Recurrent Neural Network, in Python/numpy
"""
Minimal character-level Vanilla RNN model. Written by Andrej Karpathy (@karpathy)
BSD License
"""
import numpy as np
# data I/O
data = open('input.txt', 'r').read() # should be simple plain text file
chars = list(set(data))
data_size, vocab_size = len(data), len(chars)