Spaces:
Sleeping
Sleeping
Delete models.py
Browse files
models.py
DELETED
@@ -1,15 +0,0 @@
|
|
1 |
-
from pydantic import BaseModel
|
2 |
-
|
3 |
-
class GuardrailsConfig(BaseModel):
|
4 |
-
factual_consistency: bool = True
|
5 |
-
toxicity: bool = True
|
6 |
-
# Extend with more flags for additional guardrails
|
7 |
-
|
8 |
-
# Request model now includes both the response and the configuration.
|
9 |
-
class CheckRequest(BaseModel):
|
10 |
-
response: str
|
11 |
-
config: GuardrailsConfig = GuardrailsConfig() # Default config if not provided
|
12 |
-
|
13 |
-
class CheckResponse(BaseModel):
|
14 |
-
grounded: bool
|
15 |
-
details: dict
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|