I was going to say the same thing as "the Tin Man". There has to be another format you can generate the data in.
If you want to parse this however... Parslet works like a map/reduce algorythm. You're first pass (parsing) is not intended to give you your final output, just to capture all the information you need from your source document.
Once you have that stored in a tree, you can then transform it to get the output you want.
So... I would write a parser that records each white space as a node, aswell as matching the text and percentages you need. I would group the white space nodes in an "indentation" node.
I would then use a transform to replace the whitespace nodes with a count of nodes to calculate the indentations.
Remember: Parslet generates a standard ruby hash. You can then write whatever code you like to make sense of this tree.
The parser is just converting the text file into a data-stucture you can manipulate.
Just to reiterate though. I think "the Tin Man" has the right answer.. generate the data in a machine readable way instead.
Update:
For an alternative approach you can check out: Indentation sensitive parser using Parslet in Ruby?