Skip to content

graph of links#1387

Open
dylanmcreynolds wants to merge 3 commits into
bluesky:mainfrom
als-computing:graph
Open

graph of links#1387
dylanmcreynolds wants to merge 3 commits into
bluesky:mainfrom
als-computing:graph

Conversation

@dylanmcreynolds
Copy link
Copy Markdown
Contributor

@dylanmcreynolds dylanmcreynolds commented May 13, 2026

This implements a sql-based graph-like linking implementation. This is EXPERIMENTAL. Like, really quite experimental.

With #242, @danielballan implemented a linking mechanism to implement compatibility for bluesky references.
We discussed a more general purpose linking mechanism, which might even be able to produce JSON-LD and/or RDF. These specifications are widely used to provide semantic meaning to links between objects on the web. These technologies are often implemented in purpose-built "tripl store" databases, which are highly optimized for indexing and searching a triple, often described as subject, predicate object. Specialized query languages like SPARQL exist for querying triple stores. Triple stores are a specialization of graph database, with the predicate providing the semantic indicator of the link.

Another popular feature of triple stores to actually quad stores, with another dimension helping support groups of triples, imagine projects, for example

This PR is inspired by triplestores, but does not implement many of the features. It does this all in SQL, with lots of indexes. It adds a third database to the tiled family (in addition to catalog and auth). In that database are a couple of key t tables:

  • entities which carry URIs and metadata blocks
  • links which have columns for subject, object, and predicate

The PR exposes this new functionality using a GraphQL endpoint, rather than a RESTful endpoint. This is a departure for tiled, and something that should be considered and debated. I did it this way because it felt more natural for queries here.

Much of this code comes from another project: splash_links. It could easily stay as a separate service, but in discussions with @ahexemer and @danielballan, there was a strong desire to make it a core feature of Tiled. We imagine this helping with several key types of use cases:

  • Applications that are storing processed data in tiled, and want to link that data to it's raw data...or processed to other processed.
  • Information from multiple proposals or multiple instruments that naturally fit under a single "experiment", "project", or "campain"
  • Links between nodes in tiled and resources external to tiled...or other tiled servers

Checklist

  • Add a Changelog entry
  • Add the ticket number which this PR closes to the comment section
  • Unit tests
  • Implement access_tags to support access control enforcement
  • User Documentation
  • Export links as JSON-LD
  • Support predicate sub-classing with another table
  • Probably want a quad column

Full disclosure, much of this PR was assited by an LLM (Claude). To the extent possible, all changes were reviewed before being accepted.

@checkmarx-gh-ast-us-povs
Copy link
Copy Markdown

checkmarx-gh-ast-us-povs Bot commented May 13, 2026

Logo
Checkmarx One – Scan Summary & Detailseaa1ad76-0da6-4810-af50-02fc5e9004f0

Great job! No new security vulnerabilities introduced in this pull request


Communicate with Checkmarx by submitting a PR comment with @Checkmarx followed by one of the supported commands. Learn about the supported commands here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants