Phonepadith/laos-long-content
Viewer • Updated • 1.5k • 15 • 1
How to use Phonepadith/aidc-5k-lao-gemma-3n-e4b-it with fastai:
from huggingface_hub import from_pretrained_fastai
learn = from_pretrained_fastai("Phonepadith/aidc-5k-lao-gemma-3n-e4b-it")How to use Phonepadith/aidc-5k-lao-gemma-3n-e4b-it with llama.cpp:
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16 # Run inference directly in the terminal: llama cli -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16 # Run inference directly in the terminal: llama cli -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16 # Run inference directly in the terminal: ./llama-cli -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
docker model run hf.co/Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
How to use Phonepadith/aidc-5k-lao-gemma-3n-e4b-it with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "Phonepadith/aidc-5k-lao-gemma-3n-e4b-it"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "Phonepadith/aidc-5k-lao-gemma-3n-e4b-it",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
How to use Phonepadith/aidc-5k-lao-gemma-3n-e4b-it with Ollama:
ollama run hf.co/Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
How to use Phonepadith/aidc-5k-lao-gemma-3n-e4b-it with Docker Model Runner:
docker model run hf.co/Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
How to use Phonepadith/aidc-5k-lao-gemma-3n-e4b-it with Lemonade:
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Phonepadith/aidc-5k-lao-gemma-3n-e4b-it:F16
lemonade run user.aidc-5k-lao-gemma-3n-e4b-it-F16
lemonade list
This is a Lao language summarization model fine-tuned on the Phonepadith/laos_word_dataset, using the base model google/gemma-3-4b-it. The model is designed to generate concise summaries from Lao language text.
google/gemma-3n-e4b-itlo)adapter-transformersYou can load and use the model with Hugging Face Transformers and adapter-transformers:
from transformers import AutoTokenizer, AutoModelForCausalLM
model_id = "Phonepadith/aidc-5k-lao-gemma-3n-e4b-it" # change to your actual model name
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id)
input_text = "ປັດຈຸບັນ ກອງທັບປະຊາຊົນລາວ ມີການປະກອບວັດຖຸເຕັກນິກທັນສະໄໝສົມຄວນ, ສາມາດຕອບສະໜອງ ໃຫ້ແກ່ວຽກງານປ້ອງກັນຊາດ ໃນໄລຍະໃໝ່ ໄດ້ໂດຍພື້ນຖານ; ໄດ້ປະກອບສ່ວນຢ່າງຕັ້ງໜ້າເຂົ້າໃນການປ້ອງກັນ, ຄວບຄຸມໄພພິບັດ ແລະ ຊ່ວຍເຫລືອປະຊາຊົນ ຜູ້ປະສົບໄພພິບັດທຳມະຊາດຕ່າງໆທີ່ເກີດຂຶ້ນໃນຂອບເຂດທົ່ວປະເທດ. ພ້ອມນັ້ນ, ກໍໄດ້ເປັນເຈົ້າການປະກອບສ່ວນປັບປຸງກໍ່ສ້າງພື້ນ ຖານການເມືອງ, ກໍ່ສ້າງທ່າສະໜາມສົງຄາມປະຊາຊົນ 3 ຂັ້ນ ຕິດພັນກັບວຽກງານ 3 ສ້າງ ຢູ່ທ້ອງຖິ່ນຕາມ 4 ເນື້ອໃນ 4 ຄາດໝາຍ ແລະ ສືບທອດມູນເຊື້ອຄວາມສາມັກຄີ ກັບກອງທັບປະເທດເພື່ອນມິດ ສາກົນ, ປະຕິບັດນະໂຍບາຍເພີ່ມມິດຫລຸດຜ່ອນສັດຕູ, ຮັບປະກັນສະຖຽນລະພາບ ຂອງລະບອບການ ເມືອງ, ຮັກສາຄວາມສະຫງົບປອດໄພຕາມຊາຍແດນ"
inputs = tokenizer(input_text, return_tensors="pt")
summary_ids = model.generate(**inputs, max_new_tokens=100)
summary = tokenizer.decode(summary_ids[0], skip_special_tokens=True)
print(summary)
16-bit