/neo4j-skills:neo4j-ontology-skillfrom neo4j-skills
Authors and validates Neo4j Ontology Graph Specification documents in YAML/JSON, defining nodes, relationships, properties, data types, constraints, labels, and cardinality. Includes a validator script that checks against the live-resolved spec schema.
Ships in neo4j-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
neo4j-cypher-skill (ontology Cypher procedures do not exist yet — later work there)neo4j-modeling-skillIdentify what is being modeled: entity types (nodes), connections (relationships + direction), properties per element, identifying keys, mandatory fields, cardinality. If the domain or required shape is unclear, ask the user what is being modeled and which questions the ontology must answer. Do NOT guess a domain.
YAML or JSON per user preference; default YAML (more readable). Apply the Core Facts below. Load references/format-reference.md when anything beyond the minimal example is needed (full labels object, constraint objects, extensions, full data-type grammar).
# From the skill directory:
uv run scripts/validate.py <document.{yaml,yml,json}>
# From the repo root:
uv run neo4j-ontology-skill/scripts/validate.py <document.{yaml,yml,json}>
Exit 0 = valid · exit 1 = schema violations (one line per field path) · exit 2 = parse/read/fetch error. PEP 723 script — uv resolves deps (jsonschema, pyyaml) itself.
The validator fetches the schema live — nothing is vendored. Resolution order: --schema <path-or-url> (explicit, no fallback) → the document's own schema field when it is a URL → the published current alias → repo raw fallback (only when the published host is unreachable). The document's schema URL decides which version it validates against: set it to the published versioned URL of the version being authored (older versions validate against their published schema).
Fix every reported error; re-run Step 3. Repeat until exit 0. Validation is MANDATORY — never present an ontology as done with a non-zero exit.
schema, id (unique ontology id string), version (STRING — user-defined revision label; quote it in YAML: version: "1"). Root rejects unknown fields (additionalProperties: false).schema value: a published versioned URL. Root key is plain schema, NOT $schema.
https://neo4j.com/docs/ontology-graph-spec/current/schema.json, read its $id, write that versioned URL. Never write the /current/ alias (it moves).schema URL; change only when the user asks to upgrade, then re-validate./<version>/schema.json not 200 → unpublished; don't use it.nodes / relationships are maps keyed by LOCAL IDS, not labels/types. Label lives in label or labels.identifier; relationship type lives in type. Endpoints reference node ids (from.node / to.node) — label renames never break references.label: X is shorthand for labels: {identifier: X}. Use the full labels object only when implied or optional labels exist.STRING, INTEGER, FLOAT, BOOLEAN, DATE, DURATION, POINT, UUID; temporal tokens contain a space (ZONED DATETIME, LOCAL TIME); parameterized tokens use angle brackets (LIST<STRING>, VECTOR<FLOAT32>). UUID and VECTOR<...> have no LIST arm. No unions, no nested lists. dimension (integer|null) sits on the property, paired with VECTOR types.key: true, unique: true, must_exist: true (snake_case — NOT mustExist). Single-property shorthands; key = unique + exists per Neo4j key-constraint semantics.constraints is a MAP id → constraint object {type: EXISTS|KEY|PROPERTY_TYPE|UNIQUE, properties: [p1, ...], name: optional} — required for composites (≥ 2 properties) and nameable constraints. properties must name properties declared on the SAME element.count exact, or min_count/max_count ranged; absent = unconstrained (0..*).extensions shape per element — node: indexes/display/custom; relationship: indexes/custom; root: data_source_tables/data_source_mappings/custom; labels/property/constraint/index: custom only. Unknown extension keys rejected. custom is free-form — arbitrary owner data, never validated by the spec schema.properties: {}, aliases: [], custom: {}); omit them.library.ontology.yaml — 2 nodes, 1 relationship:
schema: "https://neo4j.com/docs/ontology-graph-spec/1.1.0/schema.json"
id: library
version: "1"
name: Library
nodes:
author:
label: Author
properties:
id: { type: STRING, key: true }
name: { type: STRING, must_exist: true }
book:
label: Book
properties:
isbn: { type: STRING, key: true }
relationships:
wrote:
type: WROTE
from: { node: author, max_count: 1 }
to: { node: book }
Validates exit 0 via scripts/validate.py. schema URL = newest published on 2026-11-02; apply the schema rule above rather than copying it. Full YAML+JSON worked examples in references/format-reference.md.
Load on demand:
labels object, constraint objects, extension shapes, data-type grammar, gotchas, YAML+JSON exampleshttps://neo4j.com/docs/ontology-graph-spec/ — immutable /<version>/schema.json per spec version, moving alias /current/schema.jsonPublished: the ONT-31 URLs above are live and are the canonical schema source. If the published host is unreachable, the validator falls back to the raw schema from neo4j/ontology-graph-spec main (moving). Ontology Cypher procedures do not exist yet; applying an ontology to a database is out of scope here.
schema, id, version present; version a quoted string; schema = published versioned URL (new document: $id of /current/schema.json; never /current/) under plain schema key$schemanodes/relationships keyed by local ids; relationship from/to reference node idslabel or labels.identifierdimension on the property with VECTOR typestype ∈ EXISTS/KEY/PROPERTY_TYPE/UNIQUE) for composites/named; constraint properties exist on the same elementcustomuv run scripts/validate.py <file> exits 0 (every reported error fixed and re-validated)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
ontology, graph-specification, yaml, json, schema-validation
30 skills in this plugin
/neo4j-agent-memory-skillAuthoritative reference for the neo4j-agent-memory Python package — a graph-native memory system for AI agents built on Neo4j — and for the hosted service (NAMS) at memory.neo4jlabs.com. Use this skill whenever the user mentions neo4j-agent-memory, agent memory with Neo4j, context graphs, the POLE+O model, MemoryClient/MemorySettings, the memory MCP server, or any of the framework integrations (LangChain, PydanticAI, CrewAI, AWS Strands, Google ADK, Microsoft Agent Framework, OpenAI Agents, LlamaIndex). Also use when the user mentions the hosted service at memory.neo4jlabs.com, NAMS, the Neo4j Agent Memory Service, the `nams_` API key prefix, or the hosted MCP endpoint. Also use when writing documentation, blog posts, tutorials, PRDs, or code samples for the project, when comparing agent memory approaches, or when positioning graph-native memory against vector-only approaches — even if the user doesn't explicitly name the package. Does NOT handle GraphRAG pipelines — use neo4j-graphrag-skill./neo4j-aura-agent-skillManages Neo4j Aura Agents via the v2beta1 REST API — create, list, get, update, delete, and invoke Aura agents backed by an AuraDB instance. Use when configuring Aura Agent tools (CypherTemplate, SimilaritySearch, Text2Cypher), setting system prompts, deploying agents to REST or MCP endpoints, invoking agents with natural language queries, or generating evaluation datasets (max 50 questions) for the Aura Agent evaluation feature. Covers OAuth2 auth, organization/project scoping, tool parameter schemas, and InvokeAgentResponse format. Does NOT cover AuraDB instance provisioning — use neo4j-aura-provisioning-skill. Does NOT cover vector index creation — use neo4j-vector-index-skill.npx claudepluginhub neo4j/agent-skills --plugin neo4j-skillsOther plugins' skills for the same job