The old version of guidance doesn't allow deep copying the client object.
The newer version may support it through some changes.
However, the guidance doesn't take llm argument anymore.
the llm under guidance is now model.
This opensource code is what I was looking at.
https://github.com/psunlpgroup/GreaterPrompt/blob/main/src/greaterprompt/core/pe2/trainer/pe2_trainer.py
there are places that uses old guidance interface like
self.initializer = guidance(prompt, llm=self.llm) # guidance program for initialization