Step-by-step tutorial

OKF tutorial: build your first knowledge bundle

This OKF tutorial builds one small knowledge bundle with `index.md`, three concept files, links, and a validation checklist. Start small before you convert a full site or documentation set.

What you will build

The final output is a website content bundle with one root index and three focused concept files. The same shape can later be adapted for APIs, documentation, data catalogs, and support playbooks.

Final bundle tree
bundle/
  index.md
  pages/
    home.md
    pricing.md
  support/
    contact.md

Before you start

Step 1: choose one knowledge scope

Start with a narrow scope. A good first bundle might cover five important pages, three API endpoints, or one support workflow.

Do not start by converting everything. OKF works best when each file has a clear concept boundary.

Step 2: create a folder

Create a bundle folder with an `index.md` file at the root. The index file helps humans and agents see what is available before opening individual concept files.

Step 3: write frontmatter first

Frontmatter is the structured block at the top of a Markdown file. In this guide, the validator checks `type`, `title`, `description`, and `tags` so your documents are useful for search and preview workflows.

Step 4: write a focused Markdown body

Step 5: validate and review

Paste each file into the OKF validator on this site. The validator runs in your browser, which means pasted content is not uploaded to this website.

After validation, review the file for accuracy. A passing file can still contain outdated or unsupported claims.

Step 6: consume OKF context in AI agent workflows

Once validated, an AI agent framework (such as LangChain or custom Python scripts) can read the YAML metadata to filter active concepts, check freshness timestamps (`stale_after`), and pass verified Markdown bodies into prompt context (`verified`).

Final output

A useful first bundle has a root index, one concept per file, canonical resource links, and enough body text for a reviewer to understand the source without guessing.

Example concept file
---
type: Website Page
title: Contact page
description: Explains how visitors can report corrections, outdated examples, and validator issues.
resource: https://openknowledgeformat.online/contact/
tags: [website, contact, corrections]
timestamp: 2026-06-21T00:00:00Z
---

# Purpose

This page gives readers a correction path for Open Knowledge Format Guide.

# Related concepts

- [Privacy policy](../pages/privacy.md)
- [Validator](../products/okf-validator.md)

Validation checklist

Review v0.2 trust fields

FAQ

Can I generate OKF from OpenAPI?

You can draft endpoint concept files from OpenAPI, but the business meaning, owners, examples, and warnings still need human review.

Do I need a database?

No. A first OKF bundle can be ordinary Markdown files in a folder, Git repo, zip archive, or static site.

What should I validate first?

Validate the frontmatter and required guide fields first, then review the actual claims for accuracy.

Source boundary

This guide is unofficial. It uses public draft references for orientation and adds practical examples for learning.