Update README.md
Browse files
README.md
CHANGED
|
@@ -210,21 +210,6 @@ RQA judges **logical structure**, not persuasion quality.
|
|
| 210 |
|
| 211 |
---
|
| 212 |
|
| 213 |
-
## π¦ Example Output
|
| 214 |
-
|
| 215 |
-
```json
|
| 216 |
-
{
|
| 217 |
-
"has_issue": true,
|
| 218 |
-
"issue_probability": 0.93,
|
| 219 |
-
"errors": [
|
| 220 |
-
{ "type": "false_causality", "probability": 0.88 }
|
| 221 |
-
],
|
| 222 |
-
"hidden_problem": false,
|
| 223 |
-
"borderline": false
|
| 224 |
-
}
|
| 225 |
-
```
|
| 226 |
-
---
|
| 227 |
-
|
| 228 |
## π Training Data (High-level)
|
| 229 |
|
| 230 |
- **Custom-built dataset**
|
|
@@ -270,24 +255,39 @@ RQA is built around this principle.
|
|
| 270 |
## π Quick Start
|
| 271 |
|
| 272 |
```python
|
|
|
|
| 273 |
from transformers import AutoTokenizer, AutoModel
|
| 274 |
|
|
|
|
|
|
|
| 275 |
tokenizer = AutoTokenizer.from_pretrained(
|
| 276 |
-
"skatzR/RQA-
|
| 277 |
trust_remote_code=True
|
| 278 |
)
|
| 279 |
|
| 280 |
model = AutoModel.from_pretrained(
|
| 281 |
-
"skatzR/RQA-
|
| 282 |
trust_remote_code=True
|
| 283 |
-
)
|
| 284 |
|
| 285 |
-
|
| 286 |
-
outputs = model(**inputs)
|
| 287 |
|
| 288 |
-
has_issue_logits = outputs["has_issue_logits"]
|
| 289 |
-
errors_logits = outputs["errors_logits"]
|
| 290 |
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 291 |
|
| 292 |
---
|
| 293 |
|
|
|
|
| 210 |
|
| 211 |
---
|
| 212 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 213 |
## π Training Data (High-level)
|
| 214 |
|
| 215 |
- **Custom-built dataset**
|
|
|
|
| 255 |
## π Quick Start
|
| 256 |
|
| 257 |
```python
|
| 258 |
+
import torch
|
| 259 |
from transformers import AutoTokenizer, AutoModel
|
| 260 |
|
| 261 |
+
device = "cuda" if torch.cuda.is_available() else "cpu"
|
| 262 |
+
|
| 263 |
tokenizer = AutoTokenizer.from_pretrained(
|
| 264 |
+
"skatzR/RQA-R1",
|
| 265 |
trust_remote_code=True
|
| 266 |
)
|
| 267 |
|
| 268 |
model = AutoModel.from_pretrained(
|
| 269 |
+
"skatzR/RQA-R1",
|
| 270 |
trust_remote_code=True
|
| 271 |
+
).to(device)
|
| 272 |
|
| 273 |
+
model.eval()
|
|
|
|
| 274 |
|
|
|
|
|
|
|
| 275 |
```
|
| 276 |
+
---
|
| 277 |
+
|
| 278 |
+
## π§ Reference Inference Logic
|
| 279 |
+
|
| 280 |
+
RQA is designed to be used with **explicit post-processing logic**, including:
|
| 281 |
+
|
| 282 |
+
- temperature scaling
|
| 283 |
+
- thresholding
|
| 284 |
+
- disagreement diagnostics
|
| 285 |
+
- hidden-problem detection
|
| 286 |
+
|
| 287 |
+
A **fully working reference implementation** is provided here:
|
| 288 |
+
|
| 289 |
+
|
| 290 |
+
π **[π inference.py](https://huggingface.co/skatzR/RQA-X1.1/blob/main/inference.py) β Reference Inference Implementation**
|
| 291 |
|
| 292 |
---
|
| 293 |
|