The man had been swapping sodium chloride, or table salt, for sodium bromide for three months after consulting ChatGPT