added partial implementation to choose level