Put the lemon juice in a medium bowl.
Peel, halve, and core the apples. Cut each half into thin wedges. Toss the apple with the lemon juice..
Add the sugar and toss to combine evenly.
In a large skillet add the apples and cook, stirring, until the sugar dissolves and the mixture begins to simmer, about 2 minutes.
Cover, reduce heat to medium-low, and cook until the apples soften and release most of their juices, about 7 minutes.
Strain the apples in a colander over a medium bowl to catch all the juice. Shake the colander to get as much liquid as possible. Return the juices to the skillet, and simmer over medium heat until thickened and lightly caramelized, about 10 minutes.
Place a rack in the lower third of the oven and preheat the oven to 375 degrees F.
In a medium bowl, toss the apples with the reduced juice and spices. Set aside to cool completely. (This filling can be made up to 2 days ahead and refrigerated or frozen for up to 6 months.)