extract docs to their own files