add declarative scripting, add code comments