I recently coded an algorithm which (I think) can be used to isolate either a specific or common return. To isolate a common return you simply put your algorithm logic into the pipeline and let it run. To isolate a specific return you add in your entire algorithm, reverse the weights (negatives go to positive and vice versa) essentially shorting this algorithm and the outcome should be the specific returns.
It's not perfect because I:
a) Don't know exactly how Quantopian's risk model works
b) Haven't run the sector exposures of the stocks I added to mimic the factor returns, leaving some gapping.
It works in backtesting with a very simple fundamental long-short algorithm
The specific returns are caused (I believe) by the errors I outlined above.