"Leverage is kept fairly low, but the returns just keep going up" It seams like the recorded leverage is about 2.4 a lot of the times. (Though this value is probably not entirely accurate as @Blue Seahawk posted). 2.4 isn't 'fairly low'. A general retail investor can typically get only 2.
But, that all said, the returns you're seeing are mostly due to the mathematical magic of leverage and compounding. Take a look at the formula for returns below. RETURN is the 'Cumulative Performance' shown on the backtest.
RETURN = ((1 + RxL)^Y) - 1
Y is years
R is annual rate of return
L is leverage
The backtest for this algorithm was performed over 14.9 years (Jan 3 2003 - Dec 1 2017). The benchmark SPY and the algorithm had a return (Cumulative Performance) of 279% and 1301% respectively. Let's plug those into our formula and see what the annual return would be.
1 + (.09 x 1)^14.9 - 1 = 264%
1 + (.08 x 2.4)^14.9 - 1 = 1294%
From the above it can be seen that SPY had an average annual return of about 9%. The algorithm had only about 8%. The magic of leverage and compounding are responsible for the returns that "keep going up". One could probably get better returns by simply using 2.4 leverage and investing in SPY.
1 + (.09 x 2.4)^14.9 - 1 = 1743%
To simulate this, attached is the same algo from 7-3-2006 to 12-1-2017 benchmarked not against SPY but against SSO which is a 2x leveraged SPY ETF. (the shorter backtest is because SSO wasn't started until 6-19-2006). Notice that the algorithm simply follows SSO pretty much up until Dec 2016. This shows that there is virtually no alpha. All the 'excess' returns are simply due to leverage.
There's one other issue with the algo. This can be seen in the 'Positions and Gains' tab on 12-30-2016 in the attached backtest. Not sure this exact trade shows up in the original but it's indicative. There was a huge incorrect spike in the price of PVAC from $.15 to $49.00 a share. There may be a fault with Q data but the overarching issue is this stock is VERY thinly traded. Typically less than 1500 shares per day with some huge spikes. (see https://finance.yahoo.com/quote/PVAC/history?p=PVAC).
The backtesting, and specifically slippage models, on Q don't model low liquidity stocks very well (there's a few posts on this here in the forums). Trades in real life probably wouldn't work out the way the backtester models. That said, one flaw with the algorithm is that it doesn't have any filters to exclude low liquidity stocks. Not that a low liquidity strategy couldn't be profitable, rather the profitablity can't be validated well with the Q backtester.
Finally, to get a much more in depth understanding of why an algorithm has good (or bad) returns, use the 'View Backtest Analysis' button on the backtest. This will return a treasure trove of insightful data. Especially after the addition of the Q risk model (see https://www.quantopian.com/posts/introduction-to-the-quantopian-risk-model-in-research) this tool is invaluable. Note that one may need to shorten the backtest time (perhaps by a lot) to get the analysis to run without running out of memory.