A simple explanation for someone who doesn’t know what these are would be that the United States in 1798 passed a law during high tensions with France, that targeted immigrants, which are called aliens, along with ways to make it so people wouldn’t be able to talk negatively about the government.
I personally think that they did not need to add the sedition act, as everyone is allowed to criticize a government and be able to have free speech. While the Alien Act seems to be a type of segregation,