update docs; bug fixes