Set up documents first.