diff --git a/freenlpc/__init__.py b/freenlpc/__init__.py index 10dd947..bff930b 100644 --- a/freenlpc/__init__.py +++ b/freenlpc/__init__.py @@ -1 +1,2 @@ -from freenlpc.freenlpc import FreeNlpc +from . import nlpcloudd as nlpcloud +from freenlpc.freenlpc import FreeNlpc \ No newline at end of file diff --git a/freenlpc/freenlpc.py b/freenlpc/freenlpc.py index 976eee6..6f78c92 100644 --- a/freenlpc/freenlpc.py +++ b/freenlpc/freenlpc.py @@ -1,5 +1,5 @@ from operator import itemgetter -from . import nlpcloudd as nlpcloud +import nlpcloudd as nlpcloud import requests from time import sleep diff --git a/freenlpc/nlpcloudd.py b/freenlpc/nlpcloudd.py index 2b7ef34..7c912aa 100644 --- a/freenlpc/nlpcloudd.py +++ b/freenlpc/nlpcloudd.py @@ -9,7 +9,7 @@ class Client: def __init__(self, model, token, gpu=False, lang=""): self.headers = { "Authorization": "Token " + token, - "User-Agent": "nlpcloud-python-client" + "User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4298.0 Safari/537.36" } if lang == "en": lang = "" diff --git a/setup.py b/setup.py index c4f3d14..5e3b4a1 100644 --- a/setup.py +++ b/setup.py @@ -1,6 +1,6 @@ from setuptools import setup, find_packages -VERSION = '0.2.1' +VERSION = '0.2.2' DESCRIPTION = 'A wrapper for nlpcloud free-tier services with no requests per minute limits.' LONG_DESCRIPTION = """# freenlpc a wrapper for nlpcloud free-tier.