write a code that contains convergence test workflow for different cases
I think it will be useful if Atomate includes the sets of convergence test workflows. Each workflow will perform different types of convergence tests, which include the general k-points and cutoff energy convergence test and the size test for slab and vacuum, and defects in different systems (slab and bulk).
As far as I know, atomate already does simple energy workflows. Surely those can be strung together without having to write code to create convergence tests?
What I am thinking is combining the existed simple energy workflows with the pre-step of structure generation (slab/vacuum or doped bulk/slab with different sizes) and post step analyzing the energy and returning the optimal parameter (k-point, cutoff energy, slab/vacuum size, doped bulk size) all in the workflow.
As @shyuep says, currently you can build your own convergence tests using the workflows in atomate but it does require a little bit of coding and thought. I could see there being a feature to make this easier and also automatically return the optimal parameters as @Tinaatucsd says but I'm not sure anyone will be working on this anytime soon. Convergence testing is just not something that we do a ton of ourselves right now.
Another option is to use custodian for convergence testing since that API is a bit easier to use.