Skip to content
okay edited this page Oct 7, 2017 · 1 revision

Plugins & Extensibility

Snorkel supports configuration via the app/plugins directory. So far, there are three types of plugins:

To use a plugin, clone it into app/plugins and restart snorkel.

Snorkel Config

In order to make snorkel more deployable / configurable, its possible to store all your config in a separate git repo. You can clone that repo into app/plugins/snorkel-config and re-use configs across instances, etc.

Dataset Config

To enable (or disable) per dataset views, use the snorkel-dataset-config repo and plugins

Visualizations

To add new views, see how snorkel-plugins-demo does it. In order for a new view to work, it has to 1) be cloned into the app/plugins directory and 2) hooked up in the dataset config (also in app/plugins) as a custom view.

Views can specify their query type, supported inputs (and even have custom inputs) and have 3 main methods.

  • prepare - called when receiving the query results
  • finalize - called after all query results returned
  • render - called to render the data into a div

You can look in snorkel's view dir to see how other views are structured.