Updated the doc examples with an explicit type annotation so they actually work