Implemented more tracing hooks and also added formatting for screen viewing