Obtaining access
To access the Isaacus API, you must:- have an active, email-verified account on the Isaacus Platform, which you can create here;
- be subscribed to our usage-based (no-flat-fee) API plan, which you can do here (if you’ve unsubscribed from that plan, you can use that same link to resubscribe);
- not have any overdue invoices, which you can pay here; and
- have an active API key, which you can generate here.
Accessing the API
The Isaacus API is a RESTful API that can be accessed using any tool or programming language that supports HTTP requests. To make interfacing with the Isaacus API easier than using raw HTTP requests, we also offer and recommend using our Python and server-side JavaScript/TypeScript packages, which can be installed withpip and npm, respectively.
https://api.isaacus.com/v1. You don’t need to manually set this URL as your base URL when using our SDKs.
Authentication
If you are using one of our SDKs, you can authenticate with the Isaacus API by either setting theISAACUS_API_KEY environment variable or by passing your API key directly to your client constructor.
Authorization header in the format Bearer PASTE_YOUR_API_KEY_HERE.
Endpoints
The Isaacus API currently offers the following endpoints:POST /embeddings- Embed legal queries and documents with an Isaacus legal AI embedder.POST /rerankings- Rerank legal documents by their relevance to a query with an Isaacus legal AI reranker.POST /extractions/qa- Extract answers to questions from legal documents with an Isaacus legal AI answer extractor.POST /classifications/universal- Classify the relevance of a legal document to a query with an Isaacus universal legal AI classifier.
POST requests using the create() method and GET requests using the get() method. For example, to call POST /embeddings, you would use the method client.embeddings.create().
Requests and responses
Our SDKs accept request parameters in the form of function arguments and they return responses in the form of objects, as shown below.Content-Type header is set to application/json. The response will also be formatted as JSON.
Amazon SageMaker
All private deployments of Isaacus models on Amazon SageMaker offer feature parity with the Isaacus API. The only difference is that, due to SageMaker constraints, requests must be proxied through the/invocations endpoint. Also, since SageMaker deployments are private to your AWS account, Isaacus API keys are not required when making requests to them (if passed, they will simply be ignored).
For example, if you wanted to send a POST request to /v1/embeddings with the data {"model": "kanon-2-embedder", "texts": ["This is a confidentiality clause."], "task": "retrieval/query"}, you could do so by sending /invocations the payload {"path": "/v1/embeddings","data": {"model": "kanon-2-embedder", "texts": ["This is a confidentiality clause."], "task": "retrieval/query"}}.
Assuming the model being invoked supports the endpoint being used, you should receive the exact same response the online Isaacus API would have returned (allowing for slight numerical differences due to different hardware being used).
When an error occurs, SageMaker will wrap the original Isaacus API error message with its own message. To find the original error message and status code, check the OriginalMessage and OriginalStatusCode keys.
We recommend using the Isaacus SageMaker Python integration package to automatically proxy requests for you instead of handling this manually. We explain how to get started with that package in our SageMaker integration guide.
The complete schema for the Isaacus SageMaker /invocations endpoint is as follows: