No project description provided
Project description
Checkfor.ai Python
Installation
pip install checkforai
Add your API key
Either export it as a variable.
export CHECKFORAI_API_KEY=<your API key>
Or pass it in to the constructor:
my_api_key = '' # Fill this in with your API key.
classifier = TextClassifier(api_key=my_api_key)
Make a request
from checkforai import TextClassifier
classifier = TextClassifier()
result = classifier.predict(text)
# Score in range [0, 1] where 0 is human-written and 1 is AI-generated.
score = result['ai_likelihood']
Make a batch request
from checkforai import TextClassifier
text_batch = ["abc", "def"]
classifier = TextClassifier()
results = classifier.batch_predict(text_batch)
for result in results:
text = result['text']
score = result['ai_likelihood']
Questions? Email me at max@checkfor.ai!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
checkforai-0.2.0.tar.gz
(2.6 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file checkforai-0.2.0.tar.gz.
File metadata
- Download URL: checkforai-0.2.0.tar.gz
- Upload date:
- Size: 2.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
371e5ad96026b72fd43c1922d6f016171ee5c2e1f798b19e3513c12efdebcf42
|
|
| MD5 |
1e6b8b2f210bf616b50b0da2ac6170ef
|
|
| BLAKE2b-256 |
fbcf3d13f4c34c6ebf07a86405b2daf237590888f272fa33f41d4d98ae8caa6d
|
File details
Details for the file checkforai-0.2.0-py3-none-any.whl.
File metadata
- Download URL: checkforai-0.2.0-py3-none-any.whl
- Upload date:
- Size: 3.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
349d3b3cf82b33e579c78e202518f4021afbc700adbd91de20225d5da30a6467
|
|
| MD5 |
ffeac1298ed287c1c920728a8128e284
|
|
| BLAKE2b-256 |
af293a2420de540f9eced395c9787152a35869741ccb97f3f8d581676289da08
|