Among his deeds for the benefit of the town (which include the rebuilding of the Assumption of Mary Basilica, construction of the Saint Lazarus Hospital, the brewery, water mills, utility and residential buildings) the special recognition is deserved by the foundation of the Trzemeszno College in 1773, with a seminary for clerical students, and of a public school.
The abbot founded them because he saw the regrettable condition of education and the collapse of Polish schools. At the same time he desired to make education possible for the talented youth of limited means. In the years 1773-75, a small three-nave building of the Trzemeszno College was erected near the basilica.
The building survives to this day. On the front gate there is a marble plaque with a portrait of king Stanisław August Poniatowski and his monogram, Eye of Providence, coats of arms of Poland and Lithuania, coat of arms of king Ciołek, and a Latin founding inscription: Stanisław August the king, the glorious restorer of learning, during whose reign the college was started in the favourable year of 1773, finished in 1775, may it survive and be immortalised.
After the period of partitions in the years 1793-1918, when Poland regained its independence, favourable times came for the school. In 1932 the State Middle and Secondary School in Trzemeszno was named after Michał Kosmowski. Currently the beautiful, more than 200 hundred year old tradition of Alma Mater Tremesnensis is continued by the School Complex - M. Kosmowski Secondary School and Middle School.