8451 / labrea

A framework for declarative, functional dataset definitions.
MIT License
11 stars 0 forks source link

Add method to describe required Options for a dataset #5

Closed drewf-8451 closed 1 month ago

drewf-8451 commented 3 months ago

Currently, when someone is using a dataset for the first time, they might not know all the Options required in their config in order to call that dataset.
In order to help users, we should add a describe method where the user can see what options are required.

@dataset
def add(x: int = Option('X'), y: int = Option('Y'):
    return x + y

add.describe() = {'X', 'Y'}

The difficulty is that required options can change depending on other values in the options dictionary due to overloads. We would need to think through how to deal with overloads in this scenario.

austinwarner-8451 commented 2 months ago

This will be .explain on rewrite/monadic

austinwarner-8451 commented 1 month ago

Coming in Labrea 2.0