The Maryland Department of Juvenile Services yesterday agreed to a series of improvements at its new juvenile detention center, ending for now a legal challenge in which state Public Defender Nancy S. Forster described conditions there as "unsafe and inhumane."

Forster said in a statement that the department agreed to add security equipment at the troubled Baltimore City Juvenile Justice Center, provide special education services and make "repairs and structural improvements." The department also agreed to hire, within three months, staff sufficient for the pretrial facility's maximum capacity of 144 boys, she said.

In return, Forster agreed not to pursue a claim she had filed in the juvenile division of Baltimore Circuit Court on behalf of 67 "John Doe" residents. In a petition filed Sept. 22, Forster asked a judge to either order immediate improvements or remove her office's clients housed at the center. She cited systemic violence and allegations that workers have induced young residents to fight one another.

The agreement, like the petition and other juvenile court records, is confidential. Forster summarized its terms in a statement, and a spokeswoman for the department later said the statement was accurate.

Forster said in an interview yesterday that the center, which opened less than a year ago, has been a "powder keg" and that her office "is hopeful since we were able to reach this agreement that the conditions of confinement will improve for our clients."

But state Sen. Brian E. Frosh said "it's hard to hail [the agreement] as a solution" because "everything in there is stuff they should be doing already."

"This is a step forward, but it's a baby step," said Frosh (D-Montgomery), who chairs the Judicial Proceedings Committee. "We should have been here already. The notion that they should have adequate staff to the number of kids is pretty elementary."

A spokeswoman for the department, LaWanda Edwards, said: "It was real easy for us to agree to these terms. It's things that we were, are, will be doing.

"Staffing has improved tremendously and we are making repairs," Edwards added.

The $60 million center opened Oct. 30 after more than a decade of planning and construction. It was intended to provide desperately needed space for boys, mostly 14 to 17, awaiting trial on offenses that typically include auto theft, simple assault and drug possession.

In a report issued last month, the Office of the Independent Juvenile Justice Monitor said the center did not have enough staff to keep even half of its then-106 residents safe and under control. The situation was so volatile, the report said, that public defenders and "various ministerial and volunteer groups have not been visiting the facility for fear of their own safety."

Frosh said he was "nervous" about the portion of yesterday's agreement that requires staffing sufficient for a population of 144, a number he said the center cannot accommodate. It appears, he said, that the state hopes that the center can be used to "alleviate problems" at two older facilities, the Cheltenham Youth Facility in Prince George's County and the Charles H. Hickey Jr. School in Baltimore, "which are abysmal, but unfortunately, this place is bad in different ways."

"It's newer but it's poorly designed," he said.

Forster said progress on the agreement is to be monitored through reports the department said it would file with her office and the court.