Input (grade 6): The Thirty Years' War was ended with the Treaty of Münster, a part of the wider Peace of Westphalia.
Output (grade 3): The war ended with the Treaty of Westphalia.