Add logging functions