Man, this one is tough for me. The reason being is that most mass shooters send out tons of red flags on social media prior to committing a crime. However, I realize that the definition of a "red flag" is fluid and can be contorted to include many things that trust-worthy people might say online. In the current political climate, it'd just be another tool for gun-grabbers.
I would prefer to see social media scraping used at public schools. I truly believe that public schools should go full-on China dystopia with CCTV covering every angle of the school grounds, in which every student is submitted to facial recognition and followed on campus by AI. Anyone not in the recognition database gets red-flagged and contacted by security, and the AI would scan social media for students who act-out online and have school reps pull the students aside when they threaten people online. It can all be done by software.
Oh, and they could take down all the stupid "Gun Free Zone" signs, because yeah those really stop criminals!
In the adult world, we don't need more gun laws, just fully prosecute criminals. Vast majority of gun crimes are committed by repeat offenders who are in illegal possession of a firearm. I truly believe letting out repeat offenders (especially those with a thing for gun crimes) is just a tool used to justify restricting law-abiding owners. Only places that need increased control might be schools as this is where the killers are most likely to be 1st timers.