Updated readme and added diagram.