describe in function docstring what this magic supposed to do, with examples