@Override
    public DataType setInputType(DataType inputType, TypeContext context) {
        if (!inputType.isAssignableTo(DataType.STRING)) {
            throw new VerificationException(
                    this,
                    "Generate expression for field %s requires string input type, but got %s."
                            .formatted(destination, inputType.getName())
            );
        }

        super.setInputType(inputType, DataType.STRING, context);
        return targetType;
    }
The target type we are generating into.
indexinglanguage/src/main/java/com/yahoo/vespa/indexinglanguage/expressions/GenerateExpression.java