Random charges of tyranny
Solution 1:
Maybe I opened the popup and by the time I clicked "Imprison" they had their plot auto-stopped.
That's precisely what happened. It is not impossible, it has happened to me many times.
As evident from your statement, you have auto-stop plots option enabled. So what happens is:
- A vassal plots something.
- You get a popup to imprison them.
- Meanwhile, a message is on its way to the vassal to end their plot.
- The time it takes for a landed noble to respond to a missive depends on the distance it is from your capital.
- By the time you clicked imprison, the vassal had already ended their plot. Which therefore gave you a tyranny penalty as you imprisoned them without a cause.
An important thing to note is, whenever the plot is autostopped and you have imprison dialogue open, it immediately shows that you will get -40 penalty. I reckon you did not notice that and imprisoned the guy anyways.
There is no console command available in this regard except the remotely related neg_opinion command. You can view list of all console commands here.