From 14f3ba51714de3bd8f79a210dca02588c5687d78 Mon Sep 17 00:00:00 2001 From: Aleksey Filippov Date: Fri, 14 Jan 2022 17:11:12 +0400 Subject: [PATCH] Add syntax server address --- main.py | 3 ++- syntax.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index 00a8b99..da96c7d 100644 --- a/main.py +++ b/main.py @@ -18,7 +18,8 @@ def _main(): speech_server = 'http://vosk.athene.tech' text = Speech().run(wav_file, speech_server) print(f'Text: {text}') - parse_tree = Syntax().run(text) + syntax_server = 'http://syntaxnet.athene.tech' + parse_tree = Syntax().run(text, syntax_server) print(f'Parse tree: {parse_tree}') diff --git a/syntax.py b/syntax.py index 52a52a2..8d5876b 100644 --- a/syntax.py +++ b/syntax.py @@ -1,3 +1,4 @@ class Syntax: - def run(self, text: str) -> str: + + def run(self, text: str, server: str) -> str: return text