This repository contains Python scripts for efficient bulk deletion of OpenAI assistants and files. It's a handy tool for OpenAI resource management and cleanup.
-
delete_assistants.py
: This script deletes OpenAI assistants. It fetches a list of all assistants, displays them, and asks for user confirmation before deletion. If confirmed, the assistants are deleted in parallel using multithreading. -
delete_files.py
: This script deletes OpenAI files. It fetches a list of all files, displays them, and asks for user confirmation before deletion. If confirmed, the files are deleted in parallel using multithreading.
-
Set your OpenAI API key in a
.env
file or as an environment variable namedOPENAI_API_KEY
. -
Run the scripts using Python 3:
-
python3 delete_assistants.py
-
python3 delete_files.py