For nodes you can use addon that automatically make submenus for groups, splitting them by underscore in name.
Free, works with GN too