sohom004 commited on
Commit
433971c
·
verified ·
1 Parent(s): 42efe4e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -15,9 +15,9 @@ def get_resolver():
15
  resolver = get_resolver()
16
 
17
  @app.post(path="/api/v1/fastcoref")
18
- def get_coref_resolution(text:str = Body(...)):
19
  result = resolver.resolve_with_confidence(text)
20
- return result
21
 
22
  def get_container_cpu_count():
23
  try:
 
15
  resolver = get_resolver()
16
 
17
  @app.post(path="/api/v1/fastcoref")
18
+ def get_coref_resolution(text:str = Body(...)) -> list[list[str]]:
19
  result = resolver.resolve_with_confidence(text)
20
+ return result["preds"][0].get_clusters(as_strings=True)
21
 
22
  def get_container_cpu_count():
23
  try: