modify document and create samples