added features and implementation