Instructions to use eunushosen/jonas-v2-0-2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use eunushosen/jonas-v2-0-2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="eunushosen/jonas-v2-0-2") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("eunushosen/jonas-v2-0-2") model = AutoModelForCausalLM.from_pretrained("eunushosen/jonas-v2-0-2") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use eunushosen/jonas-v2-0-2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "eunushosen/jonas-v2-0-2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "eunushosen/jonas-v2-0-2", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/eunushosen/jonas-v2-0-2
- SGLang
How to use eunushosen/jonas-v2-0-2 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "eunushosen/jonas-v2-0-2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "eunushosen/jonas-v2-0-2", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "eunushosen/jonas-v2-0-2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "eunushosen/jonas-v2-0-2", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use eunushosen/jonas-v2-0-2 with Docker Model Runner:
docker model run hf.co/eunushosen/jonas-v2-0-2
jonas-7b-v2-0
Mistral-7B-Instruct-v0.3 fine-tuned to humanize text, with the LoRA adapter merged into the base weights. Serve with TGI or vLLM (OpenAI-compatible, supports streaming).
Prompt format (must match training)
Send the user message as:
Humanize the following text. Keep the meaning accurate; fix stiff phrasing and rhythm so it reads like something a thoughtful person wrote. Do not add any new information, facts, or opinions not present in the original text. The text type is: {text_type}
{text}
text_type โ {News, Academic, General, Formal, Casual, Legal, Simple}.
Example (OpenAI Messages API, streaming)
curl -N https://<ENDPOINT>/v1/chat/completions \
-H "Authorization: Bearer $HF_TOKEN" -H "Content-Type: application/json" \
-d '{"model":"tgi","stream":true,
"messages":[{"role":"user","content":"Humanize the following text. ... The text type is: General\n\n---\nFurthermore, the data was utilized."}],
"max_tokens":512,"temperature":0.7}'
The `pipeline_tag: text-generation` line is the one that un-greys TGI/vLLM in the engine dropdown โ everything else is documentation.
Now let me wire it into the merge script. Let me check the shell wrapper first.
- Downloads last month
- 82
Model tree for eunushosen/jonas-v2-0-2
Base model
mistralai/Mistral-7B-v0.3 Finetuned
mistralai/Mistral-7B-Instruct-v0.3