refactor into new interface
release 0.5.0