schema-sidecar
Theme
Text size
GitHub Menu

The schema The bundle Architecture Glossary Quick start

schema-sidecar#

Validate Licence OpenSSF Scorecard KTL scorecard

schema-sidecar gives any repository a LinkML data model: one schema file from which JSON Schema, Pydantic models, OWL, SHACL, TypeScript and a documentation site are generated. Two Agent Skills do the work, on the project shape that linkml-project-copier defines.

Documentation is at w3id.org/lmodel/schema-sidecar.

Get started#

Install the skills:

gh skill install lmodel/schema-sidecar --all --scope user

Or from PyPI: uvx schema-sidecar skills install --scope user.

Then open your agent in a repository and say, in turn:

  1. “Set up a LinkML schema project here.”
  2. “Model this repository’s data in the schema.”
  3. “Lint, generate and test the schema.”

The install page gives the other ways to install, and running the scripts without an agent gives the commands for a person at a shell.

Only want to ask? Install ktl-docent into any agent you use, by a route from the install page, and ask it about this project. It answers from the bundle and says how far each answer has been checked.

Agents: if .lokf/knowledge/index.md exists, read it first. llms.txt says how to weigh it.

The two skills#

SkillWhat it doesRuns
linkml-sidecarInstalls the project from linkml-project-copier at a verified pin, around a dummy schema or a schema the repository already holds, and repairs a file it ownsonce
linkml-authorTurns the dummy into the repository’s model, and keeps any LinkML schema linted, generated, documented and testedoften

Where the project goes#

The repositoryThe projectThe schema
empty, or a folder with no git yetat the root: the repository is the schema projectsrc/<slug>/schema/
a codebasea hidden .linkml/ sidecar beside the code, outside its build, with a linkml_schema link to the schema.linkml/src/<slug>/schema/
a schema but no projecta sidecar around that schema, which stays where it iswhere it is

The architecture says who owns which file, and why the template is trusted only at its pin.

Beside a knowledge bundle#

A Knowledge Trust Ladder (KTL) bundle in .lokf/ belongs to KTL, and neither skill writes there. A bundle takes a published release of the schema, which ktl-librarian adapts into the bundle’s vocabulary.