Skip to content

KOS — FRD: Chat UI & Connectors

KOS — FRD: Chat UI & Connectors

Parent: KOS PRD
Owner: Digital Office
Status: Phase 1b


Chat UI

Conversational interface built on Chainlit. Always uses synthesised mode.

FR-UI-01: Two-Phase Response

  1. Phase 1 (fast): Raw retrieval completes. Citations displayed immediately.

  2. Phase 2 (async): LLM synthesis streams. Prose answer replaces/supplements citations.

FR-UI-02: Authentication

Password-protected via KOS_CHAT_PASSWORD. Single shared password for the team.

FR-UI-03: Multilingual

The Ollama LLM understands Urdu, Bengali, Arabic, and English. No explicit translation step required for queries.

FR-UI-04: Model Warmup

On session start, the Ollama model is preloaded to avoid cold-start latency on first query.

FR-UI-05: Wiki Status

The welcome message indicates whether a compiled wiki is available and how many pages it contains.


Connector Summary

Connector Protocol Auth Documents Ingested
Confluence REST API v2 Basic Wiki pages, ADRs, standards, schemas, playbooks
Slack Conversations API Bot token Messages, threads
Bitbucket REST API 2.0 Basic READMEs
Git repos Filesystem None Standards, ADRs, schemas, OpenAPI specs
Filesystem Filesystem None Markdown, PDFs, SurrealDB schemas
Jira REST API v3 Basic Issues, epics, stories
SharePoint/OneDrive Microsoft Graph OAuth2 client credentials Documents, wiki pages

Wiki Compilation

The WikiCompiler generates a static markdown knowledge base from graph facts.

FR-WIKI-01: Output Structure

wiki/
  jurisdictions/{slug}.md
  systems/{slug}.md
  standards/{slug}.md

FR-WIKI-02: Authority Badges

Each page renders authority badges (canonical / approved / documented / discussion).

FR-WIKI-03: Trigger

Compilation is batch — not incremental. Run: uv run python -m kos.compilation

FR-WIKI-04: MkDocs Integration

Compiler generates mkdocs.yml for a browsable MkDocs Material site.