index_actor.scrub {multi|||}
index_temp_6.scrub {multi||">}
index_temp_2.modify {set|0}
index_loop{(each "index_temp_3" in 'index_actor')|end}
index_temp_4.modify {substring(type=element)|'index_temp_6' 'index_temp_2' 1}
index_temp_4.modify {addstart(not "")|(role=}
index_temp_4.modify {addend(~ "role=")|)}
index_temp_5.modify {addend|'index_temp_3''index_temp_4'##}
index_temp_2.modify {calculate(format=F0)|1 +}
end_loop
index_actor.modify {set|'index_temp_5'}
index_actor.modify {replace|##|\|}