# AI use cases for Ksor (panaversity/ksor)

Repo: [panaversity/ksor](https://github.com/panaversity/ksor) | Use cases: 3 | Page: https://dedupedai.com/use-cases/panaversity-ksor/

KSoR is an open-source TypeScript SDK for building a governed, authoritative knowledge record that humans and AI agents can operate from.

This file holds every use case of this repo. Each one starts with a "## " heading and ends with its URL.

- Stand up a governed knowledge site from a fresh project: https://dedupedai.com/use-cases/panaversity-ksor/stand-up-a-governed-knowledge-site/
- Serve a governed record to AI agents with a refusal floor: https://dedupedai.com/use-cases/panaversity-ksor/serve-governed-knowledge-to-ai-agents/
- Govern a team's policy or course content with human approval: https://dedupedai.com/use-cases/panaversity-ksor/govern-team-policy-with-human-approval/

## How to stand up a governed knowledge site from a fresh project with Ksor

Repo: [panaversity/ksor](https://github.com/panaversity/ksor) | Difficulty: Intermediate | Time: 15 minutes | Basis: From the README

Create a working KSoR project with starter documents and build it locally in minutes.

**Who it is for:** A developer or team lead who wants one authoritative knowledge base for a policy set or course and has only Node installed.

**The problem:** Policies, procedures, or curriculum are spread across wikis, PDFs, and chat, so nobody can say which version is current.

**The outcome:** A running local site reading Markdown from knowledge/, with a build that reports which documents are admitted to a machine surface.

### Steps

1. Install Node 24 or newer from https://nodejs.org/en/download.
2. `npx @panaversity/ksor@latest init my-knowledge-sor`
3. `cd my-knowledge-sor && npm install && npm run dev`
4. Open `http://localhost:3000` and edit the Markdown files in `knowledge/`; the site reloads as you edit.
5. In a pnpm project, run `pnpm exec ksor build` and check the document and admitted counts.

### Prompt to paste into your agent

```text
Use the panaversity/ksor repo to create a new project named <project-name> with `npx @panaversity/ksor@latest init <project-name>`, then run its build. Report the build line that shows documents and admitted documents, and confirm that any document with status draft is not counted as admitted.
```

### Caveat

The five starter documents are KSoR's own samples and should be deleted as your real knowledge arrives.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/panaversity-ksor/stand-up-a-governed-knowledge-site/

## How to serve a governed record to AI agents with a refusal floor with Ksor

Repo: [panaversity/ksor](https://github.com/panaversity/ksor) | Difficulty: Advanced | Time: 60 minutes | Basis: From the README

Provision a Postgres-backed serve path so agents query the record and abstain when it does not answer.

**Who it is for:** A platform engineer whose AI agents must answer from approved institutional knowledge and must refuse when the record is silent.

**The problem:** Agents retrieve plausible but conflicting text, so answers cannot be traced to an authoritative source or refused when knowledge is missing.

**The outcome:** A serving setup where agent answers name the document and publication they came from, and the agent abstains when the record does not cover the question.

### Steps

1. Add a Postgres database and an embedding API key, following the Serve to AI Agents section of the README.
2. `pnpm provision`
3. `pnpm refresh`
4. `pnpm serve`
5. Follow docs/tutorials/04-serve-it.md to measure where the record declines and test an out-of-scope question.

### Prompt to paste into your agent

```text
In the panaversity/ksor repo, run `pnpm provision` once, then `pnpm refresh`, then `pnpm serve` in <project-directory>. Report the output of each command. Verify that an agent question on <topic> returns an answer that names its source document and publication, or an abstention when the record has no coverage.
```

### Caveat

The README gives the three commands but leaves database and embedding key setup to the Serve to AI Agents section, so read that section before running them.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/panaversity-ksor/serve-governed-knowledge-to-ai-agents/

## How to govern a team's policy or course content with human approval with Ksor

Repo: [panaversity/ksor](https://github.com/panaversity/ksor) | Difficulty: Intermediate | Time: 30 minutes | Basis: From the README

Write your own knowledge as Markdown, keep it as draft, and publish only what a person approves.

**Who it is for:** A policy owner or instructor who wants AI-facing knowledge to reflect only what the institution has approved.

**The problem:** Drafts and unreviewed notes get picked up by AI tools, so agents answer from text no one accountable has approved.

**The outcome:** Your own document replaces the starter samples, stays out of machine surfaces while in draft, and is admitted only after approval.

### Steps

1. `npx @panaversity/ksor@latest init my-knowledge-sor`
2. `cd my-knowledge-sor && npm install && npm run dev`
3. Replace the starter files in `knowledge/` with your own Markdown document, which begins as a draft.
4. `pnpm exec ksor build`
5. Follow docs/tutorials/03-governance-in-practice.md to get the document approved, then run `pnpm exec ksor build` again and confirm the admitted count moves.

### Prompt to paste into your agent

```text
Using the panaversity/ksor repo in <project-directory>, add my policy document at <path-to-document> to knowledge/ as a draft, then run the build. Report the document and admitted counts before and after approval, and verify that the draft is excluded from machine surfaces until approved.
```

### Caveat

The README describes approval in general terms, so the exact approval steps are only in docs/tutorials/03-governance-in-practice.md, which you should read before relying on them.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/panaversity-ksor/govern-team-policy-with-human-approval/
