Hello
Thank you for your question and reaching out. I can understand you are having query\issues related to auto-clear temp folder
The folder INetcache used by IE and caches temporary Internet Explorer files.
The local\temp is also used for Windows to store temp files used by Windows services or programs.
You can configure some GPO or script to clean it up
Run Start > Internet Options -> Advanced tab -> Place a check-mark next to "Empty Temporary Internet Files folder when browser is closed" -> Click OK.
--If the reply is helpful, please Upvote and Accept as answer--