Skip to content

Commit

Permalink
- Fix wsgi.py
Browse files Browse the repository at this point in the history
- Remove stuff from contrib/__init__.py to reduce import errors
  • Loading branch information
jcklie committed Dec 7, 2021
1 parent 67c736b commit a8b546b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 12 deletions.
7 changes: 0 additions & 7 deletions ariadne/contrib/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +0,0 @@
from ariadne.contrib.adapters import AdapterSequenceTagger
from ariadne.contrib.jieba import JiebaSegmenter
from ariadne.contrib.nltk import NltkStemmer
from ariadne.contrib.sbert import SbertSentenceClassifier
from ariadne.contrib.sklearn import SklearnSentenceClassifier, SklearnMentionDetector
from ariadne.contrib.spacy import SpacyNerClassifier, SpacyPosClassifier
from ariadne.contrib.stringmatcher import LevenshteinStringMatcher
8 changes: 3 additions & 5 deletions wsgi.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
from ariadne.contrib import *
from ariadne.contrib.adapters import AdapterSentenceClassifier
from ariadne.contrib.simalign import SimAligner
from ariadne.server import Server
from ariadne.util import setup_logging
from ariadne.contrib.spacy import SpacyNerClassifier

setup_logging()

server = Server()
server.add_classifier("align", SimAligner())
# server.add_classifier("spacy_ner", SpacyNerClassifier("en_core_web_sm"))

server.add_classifier("spacy_ner", SpacyNerClassifier("en_core_web_sm"))
# server.add_classifier("spacy_pos", SpacyPosClassifier("en_core_web_sm"))
# server.add_classifier("sklearn_sentence", SklearnSentenceClassifier())
# server.add_classifier("jieba", JiebaSegmenter())
Expand Down

0 comments on commit a8b546b

Please sign in to comment.