Documentation and some stability fixes