File size: 578 Bytes
91cb36e
 
 
 
 
 
 
 
 
 
 
25ca7c8
91cb36e
 
 
 
25ca7c8
91cb36e
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23

from handler import EndpointHandler

# init handler
my_handler = EndpointHandler()

# prepare sample payload
example = {
 "inputs": [
   {"uid": "1", "speaker": "Alice", "text": "How much is the fish?" },
   {"uid": "2", "speaker": "Bob", "text": "I do not know about the fish. Because you put a long side and it’s a long side. What do you think." },
{"uid": "3", "speaker": "Alice", "text": "OK, thank you Bob." }
 ],
 "parameters": {
   "uptake_min_num_words": 5,
   "uptake_speaker": "Bob",
    "filename": "sample.csv"
 }
}

# test the handler
print(my_handler(example))