Cleaned up code for LEADS demo