FlagVNE: A Flexible and Generalizable Reinforcement Learning Framework for Network Resource Allocation