Adding support for 'latest' shortcut
Minor cleanup based on shivaram's review