Skip to main content

Python SDK for Cradl

Project description

Python SDK for Cradl

Github Actions build status

Installation

$ pip install cradl

Usage

Sign up for free here and download API credentials to use this SDK. Read more about authenticating to the API here

Quick start

import json
from cradl import Client

client = Client()
models = client.list_models()['models'] # List all models available
model_id = models[0]['modelId'] # Get ID of first model in list
document = client.create_document('path/to/document.pdf')
prediction = client.create_prediction(document['documentId'], model_id=model_id)
print(json.dumps(prediction, indent=2))

Contributing

Prerequisites

$ pip install -r requirements.txt
$ pip install -r requirements.ci.txt

Run tests

$ make prism-start
$ python -m pytest

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cradl-0.4.6.tar.gz (34.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cradl-0.4.6-py3-none-any.whl (26.1 kB view details)

Uploaded Python 3

File details

Details for the file cradl-0.4.6.tar.gz.

File metadata

  • Download URL: cradl-0.4.6.tar.gz
  • Upload date:
  • Size: 34.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.8

File hashes

Hashes for cradl-0.4.6.tar.gz
Algorithm Hash digest
SHA256 ef43a5d6ae569a59a66239fef0746d4dbbf28c375445a5e7a5a47ac7fd51520b
MD5 8b67f04aa58c1e9d0b64f5ab76ad1b9c
BLAKE2b-256 ff61355021462ff0823ce95f6292cebaf85bc2417c4948b40bf41ed00e867dd8

See more details on using hashes here.

File details

Details for the file cradl-0.4.6-py3-none-any.whl.

File metadata

  • Download URL: cradl-0.4.6-py3-none-any.whl
  • Upload date:
  • Size: 26.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.8

File hashes

Hashes for cradl-0.4.6-py3-none-any.whl
Algorithm Hash digest
SHA256 37e1bcd0ccc3e0dc022952fe9ec3c79a26705625257ba4f792a2d7ebbd11aa36
MD5 4983880baa8925c9a4c2eaa479ba5a43
BLAKE2b-256 d0fe78e054f57c29042170f60b7d4ec740657ac172259f7731f3938bbded8da8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page