Please download the regexes.json file before using uaparser.php. You can type the following at the command line to download the latest version:
%: cd /path/to/UAParser/%: php uaparser-cli.php -g
%: cd /path/to/UAParser/
%: php uaparser-cli.php -g