Model reference · open weights

Phi-Hermes

Available as managed deployment Licence fee LLMs teknium Text gen 1 variants 17 dl/mo

Phi-Hermes is an open-weight language model from teknium. AxForge deploys and operates it for you on dedicated EU-owned hardware — with the licence handled where one is required.

Available as managed deployment — configured and operated for you on dedicated EU hardware, quoted per deployment.

What it is

Makerteknium
TypeLanguage models
TaskText gen
Parameters (lead)1.4B
Context2k tokens
Runs withtransformers
Released2023-09-13
Popularity17 downloads / month
LicenceCommercial licence needed

About

What Phi-Hermes is

Phi-1.5 fine tuned with Hermes Dataset

Model Details

Model Sources

This model was trained on the OpenHermes Dataset, made by me, which is over 240,000 mostly GPT-4 generated synthetic datapoints

Uses

Let me know!

How to Get Started with the Model

Phi does not support device_map "auto", and does not seem to want to inference in fp16, so use bf16.

Here is working code to inference, though it can be improved:

import torch
from transformers import AutoModelForCausalLM, AutoTokenizer

model = AutoModelForCausalLM.from_pretrained("teknium/Puffin-Phi-v2", trust_remote_code=True, torch_dtype=torch.bfloat16).to("cuda")
tokenizer = AutoTokenizer.from_pretrained("teknium/Puffin-Phi-v2", trust_remote_code=True, torch_dtype=torch.bfloat16)
inputs = tokenizer(f"### Instruction:\nWrite a negative review for the website, Twitter.\n### Response:\n", return_tensors="pt", return_attention_mask=False)
outputs = model.generate(**inputs, max_length=128, do_sample=True, temperature=0.2, top_p=0.9, use_cache=True, repetition_penalty=1.2, eos_token_id=tokenizer.eos_token_id)
text = tokenizer.batch_decode(outputs)[0]
print(text)

The prompt format is Alpaca, then is prompted like so:

### Instruction:
### Response:

Training Details

Training Procedure

Trained with Axolotl. View the wandb runs for all my puffin runs (this is puffin-phi-4 on wandb): https://wandb.ai/teknium1/hermes-phi/runs/hermes-phi-1

Evaluation

From the published model card. Full card on the HuggingFace links in the sidebar.

Using it via the API

Call it like any OpenAI endpoint

Once AxForge deploys phi-hermes for you, it answers on the OpenAI-compatible API — the same base URL and keys as every other model. (phi-hermes below is illustrative; you get the exact model name on deployment.)

$ curl -sS https://api.axforge.ai/v1/chat/completions \
  -H "Authorization: Bearer $AXFORGE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"phi-hermes","messages":[{"role":"user","content":"Hello"}]}'

Create an account — your API key is available in the console. 5M tokens/month currently included with every new account at launch.

© 2026 AxForge · EU-hosted AI infrastructure Pricing Docs Trust Privacy Terms