Skip to content

Commit f40e52b

Browse files
author
Julien Salinas
committed
Decomission the lib versions api endpoint.
1 parent 78f0909 commit f40e52b

File tree

2 files changed

+0
-24
lines changed

2 files changed

+0
-24
lines changed

README.md

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -287,16 +287,6 @@ client.langdetection("<The text you want to analyze>")
287287

288288
The above command returns a JSON object.
289289

290-
### Library Versions Endpoint
291-
292-
Call the `lib_versions()` method to know the versions of the libraries used behind the hood with the model (for example the PyTorch, TensorFlow, or spaCy version used).
293-
294-
```python
295-
client.lib_versions()
296-
```
297-
298-
The above command returns a JSON object.
299-
300290
### Paraphrasing Endpoint
301291

302292
Call the `paraphrasing()` method and pass the text you want to paraphrase.

nlpcloud/__init__.py

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -303,20 +303,6 @@ def langdetection(self, text):
303303

304304
return r.json()
305305

306-
def lib_versions(self):
307-
r = requests.get(
308-
"{}/{}".format(self.root_url, "versions"), headers=self.headers)
309-
310-
try:
311-
r.raise_for_status()
312-
except HTTPError as err:
313-
if "<!DOCTYPE html>" in r.text:
314-
raise HTTPError(str(err))
315-
316-
raise HTTPError(str(err) + ": " + str(r.text))
317-
318-
return r.json()
319-
320306
def paraphrasing(self, text):
321307
payload = {
322308
"text": text

0 commit comments

Comments
 (0)