You will find that portions of the regex marked with parentheses will be
places in variables called $1, $2, etc.  So, you will want to change the
regex to

/(?!%)\w+\s+(\(\w+\))/

And then the contents of (\(\w+\)) will be placed in the variable $2.

-Jonathan Nielsen