Downloads · 30 days
12
33% of all-time downloads
KingTechnician/bert-osmosis-coverage
bert-osmosis-coverage is a machine learning model from KingTechnician. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as apache-2.0.
🎯 A domain-agnostic BERT model for assessing educational conversation coverage
Downloads · 30 days
12
33% of all-time downloads
All-time downloads
36
Public
Repo size
438 MB
Likes
0
Public
Click a slice to open those files.
.bin438 MB · 100%
From the Hugging Face model README
🎯 A domain-agnostic BERT model for assessing educational conversation coverage
This model fine-tunes BERT for educational coverage assessment, predicting how well student conversations address learning objectives. It achieves 0.865 Pearson correlation with coverage assessments, making it suitable for real-time educational applications.
| Metric | Value |
|---|---|
| Pearson Correlation | 0.8650 |
| R-squared | 0.7490 |
| Mean Absolute Error | 0.1330 |
| RMSE | 0.165 |
from transformers import AutoTokenizer
import torch
import torch.nn as nn
from transformers import AutoModel
class BERTCoverageRegressor(nn.Module):
def __init__(self, model_name='bert-base-uncased', dropout_rate=0.3):
super(BERTCoverageRegressor, self).__init__()
self.bert = AutoModel.from_pretrained(model_name)
self.dropout = nn.Dropout(dropout_rate)
self.regressor = nn.Linear(self.bert.config.hidden_size, 1)
def forward(self, input_ids, attention_mask):
outputs = self.bert(input_ids=input_ids, attention_mask=attention_mask)
pooled_output = outputs.pooler_output
output = self.dropout(pooled_output)
return self.regressor(output)
# Load model and tokenizer
tokenizer = AutoTokenizer.from_pretrained('KingTechnician/bert-osmosis-coverage')
model = BERTCoverageRegressor()
# Load the fine-tuned weights
model_path = "pytorch_model.bin" # Download from repo
model.load_state_dict(torch.load(model_path, map_location='cpu'))
model.eval()
# Make prediction
def predict_coverage(objective, conversation, max_length=512):
encoding = tokenizer(
objective,
conversation,
truncation=True,
padding='max_length',
max_length=max_length,
return_tensors='pt'
)
with torch.no_grad():
output = model(encoding['input_ids'], encoding['attention_mask'])
score = torch.clamp(output.squeeze(), 0.0, 1.0).item()
return score
# Example usage
objective = "Understand the process of photosynthesis"
conversation = "Student explains light reactions and Calvin cycle with examples..."
coverage_score = predict_coverage(objective, conversation)
print(f"Coverage Score: {coverage_score:.3f}")
The model expects input in the format:
[CLS] learning_objective [SEP] student_conversation [SEP]
Returns a continuous score between 0.0 and 1.0:
Trained on synthetic educational conversations across multiple domains:
This model implements the methodology from research on domain-agnostic educational assessment, achieving significant improvements over traditional similarity-based approaches:
If you use this model in your research, please cite:
@misc{bert-coverage-assessment,
title={Domain-Agnostic Coverage Assessment Through BERT Fine-tuning},
author={Your Name},
year={2025},
url={https://huggingface.co/KingTechnician/bert-osmosis-coverage}
}
For questions or collaborations, please open an issue in the model repository.
Model Type: Educational AI | Task: Coverage Assessment | Performance: r=0.865