Nice Dict/JSON output.

Code cleaning.