[PLAT-5232] Add permissive modes to functions, fix portfolio names in integration test, add function-by-type cache.