Licensing agreement optimization