QuickSpec: Clean up example filtering logic

Move complex methods into World.swift.