Leap Laboratories Results API
The results API from Leap Laboratories — 1 operation(s) for results.
The results API from Leap Laboratories — 1 operation(s) for results.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/leap-labs-com:leap-labs-com-results-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Disco Results API
description: 'Disco finds novel, statistically validated patterns in tabular data that correlation analysis, LLMs, and hypothesis-driven approaches miss. Each pattern is validated on hold-out data with FDR-corrected p-values and checked against academic literature with citations.
## Agent workflow
**Step 1 — Get an API key** (once):
- `POST /api/signup` with `{"email": "..."}` → sends a 6-digit code
- `POST /api/signup/verify` with `{"email": "...", "code": "..."}` → returns `{"key": "disco_..."}`
- Use this key as `Authorization: Bearer disco_...` for all subsequent requests
**Step 2 — Estimate cost** (optional but recommended):
- `POST /api/estimate` with file size, column count, depth, visibility
- Returns credit cost and time estimate
**Step 3 — Upload data** (pick one):
- *From URL:* `POST /api/data/upload/from-url` with `{"url": "https://..."}` → returns `file` and `columns`
- *Direct (base64):* `POST /api/data/upload/direct` with `{"fileName": "data.csv", "content": ""}` → returns `file` and `columns`. Max 50MB.
- *Presign flow (for large files):* `POST /api/data/upload/presign` → PUT file to `uploadUrl` → `POST /api/data/upload/finalize`
**Step 4 — Run analysis:**
- `POST /api/run-analysis` with `file`, `columns`, and `targetColumn` from step 3 → returns `{"run_id": "..."}`
**Step 5 — Poll for results:**
- `GET /api/runs/{run_id}/results` — poll every 10s until `status` is `"completed"` (time varies with dataset size and depth)
- Response includes `patterns[]` with conditions, p-values, effect sizes, novelty scores, and citations
## Billing
Public runs are free. If the user needs more credits or a paid plan, send them to https://disco.leap-labs.com/account to upgrade.
## Authentication
`disco_` API keys via `Authorization: Bearer disco_...` header. Get a key via signup or at https://disco.leap-labs.com/developers.
## SDK
`pip install discovery-engine-api` — Full docs'
version: 1.0.0
servers:
- url: https://disco.leap-labs.com
tags:
- name: Results
paths:
/api/runs/{run_id}/results:
get:
tags:
- Results
summary: Get complete analysis results
description: Returns analysis results including patterns, p-values, novelty scores, and citations. Poll until status is "completed". If "failed", check error_message.
operationId: get_results
parameters:
- name: run_id
in: path
required: true
schema:
type: string
format: uuid
description: The ID of the run
title: Run Id
description: The ID of the run
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/ResultsResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
PatternCitation:
properties:
url:
anyOf:
- type: string
- type: 'null'
title: Url
description: Citation URL
title:
anyOf:
- type: string
- type: 'null'
title: Title
description: Paper/article title
doi:
anyOf:
- type: string
- type: 'null'
title: Doi
description: Digital object identifier
authors:
anyOf:
- items:
type: string
type: array
- type: 'null'
title: Authors
description: Author list
year:
anyOf:
- type: string
- type: 'null'
title: Year
description: Publication year
journal:
anyOf:
- type: string
- type: 'null'
title: Journal
description: Journal name
volume:
anyOf:
- type: string
- type: 'null'
title: Volume
issue:
anyOf:
- type: string
- type: 'null'
title: Issue
pages:
anyOf:
- type: string
- type: 'null'
title: Pages
type: object
required:
- url
- title
- doi
- authors
- year
- journal
title: PatternCitation
DashboardUrls:
properties:
summary:
$ref: '#/components/schemas/DashboardPageUrl'
description: AI-generated overview with key insights and novel findings
patterns:
$ref: '#/components/schemas/DashboardPageUrl'
description: Full list of discovered patterns with statistics, citations, and interactive visualizations
features:
$ref: '#/components/schemas/DashboardPageUrl'
description: Feature importance rankings, column statistics, and correlations
territory:
$ref: '#/components/schemas/DashboardPageUrl'
description: Interactive 3D map showing how patterns select different regions of the data
type: object
required:
- summary
- patterns
- features
- territory
title: DashboardUrls
FeatureImportanceScore:
properties:
feature:
type: string
title: Feature
description: Feature/column name
score:
type: number
title: Score
description: Importance score
type: object
required:
- feature
- score
title: FeatureImportanceScore
ColumnInfo-Output:
properties:
name:
type: string
title: Name
description: Column name
display_name:
type: string
title: Display Name
description: Display-friendly column name
type:
type: string
title: Type
description: '''continuous'' or ''categorical'''
data_type:
type: string
title: Data Type
description: Data type (float, int, string, etc.)
mean:
anyOf:
- type: number
- type: 'null'
title: Mean
median:
anyOf:
- type: number
- type: 'null'
title: Median
std:
anyOf:
- type: number
- type: 'null'
title: Std
min:
anyOf:
- type: number
- type: 'null'
title: Min
max:
anyOf:
- type: number
- type: 'null'
title: Max
mode:
anyOf:
- type: string
- type: 'null'
title: Mode
approx_unique:
anyOf:
- type: integer
- type: 'null'
title: Approx Unique
null_percentage:
anyOf:
- type: number
- type: 'null'
title: Null Percentage
type: object
required:
- name
- display_name
- type
- data_type
title: ColumnInfo
DashboardPageUrl:
properties:
url:
type: string
title: Url
description: Direct URL to this dashboard page
description:
type: string
title: Description
description: What the user will find on this page
type: object
required:
- url
- description
title: DashboardPageUrl
ResultsSummary:
properties:
overview:
anyOf:
- type: string
- type: 'null'
title: Overview
description: High-level summary of findings
key_insights:
items:
type: string
type: array
title: Key Insights
description: Key insights from the analysis
novel_patterns:
anyOf:
- {}
- type: 'null'
title: Novel Patterns
description: Novel pattern summary
selected_pattern_id:
anyOf:
- {}
- type: 'null'
title: Selected Pattern Id
type: object
title: ResultsSummary
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
type: object
required:
- loc
- msg
- type
title: ValidationError
CorrelationEntry:
properties:
feature_x:
type: string
title: Feature X
feature_y:
type: string
title: Feature Y
value:
type: number
title: Value
type: object
required:
- feature_x
- feature_y
- value
title: CorrelationEntry
PatternResult:
properties:
pattern_no:
type: integer
title: Pattern No
description: Pattern sequence number
description:
type: string
title: Description
description: Human-readable pattern description
target_column:
type: string
title: Target Column
description: Target column name
target_change_direction:
type: string
title: Target Change Direction
description: '''max'' or ''min'' — which extreme this pattern drives'
p_value:
anyOf:
- type: number
- type: 'null'
title: P Value
description: FDR-corrected p-value
p_value_raw:
anyOf:
- type: number
- type: 'null'
title: P Value Raw
description: Raw (uncorrected) p-value
abs_target_change:
anyOf:
- type: number
- type: 'null'
title: Abs Target Change
description: Absolute effect on target
support_count:
type: number
title: Support Count
description: Number of rows matching this pattern
support_percentage:
type: number
title: Support Percentage
description: Fraction of dataset matching this pattern
novelty_type:
type: string
title: Novelty Type
description: '''novel'' or ''confirmatory'''
novelty_explanation:
type: string
title: Novelty Explanation
description: Why this pattern is novel or known
conditions:
items:
$ref: '#/components/schemas/PatternCondition'
type: array
title: Conditions
description: Conditions defining this pattern
citations:
items:
$ref: '#/components/schemas/PatternCitation'
type: array
title: Citations
description: Academic citations
target_percentage:
anyOf:
- type: number
- type: 'null'
title: Target Percentage
target_class:
anyOf:
- type: string
- type: 'null'
title: Target Class
target_mean:
anyOf:
- type: number
- type: 'null'
title: Target Mean
target_std:
anyOf:
- type: number
- type: 'null'
title: Target Std
type: object
required:
- pattern_no
- description
- target_column
- target_change_direction
- p_value
- p_value_raw
- abs_target_change
- support_count
- support_percentage
- novelty_type
- novelty_explanation
- conditions
title: PatternResult
PatternCondition:
properties:
type:
type: string
title: Type
description: 'Condition type: ''continuous'' or ''categorical'''
feature:
type: string
title: Feature
description: Feature/column name
min_value:
anyOf:
- type: number
- type: 'null'
title: Min Value
description: Minimum value (continuous only)
max_value:
anyOf:
- type: number
- type: 'null'
title: Max Value
description: Maximum value (continuous only)
min_q:
anyOf:
- type: number
- type: 'null'
title: Min Q
description: Minimum quantile (continuous only)
max_q:
anyOf:
- type: number
- type: 'null'
title: Max Q
description: Maximum quantile (continuous only)
values:
anyOf:
- items:
type: string
type: array
- type: 'null'
title: Values
description: Category values (categorical only)
type: object
required:
- type
- feature
title: PatternCondition
ResultsResponse:
properties:
status:
type: string
title: Status
description: 'Run status: ''processing'', ''completed'', or ''failed'''
report_id:
anyOf:
- type: string
- type: 'null'
title: Report Id
description: Report UUID (null if not yet completed)
report_url:
anyOf:
- type: string
- type: 'null'
title: Report Url
description: Shareable URL to the interactive web report
dashboard_urls:
anyOf:
- $ref: '#/components/schemas/DashboardUrls'
- type: 'null'
description: Direct links to each dashboard page with descriptions of what's on each page
job_id:
anyOf:
- type: string
- type: 'null'
title: Job Id
description: Job UUID
job_status:
anyOf:
- type: string
- type: 'null'
title: Job Status
description: Job status
error_message:
anyOf:
- type: string
- type: 'null'
title: Error Message
description: Error message if status is 'failed'
task:
anyOf:
- type: string
- type: 'null'
title: Task
description: 'Task type: regression, binary_classification, multiclass_classification'
dataset_title:
anyOf:
- type: string
- type: 'null'
title: Dataset Title
description: Dataset title
target_column:
anyOf:
- type: string
- type: 'null'
title: Target Column
description: Target column name
total_rows:
anyOf:
- type: integer
- type: 'null'
title: Total Rows
description: Number of rows in the dataset
summary:
anyOf:
- $ref: '#/components/schemas/ResultsSummary'
- type: 'null'
description: LLM-generated analysis summary
patterns:
items:
$ref: '#/components/schemas/PatternResult'
type: array
title: Patterns
description: Discovered patterns
columns:
items:
$ref: '#/components/schemas/ColumnInfo-Output'
type: array
title: Columns
description: Column statistics
correlation_matrix:
items:
$ref: '#/components/schemas/CorrelationEntry'
type: array
title: Correlation Matrix
description: Feature correlations
feature_importance:
anyOf:
- $ref: '#/components/schemas/FeatureImportance'
- type: 'null'
description: Global feature importance
type: object
required:
- status
title: ResultsResponse
FeatureImportance:
properties:
kind:
type: string
title: Kind
description: '''global'' or ''local'''
baseline:
type: number
title: Baseline
description: Baseline score
scores:
items:
$ref: '#/components/schemas/FeatureImportanceScore'
type: array
title: Scores
description: Per-feature importance scores
type: object
required:
- kind
- baseline
- scores
title: FeatureImportance