The okb command guides you through the eight steps of the method. You run each command, okb refuses common mistakes as you make them, and okb validate checks the result against the rules. Use this path if you like a terminal and want to see every change as you make it.
What you need#
Install okb first. The Installation page has the steps, and okb version confirms it works.
Pick a way in#
- Quickstart. A tiny coffee menu, one rule broken on purpose. Start here if you want to feel the loop before you commit to a subject.
- Wine tutorial. Eight pages that build the wine ontology from Ontology Development 101, with every command and its real output.
- Espresso tutorial. The same eight steps on a café menu, where you decide whether something is a class or an instance.
After one of those, build your own subject with the same commands.
The loop#
Every step works the same way. Ask okb where you are, do the step, check it, then move on:
okb status
okb step
okb validate
okb step next
okb statusshows your step and what’s left in it.okb stepprints the guide for the current step: its goal, its questions and a wine example.okb validatelists errors (fix them), warnings (fix them or record why not) and hints. Add--allto see the findings for later steps too.okb step nextmoves on when you’re ready.
When a finding isn’t clear, okb explain <rule-id> gives it in plain words with the source quote. See How do I read and fix a finding?.
The commands, by step#
| Step | You do | Main commands |
|---|---|---|
| 1. Scope | State the purpose and the questions to answer. | okb scope, okb cq add |
| 2. Reuse | Check for a vocabulary you could use. | okb reuse add, okb reuse none |
| 3. Terms | List the words your subject uses. | okb term add |
| 4. Classes | Name the kinds of things and how they nest. | okb class add, okb class disjoint, okb tree |
| 5. Slots | Say what you can state about each kind. | okb property add, okb relationship add |
| 6. Facets | Limit the values. | okb slot set, okb class fix, okb relationship inverse |
| 7. Instances | Add real examples. | okb instance add, okb instance set |
| 8. Review | Check it against your questions. | okb cq link, okb validate --all, okb review |
Every command and flag is in the CLI reference, and the cheat sheet fits on one page. Add --json to most commands for machine-readable output.
Next#
Run the review when you reach step 8, and export when you want the data in a graph database.