CoolFace
Modelpublic

somieee20/llama-linkedin

sourceHugging Faceapache-2.0updated 11mo agoView on Hugging Face
0likes11downloads
Model Card

Llama-3.1-8B-LinkedIn-Finetune

This model is a QLoRA fine-tuned version of Meta-Llama 3.1 8B Instruct, trained on a curated dataset of 6,200 viral-style LinkedIn posts inspired by top creators like Lara Acosta, Matt Gray, and Mischa G. It is optimized for high-conversion, authentic, and emotionally resonant content generation β€” particularly for founders, creators, and professionals looking to grow influence and inbound leads on LinkedIn.


🧠 Model Details

Model Description

  • β€”Base model: meta-llama/Meta-Llama-3.1-8B-Instruct
  • β€”Fine-tuning method: QLoRA (8-bit quantization, rank = 64)
  • β€”Context length: 4096 tokens
  • β€”Training samples: 6,200 (95 % train / 5 % eval)
  • β€”Hardware: NVIDIA H100 80 GB GPU
  • β€”Precision: bfloat16 with 8-bit loading
  • β€”Epochs: 5
  • β€”Optimizer: AdamW (Torch Implementation)
  • β€”Learning rate: 3e-4 with cosine schedule
  • β€”LoRA target modules: qproj, kproj, vproj, oproj, gateproj, upproj, downproj, lmhead

πŸ“Š Training Configuration

CategoryValue
Batch size (train/eval)8 / 8
Gradient accumulation2
Warmup ratio0.05
Weight decay0.01
Max grad norm1.0
Dropout (LoRA)0.05
Learning rate schedulerCosine
Save/eval frequencyEvery 200 steps
Total checkpoints kept5
LoggingW&B (llama-3.1-8b-finetune)
OptimizerAdamW (β₁ = 0.9, Ξ²β‚‚ = 0.999, Ξ΅ = 1e-8)
Quantization8-bit with llm_int8_threshold = 6.0
Mixed precisionbf16 (True)

πŸ’Ύ Dataset

The dataset consists of 6000+ real viral posts from top creators, expanded synthetically to ~6,200 samples using generative augmentation for tone, structure, and narrative diversity. Each post follows the LinkedIn-native storytelling format (hook β†’ story β†’ lesson β†’ CTA) with labeled stylistic attributes such as authenticity, pacing, and emotional tone.


βš™οΈ Use Cases

βœ… Direct Use

  • β€”Generating high-quality LinkedIn posts or storytelling templates.
  • β€”Writing thought leadership content for founders or coaches.
  • β€”Producing outbound copy for cold outreach that feels β€œhuman.”

πŸ”§ Downstream Use

  • β€”Integrate into marketing automation tools or content CRMs.
  • β€”Use as a base for persona-tuned agents (e.g., β€œMatt-style writer”).
  • β€”Fine-tune further for niche B2B verticals (e.g., SaaS, AI, VC).

🚫 Out-of-Scope

  • β€”Political or sensitive opinion generation.
  • β€”Automated spam or fake persona creation.

🧩 How to Use

python
from transformers import AutoTokenizer, AutoModelForCausalLM

model_id = "somieee20/llama-3.1-8b-linkedin"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id)

prompt = "Write a viral LinkedIn post about learning from startup failures."
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens=300, temperature=0.8, do_sample=True)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))