Spaces:
Sleeping
Sleeping
Download api/schema.py from ApyHTML19/Triple-R-Checker: direct link, hf CLI and curl.
- Browser
- Download file 471 Bytes
-
https://huggingface.co/spaces/ApyHTML19/Triple-R-Checker/resolve/17c64886d5bd347a4dfa37666f8df0c9034ea012/api/schema.py
- Command line
-
hf download hf://spaces/ApyHTML19/Triple-R-Checker@17c64886d5bd347a4dfa37666f8df0c9034ea012/api/schema.py
-
curl -L -o schema.py https://huggingface.co/spaces/ApyHTML19/Triple-R-Checker/resolve/17c64886d5bd347a4dfa37666f8df0c9034ea012/api/schema.py
471 Bytes
| from pydantic import BaseModel | |
| from typing import Dict, List, Optional | |
| class ClaimRequest(BaseModel): | |
| claim: str | |
| model: str = 'logistic' | |
| class EvidenceItem(BaseModel): | |
| statement: str | |
| label: str | |
| similarity: float | |
| reason: Optional[str] = None | |
| class PredictionResponse(BaseModel): | |
| prediction: str | |
| probabilities: Optional[Dict[str, float]] = None | |
| evidence: Optional[List[EvidenceItem]] = None | |
| justification: Optional[str] = None | |