Optimal contracts for research agents. (7th February 2017)