public Document withGroupId(String groupId) {
        setGroupId(groupId);
        return this;
    }
<p>
The optional group identifier of the document from the search service. Documents with the same group identifier
are grouped together and processed as one document within the service.
</p>

@param groupId
       The optional group identifier of the document from the search service. Documents with the same group
       identifier are grouped together and processed as one document within the service.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-kendraranking/src/main/java/com/amazonaws/services/kendraranking/model/Document.java