blob: a5fcb4d468367ee99a769f24b94a2922b70cfe36 [file]
////
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
////
:docinfo: shared
:docinfodir: ../
:toc-position: left
image::apache-tinkerpop-logo.png[width=500,link="https://tinkerpop.apache.org"]
*x.y.z*
[llms-summary="A reference for the sample graphs bundled with TinkerPop. Each section describes a graph's nature, origin and best use, presents its schema in GQL Graph Types, and demonstrates it with runnable Gremlin.",allow-oversize="true"]
= TinkerPop Sample Data
image:gremlin-standing.png[width=125]
TinkerPop bundles a small collection of sample graphs, often called "toy graphs", that appear
throughout the reference documentation, the tutorials, and the test suites. They are deliberately
small and self-contained so that a traversal can be read alongside the data it operates on, and
they are available in every distribution without any external data source or configuration. Each
graph is constructed by a factory method on
link:https://github.com/apache/tinkerpop/blob/master/tinkergraph-gremlin/src/main/java/org/apache/tinkerpop/gremlin/tinkergraph/structure/TinkerFactory.java[`TinkerFactory`]
and also ships as data files under the `data/` directory of the distribution in the GraphSON,
GraphML, and Gryo formats.
This book serves as a reference for those graphs. Each section describes one graph: the nature of
its data, where it came from, and the kinds of problems it illustrates best. Every graph is then
given a schema expressed in link:https://learn.microsoft.com/en-us/fabric/graph/gql-graph-types[GQL
Graph Types], a declarative notation that states the node and edge labels a graph may contain,
their properties and value types, and how edges connect the nodes. Finally, each section presents
Gremlin examples that exercise the data and demonstrate the traversal patterns the graph was
designed to teach.
The examples in this book are executable and run against the corresponding graph at build time, so
their results are the actual output produced by the graph. The same graphs are available in the
Gremlin Console through `TinkerFactory`, which makes it convenient to follow along and experiment
with variations of the queries shown here.
include::modern.asciidoc[]
include::the-crew.asciidoc[]
include::the-zoo.asciidoc[]
include::grateful-dead.asciidoc[]
include::air-routes.asciidoc[]