Downloads · 30 days
114
16% of all-time downloads
yothinS/gemma4-thai-marketing
gemma4-thai-marketing is a text generation model from yothinS. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
นี่คือโมเดลภาษาขนาดใหญ่ (LLM) สถาปัตยกรรม Gemma 4 E2b ที่ผ่านการทำ Fine-tuning (QLoRA) เพื่อปรับจูนความเชี่ยวชาญเฉพาะทางด้าน Performance Marketing (การตลาดออนไลน์ที่เน้นผลลัพธ์) โดยเฉพาะการวิเคราะห์คоขวดของการยิงโฆษณา…
Downloads · 30 days
114
16% of all-time downloads
All-time downloads
731
Public
Parameters
5.1B
15.3 GB on disk
Likes
1
Public
Click a slice to open those files.
.safetensors10.3 GB · 99%
From the Hugging Face model README
นี่คือโมเดลภาษาขนาดใหญ่ (LLM) สถาปัตยกรรม Gemma 4 E2b ที่ผ่านการทำ Fine-tuning (QLoRA) เพื่อปรับจูนความเชี่ยวชาญเฉพาะทางด้าน Performance Marketing (การตลาดออนไลน์ที่เน้นผลลัพธ์) โดยเฉพาะการวิเคราะห์คоขวดของการยิงโฆษณา (Meta Ads, TikTok Ads) และการวิเคราะห์ข้อมูลทางธุรกิจในรูปแบบโครงสร้างคำแนะนำแบบมีเหตุมีผล (IF-THEN Actionable Insights) เป็นภาษาไทย
/lora) และโมเดลรวมร่างตัวเต็ม (Merged 16-bit) ในหน้าแรกโมเดลนี้ได้รับการฝึกฝนผ่านชุดข้อมูล: yothinS/Thai_performance_marketing ซึ่งผ่านการคลีนและจัดโครงสร้างในรูปแบบ OpenAI Chat Format บันทึกบทสนทนาแนวคิดและตัวเลขสถิติทางการตลาดออนไลน์ (CPM, CTR, CPC, CVR, ROAS)
กระบวนการจูนใช้การตั้งค่าพารามิเตอร์ที่มีความเสถียรสูงสุดสำหรับการ์ดจอ T4 GPU ดังนี้:
q_proj, k_proj, v_proj, o_proj, gate_proj, up_proj, down_proj)เนื่องจากโมเดลในหน้าแรกถูกรวมร่าง (model.safetensors) เรียบร้อยแล้ว คุณสามารถดึงไปใช้ผ่านไลบรารีดั้งเดิมได้ทันที:
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
model_id = "yothinS/gemma4-thai-marketing"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
torch_dtype=torch.float16,
device_map="auto"
)
# จัดฟอร์แมตข้อความแบบ Chat Template ของ Gemma 4 (Multimodal Input Format)
messages = [
{
"role": "user",
"content": [
{
"type": "text",
"text": "แคมเปญ E-commerce งบ 5,000 บาท/วัน CTR 2.4% แต่ CVR ต่ำมากเพียง 0.2% ควรวิเคราะห์คอขวดอย่างไร"
}
]
}
]
inputs = tokenizer.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens=1024, temperature=0.7, top_p=0.95)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
หากต้องการดึงเฉพาะไฟล์น้ำหนักตัวเสริมไปประกบกับ Gemma 4 ตัวดั้งเดิม:
from unsloth import FastLanguageModel
import torch
model, tokenizer = FastLanguageModel.from_pretrained(
model_name = "unsloth/gemma-4-E2b-it",
lora_model = "yothinS/gemma4-thai-marketing",
subfolder = "lora", # ดึงจากโฟลเดอร์ย่อย lora
max_seq_length = 2048,
load_in_4bit = True
)