How long should I wait before contacting my ex girlfriend (trying to get her back)?

My ex-gf and I had been dating for 2.5 years before she broke up with me about 3 weeks ago.
During the breakup she told me that she loves me and that one day in the future we can maybe get back together. However, her reason for the breakup was that she was no longer sexually attracted to me and that this has been a struggle for her for the past several months because she thought she was asexual (due to her low sex drive/no desire for sex). In this past several months she did not want to be intimate with me. She said that she would like it for us to remain friends, or even best of friends but I told her I cannot do that as Everytime I would get close to her I would want us to get back together because of our history.

Also, during our 2.5 years together she had been abroad for 10 months.

After the breakup I realized that over the course of our relationship I have developed some unattractive traits such as messaging her everyday (so needy, clingy), that I put her at centre of my world, stopped/reduced flirting which made the spark disappear , and not taking the lead in the relationship. I believe these are what caused her to be sexually unattracted to me.

After the breakup I took the time not to contact her to give her space but aswell to work on myself and fix these issues and so far it's been 3 weeks.

I am very much in love with this girl and I would like to try to get her back and I know she loves me too. So I'm just wondering, how much longer should I wait before trying to recommunicate with her to try and slowly build that spark that we once had at the beginning of our relationship?

I understand that she needs her space to figure things out but at the same time I don't want to wait too long before she completely moves on from me.
How long should I wait before contacting my ex girlfriend (trying to get her back)?
Add Opinion