Active Learning
Collect production inference data to continuously improve your model through review and retraining.
About
Active Learning collects production data from your deployed models and surfaces it for review and retraining. When your model runs inference in production, Active Learning automatically samples images based on rules you configure (such as low-confidence predictions or specific classes) and queues them for human review.
Web App
Enable Active Learning
Open your Project and select "Active Learning" in the left sidebar.
Toggle Active Learning on.
Your Project must have a trained model and an active cloud deployment for Active Learning to collect data.
Configure Collection Rules
Active Learning has two categories of configuration: collection limits and conditions.
Collection Limits
Control how much data Active Learning collects:
Sampling rate: the percentage of inferences to sample (ex: 0.5%)
Per-minute, hourly, and daily image caps
Compression level and maximum image dimensions
Batch recreation frequency (daily, weekly, monthly, or never)
Whether to persist model predictions with collected images
To edit these settings, click "Edit" in the Collection Limits section and update the values in the configuration modal.
Conditions
Conditions filter which images get collected. You can define rules based on your model type:
Confidence thresholds (ex: collect images where confidence falls below 60%)
Specific classes of interest
Detection count requirements
To set up conditions, click "Edit" in the Conditions section.
Manage Active Learning From the Agent
You can also manage Active Learning in Roboflow Agent. Open a project tab, select "Settings", and use the same toggle, Collection Limits, and Conditions as this page. This needs the Manage Workflows, Publish Workflows, and Dataset Active Learning permissions.
Review Collected Images
As Active Learning collects images, they appear in the Images section of the Active Learning page. The page shows counts of images ready for review and images currently being reviewed.
To start reviewing:
Click "Review Images" to open the review queue.
Browse batches by status (Not Started, In Progress) and sort by creation date, image count, or progress.
Select a batch to begin reviewing.
Assign Reviewers
You can distribute review work across your team:
Open the review queue and select a batch.
Click to assign reviewers.
Choose team members, set the number of images to assign, and optionally add review instructions.
Toggle "Shuffle Images" to randomize which images each reviewer receives.
Reviewers are notified when images are assigned to them. You can reassign images to a different reviewer at any time.
How Active Learning Fits Your Training Loop
The typical workflow:
Train and deploy a model.
Enable Active Learning with conditions tuned to your use case.
Production data that matches your conditions is collected and queued.
Reviewers label the collected images.
Add the reviewed images to your dataset and retrain to improve your model.
This creates a feedback loop where your model improves on the cases where it struggles most.
HTTP API
Use the HTTP API to turn Active Learning on or off, update collection rules, and list images in the review queue. Active Learning runs inside the Project's base Workflow, so each change saves and deploys a new version of that Workflow.
Get Active Learning Configuration
Returns the project's base Workflow, its model, and its Active Learning settings. Requires project:read and the Active Learning permission in the workspace.
Roboflow API key or OAuth access token.
Workspace URL slug.
Project URL slug.
Successful response.
The request is invalid.
Authentication is missing or invalid.
You do not have the Active Learning permission in this workspace.
The resource does not exist or is not accessible.
The request rate is too high.
GET /{workspace}/{project}/deploy/active-learning HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"project": {
"id": "abc123",
"url": "my-project",
"name": "My Project",
"owner": "my-workspace-id",
"type": "object-detection",
"classes": [
"cat",
"dog"
],
"multilabel": false
},
"workflow": {
"id": "wf_xyz",
"name": "My Project Base Workflow",
"url": "my-project-base-workflow",
"workspaceUrl": "my-workspace",
"inferencePath": "/infer/workflows/my-workspace/my-project-base-workflow"
},
"model": {
"id": "rfdetr-medium",
"kind": "pretrained",
"displayName": "RF-DETR Medium",
"modelId": "rfdetr-medium"
},
"deployability": {
"status": "deployable",
"modelWasConfigured": false,
"selectedModelId": null,
"selectionReason": null
},
"activeLearning": {
"enabled": false,
"collectionLimits": {
"dataPercentage": 100,
"minutelyUsageLimit": 10,
"hourlyUsageLimit": 100,
"dailyUsageLimit": 1000,
"labelingBatchesRecreationFrequency": "daily",
"usageQuotaName": "upload_quota_active_learning",
"imageCompressionLevel": 95,
"maxImageHeight": 1080,
"maxImageWidth": 1920,
"persistPredictions": true
},
"filters": []
}
}Enable Active Learning
If the Project has no model set, the service picks one first.
Turns on image collection in the project's base Workflow. If no model is set, picks one first. Calling it again changes nothing. Requires project:update.
Roboflow API key or OAuth access token.
Workspace URL slug.
Project URL slug.
Successful response.
The base Workflow is not deployable, or no model could be set.
Authentication is missing or invalid.
You do not have the Active Learning permission in this workspace.
The resource does not exist or is not accessible.
The request rate is too high.
POST /{workspace}/{project}/deploy/active-learning/enable HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"project": {
"id": "abc123",
"url": "my-project",
"name": "My Project",
"owner": "my-workspace-id",
"type": "object-detection",
"classes": [
"cat",
"dog"
],
"multilabel": false
},
"workflow": {
"id": "wf_xyz",
"name": "My Project Base Workflow",
"url": "my-project-base-workflow",
"workspaceUrl": "my-workspace",
"inferencePath": "/infer/workflows/my-workspace/my-project-base-workflow"
},
"model": {
"id": "rfdetr-medium",
"kind": "pretrained",
"displayName": "RF-DETR Medium",
"modelId": "rfdetr-medium"
},
"deployability": {
"status": "deployable",
"modelWasConfigured": false,
"selectedModelId": null,
"selectionReason": null
},
"activeLearning": {
"enabled": false,
"collectionLimits": {
"dataPercentage": 100,
"minutelyUsageLimit": 10,
"hourlyUsageLimit": 100,
"dailyUsageLimit": 1000,
"labelingBatchesRecreationFrequency": "daily",
"usageQuotaName": "upload_quota_active_learning",
"imageCompressionLevel": 95,
"maxImageHeight": 1080,
"maxImageWidth": 1920,
"persistPredictions": true
},
"filters": []
}
}Disable Active Learning
Turns off image collection. Your collection limits and filters are kept. Requires project:update.
Roboflow API key or OAuth access token.
Workspace URL slug.
Project URL slug.
Successful response.
The request is invalid.
Authentication is missing or invalid.
You do not have the Active Learning permission in this workspace.
The resource does not exist or is not accessible.
The request rate is too high.
POST /{workspace}/{project}/deploy/active-learning/disable HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"project": {
"id": "abc123",
"url": "my-project",
"name": "My Project",
"owner": "my-workspace-id",
"type": "object-detection",
"classes": [
"cat",
"dog"
],
"multilabel": false
},
"workflow": {
"id": "wf_xyz",
"name": "My Project Base Workflow",
"url": "my-project-base-workflow",
"workspaceUrl": "my-workspace",
"inferencePath": "/infer/workflows/my-workspace/my-project-base-workflow"
},
"model": {
"id": "rfdetr-medium",
"kind": "pretrained",
"displayName": "RF-DETR Medium",
"modelId": "rfdetr-medium"
},
"deployability": {
"status": "deployable",
"modelWasConfigured": false,
"selectedModelId": null,
"selectionReason": null
},
"activeLearning": {
"enabled": false,
"collectionLimits": {
"dataPercentage": 100,
"minutelyUsageLimit": 10,
"hourlyUsageLimit": 100,
"dailyUsageLimit": 1000,
"labelingBatchesRecreationFrequency": "daily",
"usageQuotaName": "upload_quota_active_learning",
"imageCompressionLevel": 95,
"maxImageHeight": 1080,
"maxImageWidth": 1920,
"persistPredictions": true
},
"filters": []
}
}Update Active Learning Configuration
Enable Active Learning before you configure it on a new Project. Send the full collectionLimits object each time: optional fields you leave out are removed.
Saves collection limits and, when you send them, filters. Enable Active Learning on the project first: the call fails when collection was never turned on. It does not turn collection on or off. Requires project:update.
Roboflow API key or OAuth access token.
Workspace URL slug.
Project URL slug.
Successful response.
collectionLimits or filters are invalid (the body has error and details), or a detectionSize filter was sent for a project that is not object detection or instance segmentation.
Authentication is missing or invalid.
You do not have the Active Learning permission in this workspace.
The resource does not exist or is not accessible.
The request rate is too high.
POST /{workspace}/{project}/deploy/active-learning/configuration HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 472
{
"collectionLimits": {
"dataPercentage": 50,
"minutelyUsageLimit": 10,
"hourlyUsageLimit": 100,
"dailyUsageLimit": 1000,
"labelingBatchesRecreationFrequency": "daily",
"usageQuotaName": "default",
"imageCompressionLevel": 85,
"imageName": "camera-1",
"maxImageHeight": 1080,
"maxImageWidth": 1920,
"registrationTags": [
"production"
],
"persistPredictions": true
},
"filters": [
{
"type": "classConfidence",
"classFilterMode": "any",
"classes": [
"cat"
],
"confidenceLowerBound": 0.2,
"confidenceUpperBound": 0.8
}
]
}{
"project": {
"id": "abc123",
"url": "my-project",
"name": "My Project",
"owner": "my-workspace-id",
"type": "object-detection",
"classes": [
"cat",
"dog"
],
"multilabel": false
},
"workflow": {
"id": "wf_xyz",
"name": "My Project Base Workflow",
"url": "my-project-base-workflow",
"workspaceUrl": "my-workspace",
"inferencePath": "/infer/workflows/my-workspace/my-project-base-workflow"
},
"model": {
"id": "rfdetr-medium",
"kind": "pretrained",
"displayName": "RF-DETR Medium",
"modelId": "rfdetr-medium"
},
"deployability": {
"status": "deployable",
"modelWasConfigured": false,
"selectedModelId": null,
"selectionReason": null
},
"activeLearning": {
"enabled": false,
"collectionLimits": {
"dataPercentage": 100,
"minutelyUsageLimit": 10,
"hourlyUsageLimit": 100,
"dailyUsageLimit": 1000,
"labelingBatchesRecreationFrequency": "daily",
"usageQuotaName": "upload_quota_active_learning",
"imageCompressionLevel": 95,
"maxImageHeight": 1080,
"maxImageWidth": 1920,
"persistPredictions": true
},
"filters": []
}
}List Active Learning Images
Lists the review queue: batches of collected images and the annotation jobs made from them, with totals. Requires project:read.
Roboflow API key or OAuth access token.
Workspace URL slug.
Project URL slug.
Page number, from 1.
1Items per page.
10Text matched against queue names, types, IDs, reviewers, and labelers.
Reviewer email, or unassigned for items with no reviewer.
not_started for batches, in_progress for annotation jobs.
allPossible values: createdPossible values: descPossible values: Successful response.
The request is invalid.
Authentication is missing or invalid.
You do not have the Active Learning permission in this workspace.
The resource does not exist or is not accessible.
The request rate is too high.
GET /{workspace}/{project}/deploy/active-learning/images HTTP/1.1
Host: api.roboflow.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"activeLearningImages": {
"totalImagesReadyForReview": 0,
"totalImagesBeingReviewed": 0,
"batches": [],
"annotationJobs": [],
"latestBatch": null,
"latestAnnotationJob": null,
"sampleImages": [],
"reviewQueueCounts": {
"all": 0,
"notStarted": 0,
"inProgress": 0
},
"reviewQueuePage": {
"page": 1,
"pageSize": 20,
"totalItems": 0,
"totalPages": 1,
"items": [],
"search": "",
"status": "all",
"sortBy": "created",
"sortDirection": "desc",
"reviewer": ""
}
}
}Python SDK
Workspace.active_learning() runs inference on every image in a directory and conditionally uploads the image (and its prediction) to a destination project. It's the SDK's built-in active-learning loop: bootstrap a labeling queue from raw footage by letting your existing model triage what's worth labeling.
The same pattern is best built as a Workflow for production use, but active_learning() is the fastest path from "I have a folder of frames" to "labelled data going into a project".
Basic usage
Parameters
raw_data_location(str) - directory of input images.raw_data_extension(str) - image extension to match (e.g..jpg,.png).inference_endpoint(list,[project, version]) - the model to run as the triage step.upload_destination(str) - project id to upload qualifying images and predictions into. Often the same project as the model.conditionals(dict) - rules that determine whether an image gets uploaded. Common keys:confidence_interval-[min, max]; only images whose detections fall in this range are forwarded.required_class_variance_count- minimum distinct classes required.minimum_size_requirement/maximum_size_requirement- filter by detection area in pixels.required_class_count- total detections.
use_localhost(bool, defaultFalse) - whenTrue, hit a self-hosted Roboflow Inference server instead of hosted inference.local_server(str) - base URL for the local inference server. Defaults tohttp://localhost:9001/.
Why use it
The typical loop:
Train a v1 model on a small labeled set.
Point
active_learning()at a folder of unlabeled production data.Forward only the images where the model is uncertain (low confidence) or sees rare classes.
Label those in the Roboflow web app.
Generate v2 with the new examples and retrain.
Tuning conditionals is what turns this from "upload everything" into a real triage policy.
Bigger pipelines
If your input is a video stream, your model lives behind a Workflow, or you want batching and retries, build the equivalent as a Workflow. active_learning() is best for one-off bootstrapping passes from a static folder.
MCP Server
Connect your AI agent to the MCP Server and it can set up Active Learning with these tools:
project_deployment_enable_active_learning
Enable Active Learning for a Project Deployment.
project_deployment_configure_active_learning
Configure how a deployment collects Active Learning data.
project_deployment_disable_active_learning
Pause Active Learning collection.
project_deployment_list_review_queues
List review queues fed by production inference.
Last updated
Was this helpful?