Utilities for Javascript plug

The data structure it returns is secondary. Tell me what the function's intent is. Any machine can check it against a data shape; docstrings are for humans.