Chelsea Manning, the soldier convicted of giving classified government materials to WikiLeaks, has been released from a Kansas military prison.
Here is a timeline of her story so far.
Manning, then known as Bradley, was a private in the US army. In 2009 she was sent to Iraq as an intelligence analyst.
She was arrested in 2010 after leaking 700,000 secret military and state department documents to WikiLeaks.
Included in the leaked files were sensitive messages and video footage of a US helicopter killing 12 civilians in Baghdad in 2007.
In August 2013 Manning was convicted of 20 counts, including six Espionage Act violations, theft and computer fraud. She was acquitted of the most serious charge of aiding the enemy.
The trove, which included classified battlefield videos, was one of the biggest breaches of intelligence in US history.
She acknowledged leaking the files while working in Iraq, but protested that she had acted to raise awareness of the impact of US military action on innocent civilians. She was sentenced to 35 years behind bars.
Trans issues are not a "distraction." They are a harbinger of things to come. When it happens to you it won't be a distraction. #LGBTQ— Chelsea E. Manning (@xychelsea) January 10, 2017
The day after her sentencing, Manning said she had felt female since childhood and now wanted to be referred to as Chelsea, not Bradley. She said she wanted to begin hormone therapy and be referred to using female pronouns.
In 2016 Manning made two attempts to take her own life, citing ill-treatment behind bars. She was imprisoned at Fort Leavenworth, a male military prison.
She also went on hunger strike, before the army agreed to provide her with gender reassignment surgery.
In his final days in office, Barack Obama granted Manning clemency and commuted her sentence. He did not grant a pardon, which would have symbolically forgiven her for the crime.
Obama said his decision took into account the fact that Manning took responsibility for her crime, and had been given a harsher sentence than other leakers.
Two more days until the freedom of civilian life ^_^ Now hunting for private #healthcare like millions of Americans =P— Chelsea E. Manning (@xychelsea) May 15, 2017
Manning was released from prison after serving seven years of her initial 35-year sentence.
In a statement, she said she hopes to use the lessons she received in prison to help others.
She added: “I can imagine surviving and living as the person who I am and can finally be in the outside world.
“Freedom used to be something that I dreamed of but never allowed myself to fully imagine.”