WASHINGTON (AP) -- Pentagon leaders are finalizing plans aimed at lifting the ban on transgender individuals in the military, with the goal of formally ending one of the last gender- or sexuality-based barriers to military service, senior U.S. officials told The Associated Press.

An announcement is expected this week, and the services would have six months to assess the impact of the change and work out the details, the officials said Monday. Military chiefs wanted time to methodically work through the legal, medical and administrative issues and develop training to ease any transition, and senior leaders believed six months would be sufficient.

The officials said Defense Secretary Ash Carter has asked his personnel undersecretary, Brad Carson, to set up a working group of senior military and civilian leaders to take an objective look at the issue. One senior official said that while the goal is to lift the ban, Carter wants the working group to look at the practical effects, including the costs, and determine whether it would affect readiness or create any insurmountable problems that could derail the plan. The group would also develop uniform guidelines.

During the six months, transgender individuals would still not be able to join the military, but any decisions to force out those already serving would be referred to the Pentagon's acting undersecretary for personnel, the officials said. One senior official said the goal was to avoid forcing any transgender service members to leave during that time.

Several officials familiar with the planning spoke on condition of anonymity because they were not authorized to talk about the issue publicly before the final details have been worked out.

In a statement to The Associated Press, Carter said, "we must ensure that everyone who's able and willing to serve has the full and equal opportunity to do so. And we must treat all of our people with the dignity and respect they deserve. Going forward the Department of Defense must and will continue to improve how we do both."

Some of the key concerns involved in the repeal of the ban include whether the military would conduct or pay for the medical costs, surgeries and other treatment associated with any gender transition, as well as which physical training or testing standards transgender individuals would be required to meet during different stages of their transition.

Officials said the military also wants time to tackle questions about where transgender troops would be housed, what uniforms they would wear, what berthing they would have on ships, which bathrooms they would use and whether their presence would affect the ability of small units to work well together. The military has dealt with many similar questions as it integrated the ranks by race, gender and sexual orientation.

Transgender people - those who identify with a different gender than they were born with and sometimes take hormone treatments or have surgery to develop the physical characteristics of their preferred gender - are banned from military service. But studies and other surveys have estimated that as many as 15,000 transgender people serve in the active duty military and the reserves, often in secret but in many cases with the knowledge of their unit commander or peers.

"Obviously this isn't finished, but Secretary Carter's clear statement of intent means that transgender service members should and will be treated with the same dignity as other service members," said Allyson Robinson, Army veteran and policy director for an association of lesbian, gay, bisexual and transgender military personnel called Service members, Partners, and Allies for Respect and Tolerance for All, or SPARTA.