This is a highly ethical question which would result in a lot of pain independent of the taken decision.
Fortunately, such situations, with all the information and enough time to think, do not often occur in the real world.
From a mathematical point of view, it seems better to save five lives than just one.
However, taking an action intentionally to kill a human is an unsatisfactory decision as well as killing five people by omission.
In a real world scenario the uncertainty of both actions is an important factor.
For example, you are a judge who knows that the accused person is innocent. The case is of great public interest.  If you acquit the person of the charge, it may lead to violent actions that would hurt many people.
You would probably reject the charge because there is a chance that the verdict is received peacefully by the people and because your action would not be the immediate cause.
spam fails_task lang_mismatch pii not_appropriate hate_speech sexual_content quality toxicity humor helpfulness creativity violence