Instructions to use OscarFeMa/ExpertiaMath-Q4 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use OscarFeMa/ExpertiaMath-Q4 with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf OscarFeMa/ExpertiaMath-Q4:F16 # Run inference directly in the terminal: llama cli -hf OscarFeMa/ExpertiaMath-Q4:F16
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf OscarFeMa/ExpertiaMath-Q4:F16 # Run inference directly in the terminal: llama cli -hf OscarFeMa/ExpertiaMath-Q4:F16
Use pre-built binary
# 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 OscarFeMa/ExpertiaMath-Q4:F16 # Run inference directly in the terminal: ./llama-cli -hf OscarFeMa/ExpertiaMath-Q4:F16
Build from source code
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 OscarFeMa/ExpertiaMath-Q4:F16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf OscarFeMa/ExpertiaMath-Q4:F16
Use Docker
docker model run hf.co/OscarFeMa/ExpertiaMath-Q4:F16
- LM Studio
- Jan
- Ollama
How to use OscarFeMa/ExpertiaMath-Q4 with Ollama:
ollama run hf.co/OscarFeMa/ExpertiaMath-Q4:F16
- Unsloth Desktop
- Pi
How to use OscarFeMa/ExpertiaMath-Q4 with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf OscarFeMa/ExpertiaMath-Q4:F16
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "OscarFeMa/ExpertiaMath-Q4:F16" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use OscarFeMa/ExpertiaMath-Q4 with Docker Model Runner:
docker model run hf.co/OscarFeMa/ExpertiaMath-Q4:F16
- Lemonade
How to use OscarFeMa/ExpertiaMath-Q4 with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull OscarFeMa/ExpertiaMath-Q4:F16
Run and chat with the model
lemonade run user.ExpertiaMath-Q4-F16
List all available models
lemonade list
- Hermes Agent
How to use OscarFeMa/ExpertiaMath-Q4 with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf OscarFeMa/ExpertiaMath-Q4:F16
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default OscarFeMa/ExpertiaMath-Q4:F16
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use OscarFeMa/ExpertiaMath-Q4 with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf OscarFeMa/ExpertiaMath-Q4:F16
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "OscarFeMa/ExpertiaMath-Q4:F16" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
ExpertiaMath (Q4_K_M)
Spanish-first mathematics specialist: formal definitions + formulae, no web opinion.
Fine-tuned from microsoft/Phi-4-mini-reasoning (MIT) with QLoRA r16 on 45k
Wikidata-derived definition/formula pairs (+5k validation), 3 epochs on RTX 3070.
Evaluation (500 held-out samples)
| Perplexity | |
|---|---|
| Base | 827.1 |
| + adapter | 63.8 (-92.3%) |
Production: 0.89 quality, 100% cycle success, ~310 pkgs/cycle in the Expertia pipeline.
Variants in this repo
| File | Size | Needs | Use |
|---|---|---|---|
expertia-math-q4_k_m.gguf |
2.5GB | 6GB VRAM | Daily inference (Ollama) |
expertia-math-f16.gguf |
7.7GB | 16GB VRAM | Max quality inference |
fp16/ |
7.2GB | โ | Base for further fine-tuning |
Usage (Ollama)
ollama create ExpertiaMath -f Modelfile-ExpertiaMath-Q4
Note: GGUF uses gpt-2 pre-tokenizer (Ollama โค0.33.3 does not know phi-3);
set num_ctx 8192 (Qwen-family 256K default loads 43GB otherwise).
Limitations
Narrow domain specialist (mathematics). Not a general assistant. Adapter weights: CC-BY-NC-4.0. Base model: MIT (Microsoft).
- Downloads last month
- 29
4-bit
16-bit
Model tree for OscarFeMa/ExpertiaMath-Q4
Base model
microsoft/Phi-4-mini-reasoning