VertexFeatures.getCardinality(String) which, if implemented by the provider, will tell you a hint at the cardinality. https://github.com/apache/tinkerpop/blob/1e3c881d9f157167b53f431898e6d1ee40429cd0/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/structure/Graph.java#L581-L594