Welcome to the Turtle Editor Viewer, a modern tool for editing RDF data, visualizing graphs, and executing SPARQL queries. This guide covers the key features and how to use them effectively.
The application interface is divided into two main resizable panes:
- Editor Pane (Left): A robust code editor for writing and loading RDF data. This pane also includes the Subjects selection and filtering tools.
- Graph & SPARQL Pane (Right): Contains the visual graph representation of your data and the SPARQL query interface.
You can adjust the width of the panes by dragging the vertical separator between them. The Graph pane is further split horizontally between the visualization area and the SPARQL panel.
The Editor Pane allows you to input, modify, and manage your RDF data.
There are three ways to load data into the editor:
- Direct Input: Simply type or paste your code into the editor.
- Open File: Click the
Choose Filebutton in the toolbar to load a local file. Supported formats include:- Turtle (
.ttl) - RDF/XML (
.rdf,.xml) - JSON-LD (
.json,.jsonld) - DOT (
.dot)
- Turtle (
- Load from URL: In the Graph Toolbar (right pane), enter a URL and click
Load URL. Note: The server hosting the file must support CORS.
The toolbar at the top of the editor provides several customization options:
- Language: Manually set the syntax highlighting (Turtle, RDF/XML, JSON-LD, DOT). The editor usually auto-detects this based on content.
- Theme: Choose your preferred color scheme (Cobalt, Dawn, Eclipse, GitHub).
To save your current work, click the Save File button. This will download the current editor content as a file (defaulting to turtle-file.ttl) to your computer.
The Graph Pane automatically visualizes the relationships defined in your RDF data using Graphviz.
- Automatic Detection: As you type, the application parses your code. If valid RDF is detected, it identifies "Subjects" (resources that have properties).
- Subject Selection:
- Specific Subjects: In the Editor Toolbar (top right of the left pane), use the Subjects dropdown to select one or more subjects to visualize.
- Search Filter: Use the filter box above the subjects dropdown to quickly find specific resources by name.
- Get All: Click the
Get Allbutton in the Graph Toolbar (right pane) to visualize the entire dataset (limited to the first 10 subjects by default for performance). Note: When loading a new file, the first 10 subjects are automatically selected.
You can customize how the graph is rendered using the toolbar controls in the Graph Pane:
- Engine: Change the Graphviz layout algorithm (e.g.,
dotfor hierarchies,neatofor force-directed,circofor circular layouts). - Format: Select the output format (
SVGis recommended for interactivity,PNGfor static images,JSON/XDOTfor raw data). - Layout: Change the direction of the graph (e.g., Left-to-Right
LR, Top-to-BottomTB). - Display Toggles:
Prefixes: Toggle shortened namespace prefixes (e.g.,rdf:typevs full IRIs).Hide Types: Hidesrdf:typerelationships to declutter the graph.Hide Annotations: Hides common annotation properties (labels, comments, notes) to focus on structural relationships.Subjects: Toggle visibility of subject nodes.
- Pan & Zoom: Use your mouse wheel to zoom in/out and click-and-drag to pan around the graph.
- Context Menu: Right-click on a node to see more details or perform specific actions (depending on the node type).
The SPARQL Panel at the bottom right allows you to query the data currently loaded in the editor.
- Write Query: Enter your SPARQL query in the text area.
- Add Prefixes: Click
Add Prefixesto automatically prepend common prefixes defined in your RDF data. - Execute: Click
Execute Queryto run the query.
The engine supports standard SPARQL 1.1 query forms:
SELECT: Returns a table of results.ASK: Returns a boolean (True/False).CONSTRUCT: Returns an RDF graph.DESCRIBE: Returns an RDF graph describing resources.
Results are displayed in a table below the query editor. You can clear the results by clicking Clear Results.
The application includes a client-side reasoner (Hylar) that supports OWL 2 RL.
- Click
Show Factsin the Graph Toolbar to perform reasoning on your data. - This opens a new window showing Explicit Triples (asserted in your data) and Implicit Triples (inferred by the reasoner).
You can convert your current RDF data between formats using the buttons in the Graph Toolbar:
To Turtle: Converts current data to Turtle format.To JSON-LD: Converts current data to JSON-LD format.
You can pre-load data when sharing a link to the application:
?dot=<url>: Loads a DOT or Turtle file from the specified URL.
Documentation generated for Turtle Editor Viewer v2.0.0
