Auditing in jupyterhub

I ready this community post discussion but there doesn’t seem to be any solution to audit python commands. Kernel level logging seems like an option but doing that will require a really good understanding of its code base. Can you be bit more specific about what can be done.