Sanhedrin 88 - How is a Judge Selected to High Court
The judges of the Great Sanhedrin would send the following message to lower courts in all places, "Anyone who is wise and humble and whom the people find agreeable shall be a judge in his city." From there they elevate the deserving judge to the court that sits at the entrance to the courtyard, and from there - to the Sanhedrin, which sits in the Chamber of Hewn Stone. Additional qualification is that he constantly learns Torah but does not take the credit for it for himself.
With regard to rebellious sage, greater stringency is attached to the teachings of the Sages, like the ones found in the Talmud, than to the words of the Torah. If, for example, he says that there is no commandment of tefillin, he is exempt, since it is such an obvious distortion that it cannot be viewed as a ruling. However, if he says that there are five compartments in the tefillin, and not four, he is liable.
Art: Marc Chagall - The Praying Jew