private static Arity getOutputArity(final Traversal<?, ?> traversal, final Arity inputArity) {
        if (traversal == null) {
            throw new NullPointerException("traversal is marked non-null but is null");
        }

        Arity result = inputArity;
        if (traversal instanceof AbstractLambdaTraversal<?, ?>) {
            if (SPECIAL_TRAVERSAL_TO_ARITY_FUNCTION_MAP.containsKey(traversal.getClass().getSimpleName())) {
                result = result.computeArity(SPECIAL_TRAVERSAL_TO_ARITY_FUNCTION_MAP.get(traversal.getClass().getSimpleName())
                        .apply(traversal));
            }
        } else {
            final List<Step> steps = traversal.asAdmin().getSteps();
            for (Step step : steps) {
                result = getStepOutputArity(step, result);
            }
            return result;
        }
        return result;
    }
This enum value tells that the output arity of the step is multiple.
For example: out(), in() unfold etc.
gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/strategy/util/StepOutputArityPredictor.java