HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
zphang
minimal-llama
Python2023–2023
zphang / minimal-llama

minimal-llama

Discover this repository through its Hacker News conversations.

2Distinct people
6Mentions
0Explicit recommenders
453GitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

A public description has not been verified.

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 5:04:57 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by day6 dated mentions

Observed mentions: 2023-03-10 22:05:50 UTC to 2023-03-22 15:41:33 UTC.

01232023-03-10 00:00:00 UTC to 2023-03-11 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 commentsMar 102023-03-11 00:00:00 UTC to 2023-03-12 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2023-03-12 00:00:00 UTC to 2023-03-13 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-13 00:00:00 UTC to 2023-03-14 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2023-03-14 00:00:00 UTC to 2023-03-15 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-15 00:00:00 UTC to 2023-03-16 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-16 00:00:00 UTC to 2023-03-17 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 commentsMar 162023-03-17 00:00:00 UTC to 2023-03-18 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-18 00:00:00 UTC to 2023-03-19 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-19 00:00:00 UTC to 2023-03-20 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-20 00:00:00 UTC to 2023-03-21 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-21 00:00:00 UTC to 2023-03-22 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-03-22 00:00:00 UTC to 2023-03-23 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 commentsMar 22

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
Mar 102023-03-10 00:00:00 UTC2023-03-11 00:00:00 UTC101
Mar 112023-03-11 00:00:00 UTC2023-03-12 00:00:00 UTC101
Mar 122023-03-12 00:00:00 UTC2023-03-13 00:00:00 UTC000
Mar 132023-03-13 00:00:00 UTC2023-03-14 00:00:00 UTC101
Mar 142023-03-14 00:00:00 UTC2023-03-15 00:00:00 UTC000
Mar 152023-03-15 00:00:00 UTC2023-03-16 00:00:00 UTC000
Mar 162023-03-16 00:00:00 UTC2023-03-17 00:00:00 UTC000
Mar 172023-03-17 00:00:00 UTC2023-03-18 00:00:00 UTC000
Mar 182023-03-18 00:00:00 UTC2023-03-19 00:00:00 UTC000
Mar 192023-03-19 00:00:00 UTC2023-03-20 00:00:00 UTC000
Mar 202023-03-20 00:00:00 UTC2023-03-21 00:00:00 UTC000
Mar 212023-03-21 00:00:00 UTC2023-03-22 00:00:00 UTC000
Mar 222023-03-22 00:00:00 UTC2023-03-23 00:00:00 UTC312

What Hacker News says

6 sources
> With no real knowledge of LLM and only recently started to understand what LLM terms mean, such as 'model, inference, LLM model, intruction set, fine tuning' whatelse do you think is required to make a took like yours? This was mee a few weeks ago. I got interested in all this when FlexGen (https://github.com/FMInference/FlexGen) was announced, which allowed to run inference using OPT model on consumer hardware. I'm an avid user of Stable Diffusion, and I wanted to see if I can have an SD equivalent of ChatGPT. Not understanding the details of hyperparameters or terminology, I basically asked ChatGPT to explain to me what these things are: Explain to someone who is a software engineer with limited knowledge of ML terms or linear algebra, what is "feed forward" and "self-attention" in the context of ML and large language models. Provi
Read the rest
de examples when possible. I did the same with all the other terms I didn't understand, like "ADAM optimizer", "gradient", etc. I relied on it very heavily and cross-referenced the answers. Looking at other people's code and just tinkering with things on my own really helped. Through the FlexGen discord I've discovered https://github.com/oobabooga/text-generation-webui where I spent days just playing around with models. This got me into the huggingface ecosystem -- their transformers library is an easy way to get started. I joined a few other discords, like LLaMA Unofficial, RWKV, Eleuther AI, Together, Hivemind and Petals. I bookmarked a bunch of resources but it's very sporadic. Here are some: - https://github.com/zphang/minimal-llama/#peft-fine-tuning-wi... - https://github.com/togethercomputer/OpenChatKit - https://www.cstroik.com/index.php/2023/02/18/finetuning-an-a... - https://github.com/huggingface/peft - https://github.com/kingoflolz/mesh-transformer-jax/blob/mast... - https://github.com/oobabooga/text-generation-webui - https://github.com/hizkifw/WebChatRWKVstic - https://github.com/ggerganov/whisper.cpp - https://github.com/qwopqwop200/GPTQ-for-LLaMa - https://github.com/oobabooga/text-generation-webui/issues/14... - https://github.com/bigscience-workshop/petals - https://github.com/alpa-projects/alpa
In Show HN: Finetune LLaMA-7B on commodity GPUs using your own text
lxe·Mar 22, 2023Submission

Show HN: Finetune LLaMA-7B on commodity GPUs using your own text

I've been playing around with https://github.com/zphang/minimal-llama/ and https://github.com/tloen/alpaca-lora/blob/main/finetune.py, and wanted to create a simple UI where you can just paste text, tweak the parameters, and finetune the model quickly using a modern GPU. To prepare the data, simply separate your text with two blank lines. There's an inference tab, so you can test how the tuned model behaves. This is my first foray into the world of LLM finetuning, Python, Torch, Transformers, LoRA, PEFT, and Gradio. Enjoy!
449 points · Open discussion
I can't edit my comment now, but it's 30B that needs 18GB of VRAM. LLaMA-13B, GPT-3 175B level, only needs 10GB of VRAM with the GPTQ 4bit quantization. >do you think there's anything left to trim? like weight pruning, or LoRA, or I dunno, some kind of Huffman coding scheme that lets you mix 4-bit, 2-bit and 1-bit quantizations? Absolutely. The GPTQ paper claims negligible output quality loss with 3-bit quantization. The GPTQ-for-LLaMA repo supports 3-bit quantization and inference. So this extra 25% savings is already possible. As of right now GPTQ-for-LLaMA is using a VRAM hungry attention method. Flash attention will reduce the requirements for 7B to 4GB and possibly fit 30B with a 2048 context window into 16GB, all before stacking 3-bit. Pruning is a possibility but I'm not aware of anyone working on it yet. LoRa has already been impl
Read the rest
In Visual ChatGPT

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.