Foundations of proof systems (M2 MPRI)