ladybug: added comments and debugging info