Skip to content

Instantly share code, notes, and snippets.

View lh0x00's full-sized avatar
💭
do something, something great 📝

Hieu Lam lh0x00

💭
do something, something great 📝
View GitHub Profile
@ahoho
ahoho / prompt_alpaca_lora.py
Last active May 7, 2024 04:28
Create a huggingface pipeline with a lora-trained alpaca
from typing import Optional, Any
import torch
from transformers.utils import is_accelerate_available, is_bitsandbytes_available
from transformers import (
AutoTokenizer,
AutoModelForCausalLM,
GenerationConfig,
pipeline,