I converted my helios from D7 (budget 7 speed) to x18 (premium 18 speed) for ~£250 . I was going to build a 2nd one as there was a donor for sale £40 on Facebook...
So, if you are handy and have time to wait for parts to come from asia, I think you can build a very good folder for $500 if you're happy with good 2nd hand parts. I found that folder can use mixture of MTB and Road gear and there are always people who want the latest piece on kit and sell 1, 2 yrs old bits in very good condition...
My helios (~$320 of upgrades and ~~$550 when bought 10 yrs ago) is not far of a tern x18T which is worth $1900
Helios... race bike type or TT?
If I am totally honnest, I wanted a dash x18 (fast etc.) but a dash would have cost £850 for a P18 and I would have had to add £150/200 for a fast road drop bar conversion... so I didn't spend £800 / ~$1000.