No-code labelling functions are labelling functions that provide a UI. They allow you to create and edit labelling functions without having to read Python code.
Vector similarity example: Label sentences similar to an example sentence
Dictionary lookup example
Programmatic comes with several no-code labelling function examples such as keyword matchers, dictionary lookups, and vector similarity. These can be used directly in-app, or customised for your own project.
Saving a no-code labelling function template
If you choose to modify a no-code labelling function, you can then save it as a template to easily create similar labelling functions in the future. Do so by clicking the three vertical dots at the top right of the function (see screenshots above), and choosing Save as template.
Components of a No-Code Labelling Function
You don't have to understand this to use the in-app examples! Read this section if you wish to understand how to modify and make your own no-code labelling functions.
No-code labelling functions are defined by two components:
User Interface (UI)
Python code template
The UI interface, defined in an XML format, specifies how the no-code view should look, what information is displayed, and what user input to accept.
The Python code template defines the labelling function that will be generated and run, using placeholders that will be replaced by user input through string interpolation.
For a list of UI elements Programmatic supports, check out the UI Reference page.