Since you posted your question, HTTP::BrowserDetect has since been updated. Once installed, here's how you could use it to parse a text file of user-agent strings:
cat user_agent_strings.txt | perl -nE 'use HTTP::BrowserDetect; $ua = HTTP::BrowserDetect->new($_); say $ua->browser_string || "unknown";'