A *quasi-static process* is often defined as a process "that occurs infinitely slowly such that equilibrium holds at all times."(Harvard, Matthew Schwartz, statistical mechanics Spring 2019). My question is a simple but possibly subtle one which I haven't seen mentioned anywhere.

Simply put, does the system need to maintain equilibrium *with the surroundings* at all times during the process in order for the process to be classified as a quasi-static process or is the lesser requirement of simply having the system maintain internal equilibrium with itself good enough to classify the process as quasi-static?

As an example, suppose we have a fixed volume system immersed in a heat bath (the surroundings). The system is at temperature $T\_{sys}$ while the heat bath is at fixed $T\_{bath}$ with $T\_{sys}<<T\_{bath}$. The walls/boundary of the system are virtually adiabatic but not totally (i.e they posses a very low thermal conductivity) and so heat can and will seep into the system across a large temperature gradient but this will happen very slowly (perhaps even infinitely slowly). After a very long time, the systems temperature will equal the heat baths temperature. Does this count as a quasi-static process? Throughout the process, the system had a well-defined internal equilibrium however it was never in equilibrium with the surroundings and so I am not sure whether it counts as quasi-static or not.

Any help on this issue would be most appreciated!