Custom Interfaces with blocks
Summary
Prodigy's "blocks" feature enables the creation of custom annotation interfaces by combining existing UI components within a single recipe. This capability addresses the need to merge distinct annotation tasks, such as audio segmentation and text transcription, which are typically handled by separate Prodigy recipes like `audio_manual` and `audio_transcribed`. A custom recipe demonstrates how to define a list of dictionaries, each specifying a `view_id` for a pre-existing component (e.g., `audio_manual`, `text_input`), and then pass this configuration to the main recipe. The overall recipe's `view_id` must be set to "blocks" to render these combined components, allowing for a unified interface that captures multiple types of annotations, like speaker segments and corresponding text transcripts, in a single output JSON.
Key takeaway
For data scientists building custom annotation workflows, Prodigy's "blocks" feature offers a flexible way to combine disparate annotation tasks like audio segmentation and transcription into a single interface. This avoids switching between recipes, streamlining your labeling process and ensuring all relevant data is captured efficiently within one task. Explore the "view_id" and "blocks" configuration to tailor interfaces precisely to your project's needs.
Key insights
Prodigy's "blocks" feature allows combining existing UI components to build custom, multi-task annotation interfaces.
Principles
- Prodigy's "blocks" feature constructs interfaces from pre-existing components.
- Each component is defined by a "view_id" in a list of dictionaries.
- Custom recipes must set the main "view_id" to "blocks" and pass the block definitions.
Method
To create a custom interface, define a list of dictionaries, each with a "view_id" referencing a Prodigy component (e.g., "audio_manual", "text_input"), and pass this list as "blocks" in the recipe's config, setting the main "view_id" to "blocks".
In practice
- Combine "audio_manual" for segmentation with "text_input" for transcription.
- Add an "id" to text components to name the output field in annotations.
Topics
- Prodigy
- Custom Annotation Interfaces
- Audio Annotation
- Data Labeling
- Blocks Feature
- Recipe Development
Best for: AI Engineer, Machine Learning Engineer, Data Scientist
Related on AIssential
Editorial summary, takeaway, and curation by AIssential. Original article published by Explosion · Developer tools and consulting for AI, Machine Learning and NLP - Explosion.ai.