Initial commit for TopHits support

"Working" end to end but still needs tests added and the deserialising
logic updated a bit.