updated morelikethis to accept a hash or record and then extract the index from that and use the extracted index to get the document type and id to build the path