Use of AI tools like ChatGPT within your assignments needs to be cited, just as you would cite any other information that is not your own. This article explains how to use and cite AI ethically and responsibly.
Not citing the use of AI may be considered plagiarism.
This article from Chicago Manual of Style (17th ed.) describes how to cite the use of generative AI in your research papers.