A former inmate at a maximum security prison has been convicted for his role in a prison brawl that followed the stabbing of a guard. Soksoursdey Roeung was sentenced Tuesday to 18 to 23 years after he was convicted at a jury-waived trial in Worcester Superior Court of charges including armed assault with intent to murder and assault and battery on a correction officer. The charges stemmed from the June 2012 stabbing of Nathan Beauvais, a guard at the Souza-Baranowski Correctional Center in Shirley. Beauvais, 28, was stabbed in the neck by Roeung’s cellmate using a prison-made knife, apparently in retaliation after Beauvais confiscated some contraband from the cell. Roeung, 28, then attacked Beauvais and another guard who had come to his colleague’s aid, prosecutors said.