summaryrefslogtreecommitdiff
path: root/modules/responses/responses.py
diff options
context:
space:
mode:
authorBotond Hende <nettingman@gmail.com>2024-11-27 23:59:07 +0100
committerBotond Hende <nettingman@gmail.com>2024-11-27 23:59:07 +0100
commitcb40a2ff74a8165cb59357c423f83219a01631bc (patch)
treeb672312dd0ab0e4a6de9d96224e78e6523133b13 /modules/responses/responses.py
parent61549211126ff8abc347e9a100b120773dfc2d62 (diff)
basic responses
Diffstat (limited to 'modules/responses/responses.py')
-rw-r--r--modules/responses/responses.py16
1 files changed, 4 insertions, 12 deletions
diff --git a/modules/responses/responses.py b/modules/responses/responses.py
index 1836deb..f89a1fe 100644
--- a/modules/responses/responses.py
+++ b/modules/responses/responses.py
@@ -2,13 +2,9 @@ from dataclasses import dataclass, field
from typing import List, Dict, Any
@dataclass(frozen=True)
-class ResponseData:
- sentence_texts: List[str]
-
-@dataclass(frozen=True)
class Response:
name: str
- data: List[ResponseData] = field(default_factory=list)
+ sentence_texts: List[str]
@dataclass(frozen=True)
class Responses:
@@ -25,13 +21,9 @@ class Responses:
responses={
response_name: Response(
name=response_name,
- data=[
- ResponseData(
- sentence_texts=data_dict["sentences"],
- )
- for data_dict in response_dict["data"]
- ],
+ sentence_texts=response_dict["sentences"]
)
for response_name, response_dict in input_dict["responses"].items()
},
- ) \ No newline at end of file
+ )
+