Addapt mapper to work document by document