Instructions to use constehub/rag-evaluation with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use constehub/rag-evaluation with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="constehub/rag-evaluation") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("constehub/rag-evaluation", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use constehub/rag-evaluation 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 constehub/rag-evaluation:Q8_0 # Run inference directly in the terminal: llama cli -hf constehub/rag-evaluation:Q8_0
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf constehub/rag-evaluation:Q8_0 # Run inference directly in the terminal: llama cli -hf constehub/rag-evaluation:Q8_0
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 constehub/rag-evaluation:Q8_0 # Run inference directly in the terminal: ./llama-cli -hf constehub/rag-evaluation:Q8_0
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 constehub/rag-evaluation:Q8_0 # Run inference directly in the terminal: ./build/bin/llama-cli -hf constehub/rag-evaluation:Q8_0
Use Docker
docker model run hf.co/constehub/rag-evaluation:Q8_0
- LM Studio
- Jan
- vLLM
How to use constehub/rag-evaluation with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "constehub/rag-evaluation" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "constehub/rag-evaluation", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/constehub/rag-evaluation:Q8_0
- SGLang
How to use constehub/rag-evaluation 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 "constehub/rag-evaluation" \ --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": "constehub/rag-evaluation", "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 "constehub/rag-evaluation" \ --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": "constehub/rag-evaluation", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use constehub/rag-evaluation with Ollama:
ollama run hf.co/constehub/rag-evaluation:Q8_0
- Unsloth Studio
How to use constehub/rag-evaluation with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for constehub/rag-evaluation to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for constehub/rag-evaluation to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for constehub/rag-evaluation to start chatting
- Pi
How to use constehub/rag-evaluation with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf constehub/rag-evaluation:Q8_0
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "constehub/rag-evaluation:Q8_0" } ] } } }Run Pi
# Start Pi in your project directory: pi
- OpenClaw new
How to use constehub/rag-evaluation with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf constehub/rag-evaluation:Q8_0
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 "constehub/rag-evaluation:Q8_0" \ --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"
- Docker Model Runner
How to use constehub/rag-evaluation with Docker Model Runner:
docker model run hf.co/constehub/rag-evaluation:Q8_0
- Lemonade
How to use constehub/rag-evaluation with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull constehub/rag-evaluation:Q8_0
Run and chat with the model
lemonade run user.rag-evaluation-Q8_0
List all available models
lemonade list
- Hermes Agent
How to use constehub/rag-evaluation with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf constehub/rag-evaluation:Q8_0
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 constehub/rag-evaluation:Q8_0
Run Hermes
hermes
- Atomic Chat
base_model: unsloth/qwen3-8b-unsloth-bnb-4bit
tags:
- text-generation
- rag
- evaluation
- information-retrieval
- question-answering
- retrieval-augmented-generation
- context-evaluation
- qwen3
- unsloth
- fine-tuned
language:
- en
- multilingual
license: apache-2.0
library_name: transformers
pipeline_tag: text-generation
model_type: qwen3
quantized: q8_0
datasets:
- evaluation
- rag-evaluation
metrics:
- completeness
- clarity
- conciseness
- precision
- recall
- mrr
- ndcg
- relevance
widget:
- example_title: RAG Context Evaluation
text: >
Evaluate the agent's response according to the metrics: completeness,
clarity, conciseness, precision, recall, mrr, ndcg, relevance
Question: What are the main benefits of renewable energy?
Retrieved contexts: [1] Renewable energy sources like solar and wind power
provide clean alternatives to fossil fuels, reducing greenhouse gas
emissions and air pollution. [2] These energy sources are sustainable and
abundant, helping to ensure long-term energy security.
model-index:
- name: RAG Context Evaluator
results:
- task:
type: text-generation
name: RAG Evaluation
metrics:
- type: evaluation_score
name: Multi-metric Assessment
value: 0-5
RAG Context Evaluator - Qwen3-8B Fine-tuned π
Model Details π
License: apache-2.0
Finetuned from model: unsloth/qwen3-8b-unsloth-bnb-4bit
Model type: Text Generation (Specialized for RAG Evaluation)
Quantization: Q8_0
Model Description π―
This model is specifically fine-tuned to evaluate the quality of retrieved contexts in Retrieval-Augmented Generation (RAG) systems. It assesses retrieved passages against user queries using multiple evaluation metrics commonly used in information retrieval and RAG evaluation.
Intended Uses π‘
Primary Use Case π―
- RAG System Evaluation: Automatically assess the quality of retrieved contexts for question-answering systems
- Information Retrieval Quality Control: Evaluate how well retrieved documents match user queries
- Academic Research: Support research in information retrieval and RAG system optimization
Evaluation Metrics π
The model evaluates retrieved contexts using the following metrics:
- Completeness π - How thoroughly the retrieved context addresses the query
- Clarity β¨ - How clear and understandable the retrieved information is
- Conciseness πͺ - How efficiently the information is presented without redundancy
- Precision π― - How accurate and relevant the retrieved information is
- Recall π - How comprehensive the retrieved information is in covering the query
- MRR (Mean Reciprocal Rank) π - Ranking quality of relevant results
- NDCG (Normalized Discounted Cumulative Gain) π - Ranking quality with position consideration
- Relevance π - Overall relevance of retrieved contexts to the query
Training Data π
https://huggingface.co/datasets/constehub/rag-evaluation-dataset
Example Training Instance
{
"instruction": "Evaluate the agent's response according to the metrics: completeness, clarity, conciseness, precision, recall, mrr, ndcg, relevance",
"input": {
"question": "Question about retrieved context",
"retrieved_contexts": "[Multiple numbered passages with source citations]"
},
"output": [
{
"name": "completeness",
"value": 1,
"comment": "Detailed evaluation comment"
}
// ... other metrics
]
}
Performance and Limitations β‘
Strengths
- Specialized for RAG evaluation
- Multi-dimensional assessment capability
- Detailed explanatory comments for each metric
Limitations
- Context Length: Performance may vary with very long retrieved contexts
Ethical Considerations π€
- The model should be used as a tool to assist human evaluators, not replace human judgment entirely
- Evaluations should be validated by domain experts for critical applications
Technical Specifications π§
- Base Model: Qwen3-8B
- Quantization: Q8_0
Usage Example π»
from transformers import AutoTokenizer, AutoModelForCausalLM
model_name = "mendrika261/rag-evaluator-qwen3-8b"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForCausalLM.from_pretrained(model_name)
# Example evaluation prompt
prompt = """Evaluate the agent's response according to the metrics: completeness, clarity, conciseness, precision, recall, mrr, ndcg, relevance
Question: [Your question here]
Retrieved contexts: [Your retrieved contexts here]"""
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs)
evaluation = tokenizer.decode(outputs[0], skip_special_tokens=True)
Citation π
If you use this model in your research, please cite:
@misc{constehub-rag-evaluator,
title={RAG Context Evaluator - Qwen3-8B Fine-tuned},
author={constehub},
year={2025},
howpublished={\url{https://huggingface.co/constehub/rag-evaluation}}
}
Contact π§
For questions or issues regarding this model, please contact the developer through the Hugging Face model repository.
This qwen3 model was trained 2x faster with Unsloth and Huggingface's TRL library.
