create a scripted segment editor effect by extension wizard

I figured out a way: Creating a basic Paint Foreground and Paint Background Tool - Support - 3D Slicer Community

Instance segment editor widget. Thank Pinter for your remind.

But I still don’t understand why the template don’t work.