Software sifts through millions of medical records to match patients with similar diagnoses and characteristics and then predicts what kind of care an individual will need and for how long. New federal rules will ensure human experts are part of the process.