Refactor and document __init__.py and application.py

Signed-off-by: Rafael Bailón <rafaelbailon@ieee.org>