Some cleanups + documentation