File size: 2,577 Bytes
e016773
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
f7f69aa
 
 
 
 
 
 
 
 
 
 
 
efa9adf
f7f69aa
1233c4c
f7f69aa
 
efa9adf
f7f69aa
 
 
 
 
 
 
 
 
 
 
efa9adf
f7f69aa
 
 
 
 
 
 
efa9adf
f7f69aa
 
 
 
7113031
 
 
 
 
f7f69aa
 
7113031
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
f7f69aa
7113031
f7f69aa
7113031
 
 
f7f69aa
 
 
 
 
 
efa9adf
f7f69aa
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
---
license: cc-by-4.0
language:
- en
metrics:
- accuracy
- f1
- recall
- precision
base_model:
- xlnet/xlnet-base-cased
tags:
- xlnet
- text-classification
- privacy
- trust
- mobile-health
- healthcare
- harpt
- finetuned-model
---



# XLNet-base Fine-Tuned on HARPT

**Model Name**: `XLNet-base-finetuned-HARPT`  
**Tags**: `xlnet`, `text-classification`, `privacy`, `trust`, `mobile-health`, `healthcare`, `harpt`, `custom-dataset`, `finetuned-model`  
**License**: *Creative Commons 4.0*

---

## Overview

This is a fine-tuned version of [XLNet-base](https://huggingface.co/xlnet-base-cased) trained on the **HARPT** (**H**ealth **A**pp **R**eviews for **P**rivacy and **T**rust) dataset - a large-scale corpus of mobile health app reviews annotated with labels reflecting privacy and trust-related concerns. The model performs **single-label, multi-class classification** across seven expert-defined categories.


## Classes

The model predicts one of the following seven categories:

- `data_control`
- `data_quality`
- `risk`
- `support`
- `reliability`
- `competence`
- `ethicality`

## Intended Use

- Analyzing trust and privacy concerns in app reviews
- Supporting responsible AI research in digital health
- Benchmarking NLP models on healthcare-oriented text classification

---

## Usage

```python
from transformers import XLNetForSequenceClassification, XLNetTokenizerFast

# Load model and tokenizer
model = XLNetForSequenceClassification.from_pretrained(
    "tk648/XLNet-base-finetuned-HARPT",
    use_safetensors=True
)
tokenizer = XLNetTokenizerFast.from_pretrained("tk648/XLNet-base-finetuned-HARPT")

# Label mapping
id2label = {
    0: "competence",
    1: "data control",
    2: "data quality",
    3: "ethicality",
    4: "reliability",
    5: "risk",
    6: "support"
}

# Run prediction
text = "This app crashes every time I open it."
inputs = tokenizer(
    text,
    return_tensors="pt",
    truncation=True,
    max_length=512,  
    padding=True
)
outputs = model(**inputs)
predicted_class_id = outputs.logits.argmax(dim=1).item()

# Print predicted label
predicted_label = id2label[predicted_class_id]
print("Predicted label:", predicted_label)
```

## If you use this model, please cite:

<small><em>
Timoteo Kelly, Abdulkadir Korkmaz, Samuel Mallet, Connor Souders, Sadra Aliakbarpour, and Praveen Rao. 2025.  
HARPT: A Corpus for Analyzing Consumers’ Trust and Privacy Concerns in Mobile Health Apps. Submitted to: Proceedings of the 34th ACM International Conference on Information and Knowledge Management (CIKM’25).
</em></small>