Facing a court battle, D.C. Mayor Muriel E. Bowser (D) moved this week to alter the composition of the panel advising her on finding a schools chief — a decision that underscores the high stakes involved with installing a chancellor.

Families with children in the District’s traditional public schools sued the city, arguing that the committee Bowser initially assembled in June did not have sufficient representation from students and teachers. The original 14-member panel had a single student and a single teacher, in violation of a city law calling for more robust representation, the parents said in their lawsuit.

“The law is pretty clear. Why should we have to sue about it?” said Valerie Jablow, a parent of two teenagers in the school system and lead plaintiff in the lawsuit. “On the face of it, it’s kind of insane. It’s to the mayor’s benefit if she listens to the direct stakeholders.”

Bowser this week expanded the panel to 19 members, adding two more students, two more teachers and another parent. The committee also includes a charter school official, a university president and others.

“Mayor Bowser has consistently called upon a diverse set of voices to advise her throughout the Chancellor search process,” Ahnna Smith, the interim deputy mayor for education, said in a statement. “She appreciates the enthusiasm from the community to provide their point of view and is confident that she has the most robust process in place to pick the best Chancellor for our students and to lead the DCPS community.”

Even with Bowser’s action this week, Greg Smith — Jablow’s attorney and a D.C. Public Schools parent — said he has no plans to withdraw the lawsuit. Smith said the law governing selection of a chancellor and creation of a search committee mentions only parents, teachers and students as members. As a result, he said other members should be removed.

“It is supposed to be a panel of teachers, parents and students. No one else is mentioned,” Smith said. “If you ask for a bag of M&M’s, you’re only asking for M&M’s, nothing else.”

The mayor’s pick for schools chancellor — it is the second time she has gone through the process since becoming mayor in 2015 — is one of her most politically consequential decisions and could signal the direction Bowser has chosen for a system that educates about 49,000 children. Her choice for chancellor must be ratified by the D.C. Council.

Antwan Wilson resigned as D.C. schools chancellor in February amid revelations that he skirted the lottery system to place his daughter into a coveted high school. Families participate in the lottery when they want their children to attend schools outside their home district or a public charter school. The deputy mayor for education, Jennifer Niles, also resigned in the wake of the scandal.

The interim chancellor, Amanda Alexander, is a contender for the position, the mayor has said. She has led the school system since February and recently hired two deputy chancellors — among the most powerful positions in the school system.

Education advocates have been scrutinizing the chancellor selection process and say they want to ensure the mayor is transparent and follows the law.

In June, local activists held a news conference and demanded a fair selection process. They said the mayor botched the selection of a chancellor in 2016 because she did not “follow the spirit of the law.”

Members of the chancellor search committee in 2016 complained that the mayor showed them Wilson’s résumé only after she had decided to pick him. The city law dictating the selection of a schools chancellor requires the mayor to share the résumé of anyone under consideration with the search committee.

The deputy mayor for education hosted three community forums since August to hear what the community wants in the next chancellor. At the last forum Tuesday, residents said they wanted the schools leader to have experience working in Washington or another urban school system. They also said they wanted a leader who could improve academic outcomes of students from low-income families.

“If they don’t know about being black, if they don’t know about being poor, if they don’t know about being traumatized, then I don’t want them on the list,” Micki Davis, a resident of Northeast Washington, said at the forum.