added configuration
added comments
changed scope variables
added option to pass schema as scope object