SEATTLE — A former community college professor who won a surprising citywide election was sworn in Monday as the first socialist City Council member in Seattle’s modern history.

Kshama Sawant of the Socialist Alternative party took her oath and served in her first hearing, then gave a speech to throngs of supporters in a ceremonial swearing-in at a packed City Hall.