Tangent Docker
Description
Tangent Docker is a lightweight version of Tangent that allows the user to access Tangent as a single docker container. The docker image can be pulled straight from the Tangent Works container registry and only requires a license token to access. The license token can be obtained by contacting a Tangent Works representative.
The docker container contains a simple API aligned with the Tangent API allowing you to easily access the core functionalities.
Installation
Tangent Works Container Registry access:
Obtain a service principal username & password from a Tangent Works representative.
docker login tangentworks.azurecr.io --username <username> --password <password>
Pull tangent-docker-image
To pull the latest version of Tangent Docker from the container registry, run the following command:
docker pull tangentworks.azurecr.io/tangent-docker-image:latest
In order to pull a specific version make sure to modify the tag from “latest” to “v.X.Y.Z”.
For example:
docker pull tangentworks.azurecr.io/tangent-docker-image:v1.0.0
Run tangent-docker
To run the latest version of Tangent Docker, run the following command:
docker run -d -p 8000:8000 --name tangent-docker tangentworks.azurecr.io/tangent-docker-image:latest
In order to run a specific version make sure to modify the tag from “latest” to “v.X.Y.Z”.
For example:
docker run -d -p 8000:8000 --name tangent-docker tangentworks.azurecr.io/tangent-docker-image:v1.0.0
Complete installation
Wait for the container to start. The container is ready when 2 messages are displayed in the logs:API is ready to receive requests on port 8000Worker is ready to process jobs
Now Tangent Docker is ready to process requests.
Using Tangent Docker
1) Overview
The Tangent Docker API exposes endpoints for:
Auto Forecast (async job-style forecasting)
Forecasting (build model, predict, root-cause analysis)
Anomaly Detection (build model, detect anomalies, root-cause analysis)
Most endpoints accept:
a CSV dataset (uploaded as a file), and
a JSON configuration (uploaded as a file),
and some also accept:a JSON model (uploaded as a file).
2) Base URL
The API within the docker container will be available on port 8000. Use this base server URL:
http://localhost:8000
Swagger UI (interactive endpoint reference):
http://localhost:8000/swagger-ui.html
Tip: Swagger UI is the source of truth for exact schemas, required fields, and response formats.
3) Authentication
The API is secured using Bearer token authentication. Send this header on every request:
Authorization: Bearer <TOKEN>
4) Request format
4.1 Multipart form uploads (most POST endpoints)
POST endpoints use multipart/form-data with file parts:
dataset: CSV file content (Content-Type:text/csv)configuration: JSON content (Content-Type:application/json)model: JSON content (Content-Type:application/json) — only for predict/detect/rca flows that require a model
4.2 Result downloads
Some “results” endpoints return CSV in the response body.
5) Endpoint map (high-level)
Auto Forecast
POST /auto-forecast→ submit jobGET /auto-forecast/{id}→ statusGET /auto-forecast/{id}/results→ results CSVGET /auto-forecast/{id}/model→ model JSONDELETE /auto-forecast/{id}→ delete job
Forecasting
POST /forecast/build-modelPOST /forecast/predictPOST /forecast/rcaGET /forecast/{id}→ statusGET /forecast/{id}/results→ results CSVGET /forecast/{id}/model→ model JSONGET /forecast/{id}/rca-table→ RCA table JSONDELETE /forecast/{id}→ delete job
Anomaly Detection
POST /anomaly-detection/build-modelPOST /anomaly-detection/detectPOST /anomaly-detection/rcaGET /anomaly-detection/{id}→ statusGET /anomaly-detection/{id}/results→ results CSVGET /anomaly-detection/{id}/model→ model JSONGET /anomaly-detection/{id}/rca-table→ RCA table JSONDELETE /anomaly-detection/{id}→ delete job
Whether a call returns an immediate result or a job
idto poll depends on the specific endpoint and configuration; confirm in Swagger UI.
6) Quickstart workflows
6.1 Auto Forecast (job-based)
Submit the job
Poll status until complete
Download results CSV (and optionally the model JSON)
Delete the job when finished (optional)
7) Where to find exact schemas
Use Swagger UI to confirm:
required fields in
configurationdataset column requirements
response schema and the exact key name that contains a job
idstatus field names and terminal states
Swagger: http://localhost:8000/swagger-ui.html