I've been using taskwarrior for several months now and like it. Today I duckduckgo'd across Ralph Bean's taskw, which made it easy to scratch an itch I've been feeling for a while: scripting more complex taskwarrior usage.
Bean's README in the taskw repository is straightforward, so I won't rehash it here. I used pip to install taskw from PyPi in a fresh Python 3.7.2 virtual environment and I was off to the races. In less than an hour I had a start on my own python package for managing projects with more metadata and flexibility than one gets out of the box with taskwarrior. The agenda is a bit cryptic for now (since it's shifting inside my brain), but fwiw: https://github.com/paregorios/taskwarrior.epics