Get Started¶
This page walks you through the smallest possible OO-LD schema, step by step. If you are not familiar yet with JSON Schema or JSON-LD, you may first want to look at dedicated tutorials like the OSW JSON Schema Tutorial and the OSW JSON-LD Tutorial.
Step 1 - Write a schema that is also a context¶
The core idea of OO-LD is that a single document is at once a valid JSON Schema and a reference-able JSON-LD remote context. Start from a plain JSON Schema and add an @context:
- The JSON Schema part (
type,properties, …) describes the structure of the object. - The
@contextpart maps thenameproperty to the semantic termschema:name, describing its meaning. $idgives the schema a stable identity and$schemadeclares the OO-LD dialect (the meta-schema).
JSON or YAML?
JSON is the canonical notation for OO-LD. YAML is an equivalent, more human-friendly rendering as long as it stays within the JSON-compatible subset (no anchors, tags, or implicit typing surprises), so every example here has a "View as YAML" tab. See the specification's Notation section for the normative rule.
Step 2 - Try it in the playground¶
You can explore this exact example - validation, UI generation, and RDF output - in the interactive playground. The playground otherwise opens with the richer Person example; every official example under examples/ can be loaded the same way via ?schema=.
Step 3 - Validate schemas in this repository¶
This repository ships example schemas under examples/ and the OO-LD meta-schema under meta/. To validate them locally:
Next steps¶
- Basic Concepts - how a schema doubles as a context, and how inheritance works.
- Composition - assemble complex types from reusable building blocks.
- Schema Instances - how instance documents reference their schema and carry identity and type.