better docs, some api improvements