> ## Documentation Index
> Fetch the complete documentation index at: https://docs.encoreos.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Knowledge Base

> Manage organization knowledge articles with create, publish, archive, and bulk operations; create and edit articles with rich-text content and publish controls.

Knowledge Base is the admin page at `/settings/knowledge-base` where authorized users manage the organization's library of knowledge articles. Articles can be created, searched, filtered by status and category, published, archived, and deleted.

## Overview

The page renders a searchable, filterable card grid of `KnowledgeArticle` records fetched via `useKnowledgeArticles`. Search is debounced and URL-synced. Filters include status (`KnowledgeArticleStatus`) and category (`KnowledgeArticleCategory`). Bulk operations (publish, archive, delete) are available via `useBulkKnowledgeOperations`. Individual articles support publish, archive, and delete. Navigation to create and edit pages is provided.

The individual article editor is at `/settings/knowledge-base/:id`.

<Frame caption="The Knowledge Base admin list at `/settings/knowledge-base`, showing the seeded organization knowledge articles — the published “About Acme Recovery” org-profile narrative alongside its draft and in-review revisions.">
  <img src="https://mintcdn.com/encoreos/FHgwdEuPbyKq-W7P/images/pf/pf-61-knowledge-base-list.png?fit=max&auto=format&n=FHgwdEuPbyKq-W7P&q=85&s=7c6768fefb239d4ccbc8dcad6f0118e7" alt="Knowledge Base article list with the published About Acme Recovery org-profile article and its draft and in-review revisions" width="1440" height="900" data-path="images/pf/pf-61-knowledge-base-list.png" />
</Frame>

## Who it's for

Requires permission `pf.ai_skills.view`.

## Before you start

* You must hold `pf.ai_skills.view` to access this page.
* To create or publish articles, additional write permissions may apply (confirm with SME).

## Steps

1. Navigate to **Settings → Knowledge Base** (`/settings/knowledge-base`).
2. Use the search input to filter articles by title or content.
3. Use the **Status** and **Category** dropdowns to narrow results.
4. To create a new article, click **New Article**.
5. To publish a draft article, click the publish action on its card.
6. To archive an article, use the archive action.
7. For bulk operations, select multiple articles and choose a bulk action (publish, archive, or delete).

## Key concepts

**Knowledge article status** — values include draft, published, and archived (from `STATUS_OPTIONS`). Only published articles are available to AI skills.

**Category** — articles are tagged with a category from `CATEGORY_OPTIONS`. Confirm values with an SME.

## Creating or editing an article

The Edit Article page (`/settings/knowledge-base/:id`) is the editor for knowledge base articles, supporting both creation (via the `new` ID) and modification of existing articles. Requires `pf.ai_skills.view`.

The page reads `:id` from `useParams` — when `id === 'new'`, it operates in create mode (no pre-fetch); otherwise it calls `useKnowledgeArticle` to load the existing article. Loading state shows a full-page skeleton. Mutations are handled by `useCreateKnowledgeArticle`, `useUpdateKnowledgeArticle`, and `usePublishKnowledgeArticle`. The editor component `KnowledgeArticleEditor` is responsible for the form UI and exposes save, publish, and cancel actions. On save in create mode, the new article's ID is returned and navigation goes to the edit URL for that article. On cancel, the editor navigates back to the knowledge base list.

<Steps>
  <Step title="Create a new article">
    Navigate to `/settings/knowledge-base/new`. The editor opens with empty fields.
  </Step>

  <Step title="Edit an existing article">
    Navigate to `/settings/knowledge-base/:id`. The editor pre-fills with the article's existing content.
  </Step>

  <Step title="Fill in the article content">
    Use `KnowledgeArticleEditor` to write the article title and body content.
  </Step>

  <Step title="Save the article">
    Click **Save** to persist the draft. In create mode, the URL updates to the new article's edit URL.
  </Step>

  <Step title="Publish the article">
    Click **Publish** to make the article available. This calls `usePublishKnowledgeArticle`.
  </Step>

  <Step title="Cancel editing">
    Click **Cancel** to discard unsaved changes and return to the knowledge base list.
  </Step>
</Steps>

### Organization profile article

The `org_profile` category holds exactly one published **"About \<Org>"** narrative per organization — the canonical org-context article the AI onboarding wizard authors, an admin publishes, and every AI skill retrieves via RAG. Publishing a new revision auto-archives the previous one (a server-side supersede trigger plus a partial unique index enforce the singleton).

<Frame caption="The single published + indexed org_profile narrative (“About Acme Recovery”) open in the article editor — the canonical org-context article that feeds every AI skill via RAG.">
  <img src="https://mintcdn.com/encoreos/FHgwdEuPbyKq-W7P/images/pf/pf-61-en-01-org-profile-article.png?fit=max&auto=format&n=FHgwdEuPbyKq-W7P&q=85&s=63becd37a82b78d7611323c146e559b2" alt="Edit Article editor showing the published About Acme Recovery org-profile narrative with its title, summary, and content fields" width="1440" height="900" data-path="images/pf/pf-61-en-01-org-profile-article.png" />
</Frame>

## Related

<Columns cols={2}>
  <Card title="Platform Foundation" icon="layer-group" href="/pf/overview">
    Platform Foundation overview.
  </Card>

  <Card title="Governance & parity" icon="scale-balanced" href="/governance/index">
    Documentation coverage and governance.
  </Card>
</Columns>

<Note>
  This page documents shipped product behavior. It is not medical, legal, or
  billing advice. Verify against your organization's policies and applicable
  regulations before using it for clinical, compliance, or billing decisions.
  Protected health information (PHI) shown in the product is governed by your
  tenant's access controls and is never exposed in this documentation.
</Note>

<Accordion title="Documentation sources">
  * src/routes/platform.tsx
  * src/platform/knowledge/pages/KnowledgeBaseListPage.tsx
  * src/platform/knowledge/hooks/use-knowledge-articles.ts
  * src/platform/knowledge/pages/KnowledgeArticleEditPage.tsx
</Accordion>
