Currently the URI shortening for queries uses a simple regular expression. It would be much better to use Soprano::NRLModel to get the existing namespace abbreviations from Nepomuk and use those and those only.