Added resource computation context and completed monad instance of it