> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getcollate.io/llms.txt
> Use this file to discover all available pages before exploring further.

# RDF Knowledge Graph Indexing

> Understand how Collate uses RDF and Apache Jena Fuseki to power knowledge graph capabilities, semantic search, and SPARQL queries.

# Overview

Collate uses RDF (Resource Description Framework) to build a knowledge graph of your metadata. This enables semantic search, SPARQL (SPARQL Protocol and RDF Query Language) queries, and JSON-LD representations of your data assets.

## What RDF Indexing Enables

RDF indexing extends your metadata catalog with graph capabilities, making it possible to query and explore data relationships beyond simple search.

* **Semantic search**: Query metadata using meaning and relationships, not just keywords.
* **Knowledge graph**: Explore connections between entities across your data catalog.
* **SPARQL queries**: Run graph queries directly against your metadata.
* **JSON-LD serialization**: Export any entity in standard linked data formats (JSON-LD, Turtle, RDF/XML, N-Triples).
* **Ontology support**: Metadata is modeled against the OpenMetadata OWL ontology.

## How It Works

RDF indexing runs as a background application alongside your Collate deployment. Collate uses **Apache Jena Fuseki** as the underlying triple store.

When RDF is enabled:

* New and updated entities are automatically indexed to the triple store.
* Hard-deleted entities are removed from the triple store.
* Existing entities can be reindexed on demand via the RDF Index App.

## Available API Endpoints

Use these endpoints to check RDF status, retrieve entities in linked data formats, or run custom graph queries. Once RDF is enabled, these endpoints are available on your Collate instance:

| Endpoint                                   | Description                                     |
| ------------------------------------------ | ----------------------------------------------- |
| `GET /api/v1/rdf/status`                   | Check whether RDF is enabled                    |
| `GET /api/v1/rdf/entity/{entityType}/{id}` | Get any entity as RDF (JSON-LD by default)      |
| `POST /api/v1/rdf/sparql`                  | Execute a SPARQL query against the triple store |

### Supported RDF Formats

The default format is JSON-LD. Pass `?format=` to the entity endpoint to select a different serialization:

| Format            | Parameter value |
| ----------------- | --------------- |
| JSON-LD (default) | `jsonld`        |
| Turtle            | `turtle`        |
| RDF/XML           | `rdfxml`        |
| N-Triples         | `ntriples`      |

## Installation

1. Select the **Profile** icon and navigate to **Settings** > **Applications**.
2. Click **Add Apps** and select the **RDF Knowledge Graph Indexing** application.
3. Click **Install**.
4. Configure the following options and click **Save**:
   * **Entities** — Select which entity types to index. Leave blank to index all supported entities.
   * **Recreate RDF Store** — When enabled, drops and rebuilds the RDF store before indexing. Default: enabled.
   * **Batch Size** — Maximum number of entities processed in a single batch. Default: `100`.
   * **Producer Threads** — Number of threads that read and produce entity batches for non-distributed indexing. Default: `2`.
   * **Consumer Threads** — Number of threads that consume and index entity batches for non-distributed indexing. Default: `3`.
   * **Queue Size** — Internal queue capacity between producers and consumers for non-distributed indexing. Default: `5000`.
   * **Use Distributed Indexing** — Enable distributed indexing across multiple servers with partition coordination and recovery. Default: enabled.
   * **Partition Size** — Number of entities per partition when distributed indexing is on. Smaller values create more partitions for better distribution. Default: `10000` (range: 1,000–50,000).
5. Set a schedule and click **Submit**. The default schedule runs every Saturday at midnight.

## Manage Application

After installation, open the application from **Settings** > **Applications** > **RDF Knowledge Graph Indexing**.

### Schedule

The **Schedule** tab shows the current schedule type and interval. Click **Edit** to update the schedule, or click **Run now** to trigger an immediate run.

### Recent Runs

Each row in the run history shows the run time, run type, duration, and status. Click **Logs** to view the full run log, or **Config** to see the configuration used for that run.

### Disable or Uninstall

Select the **⋮** icon in the top-right corner of the application page:

* **Disable** — Pauses the application without removing it. The app stops running on schedule but retains its configuration.
* **Uninstall** — Removes the application from Collate entirely.
