Downloads · 30 days
72
5% of all-time downloads
RichardErkhov/mhenrichsen_-_danskgpt-tiny-chat-gguf
mhenrichsen_-_danskgpt-tiny-chat-gguf is a machine learning model from RichardErkhov. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
Downloads · 30 days
72
5% of all-time downloads
All-time downloads
1.3K
Public
Repo size
12.7 GB
Likes
0
Public
Click a slice to open those files.
.gguf14.7 GB · 100%
From the Hugging Face model README
Quantization made by Richard Erkhov.
danskgpt-tiny-chat - GGUF
| Name | Quant method | Size |
|---|---|---|
| danskgpt-tiny-chat.Q2_K.gguf | Q2_K | 0.4GB |
| danskgpt-tiny-chat.IQ3_XS.gguf | IQ3_XS | 0.44GB |
| danskgpt-tiny-chat.IQ3_S.gguf | IQ3_S | 0.47GB |
| danskgpt-tiny-chat.Q3_K_S.gguf | Q3_K_S | 0.47GB |
| danskgpt-tiny-chat.IQ3_M.gguf | IQ3_M | 0.48GB |
| danskgpt-tiny-chat.Q3_K.gguf | Q3_K | 0.51GB |
| danskgpt-tiny-chat.Q3_K_M.gguf | Q3_K_M | 0.51GB |
| danskgpt-tiny-chat.Q3_K_L.gguf | Q3_K_L | 0.55GB |
| danskgpt-tiny-chat.IQ4_XS.gguf | IQ4_XS | 0.57GB |
| danskgpt-tiny-chat.Q4_0.gguf | Q4_0 | 0.59GB |
| danskgpt-tiny-chat.IQ4_NL.gguf | IQ4_NL | 0.6GB |
| danskgpt-tiny-chat.Q4_K_S.gguf | Q4_K_S | 0.6GB |
| danskgpt-tiny-chat.Q4_K.gguf | Q4_K | 0.62GB |
| danskgpt-tiny-chat.Q4_K_M.gguf | Q4_K_M | 0.62GB |
| danskgpt-tiny-chat.Q4_1.gguf | Q4_1 | 0.65GB |
| danskgpt-tiny-chat.Q5_0.gguf | Q5_0 | 0.71GB |
| danskgpt-tiny-chat.Q5_K_S.gguf | Q5_K_S | 0.71GB |
| danskgpt-tiny-chat.Q5_K.gguf | Q5_K | 0.73GB |
| danskgpt-tiny-chat.Q5_K_M.gguf | Q5_K_M | 0.73GB |
| danskgpt-tiny-chat.Q5_1.gguf | Q5_1 | 0.77GB |
| danskgpt-tiny-chat.Q6_K.gguf | Q6_K | 0.84GB |
| danskgpt-tiny-chat.Q8_0.gguf | Q8_0 | 1.09GB |
license: apache-2.0 base_model: mhenrichsen/danskgpt-tiny tags:
DanskGPT-tiny-chat er chat-varianten af mhenrichsen/danskgpt-tiny trænet på private chat datasæt.
Modellen er beregnet til at være en lightweight version af DanskGPT, der kan køre på næsten alle enheder.
Modellen er trænet med ChatML format (samme som OpenAI's modeller), og skal bruges på følgende måde:
<|im_start|>system\nDu er en hjælpsom assistent.<|im_end|>\n<|im_start|>user\nHvad er skak?<|im_end|>\n<|im_start|>assistant
Installér ollama: https://ollama.ai/download
Kør:
ollama run mhenrichsen/danskgpt-tiny-chat
pip install vllm
from vllm import LLM, SamplingParams
sampling_params = SamplingParams(temperature=0.8, top_p=0.95, max_tokens=1024)
llm = LLM(model="mhenrichsen/danskgpt-tiny-chat")
system_message = "Du er en hjælpsom assistent."
conversation_history = f"<|im_start|>system\n{system_message}<|im_end|>\n<|im_start|>user\n"
while True:
prompt = input("Bruger: ")
new_prompt = f"{conversation_history}{prompt}<|im_end|>\n<|im_start|>assistant\n"
outputs = llm.generate(new_prompt, sampling_params)
for output in outputs:
prompt = output.prompt
generated_text = output.outputs[0].text
print(f"AI: {generated_text!r}")
conversation_history = f"{prompt}{generated_text!r}<|im_end|>\n<|im_start|>user\n"
pip install openai
python -m vllm.entrypoints.openai.api_server --model mhenrichsen/danskgpt-tiny-chat
og brugt som erstatning for OpenAI's endpoints:
from openai import OpenAI
openai_api_key = "EMPTY"
openai_api_base = "http://localhost:8000/v1"
client = OpenAI(
api_key=openai_api_key,
base_url=openai_api_base,
)
chat_response = client.chat.completions.create(
model="mhenrichsen/danskgpt-tiny-chat",
messages=[
{"role": "system", "content": "Du er en hjælpsom assistent. Giv mig et langt svar."},
{"role": "user", "content": "Fortæl mig om Danmark."},
]
)
print("AI:", chat_response)
| Training Loss | Epoch | Step | Validation Loss |
|---|---|---|---|
| 1.3599 | 0.0 | 1 | 1.4118 |
| 0.7896 | 0.25 | 136 | 0.7813 |
| 0.7339 | 0.5 | 272 | 0.7490 |
| 0.7378 | 0.75 | 408 | 0.7285 |
| 0.7112 | 1.0 | 544 | 0.7146 |
| 0.6377 | 1.23 | 680 | 0.7135 |
| 0.6192 | 1.49 | 816 | 0.7133 |
| 0.5985 | 1.74 | 952 | 0.7073 |
| 0.6067 | 1.99 | 1088 | 0.7026 |
| 0.5139 | 2.22 | 1224 | 0.7167 |
| 0.5099 | 2.47 | 1360 | 0.7193 |
| 0.5217 | 2.72 | 1496 | 0.7168 |
Har du spørgsmål eller brug for hjælp til LLM'er eller automatisering af tekstbaserede opgaver, så kontakt mig gerne.
/Mads