Modified access to files in resource, added Grab AST, done some refactoring