# OKR for Public Sector

> Turn strategy into measurable goals. An AI coach that learns your organization, tracks progress across cycles, and guides you from first OKR to organizational mastery.

> **Solo-maintained, fork-and-own.** This plugin is a starting point, not a vendor product. Issues are welcome as signals; pull requests are not accepted. See [GOVERNANCE.md](GOVERNANCE.md) for the full model and what upstream provides.

*AI-generated: all code produced by Claude Code through dialog-driven development. [Full disclosure →](../../README.md#ai-generated-code-disclosure)*

![Version](https://img.shields.io/badge/version-1.3.0-blue)
![Platform](https://img.shields.io/badge/platform-Claude_Code_Plugin-purple)
![Agents](https://img.shields.io/badge/agents-7-orange)
![Commands](https://img.shields.io/badge/commands-10-blue)
![Hooks](https://img.shields.io/badge/hooks-4-green)
![References](https://img.shields.io/badge/references-16-yellow)
![License](https://img.shields.io/badge/license-MIT-lightgrey)

---

## Why This Exists

Every organization has a strategy. Few manage to turn it into goals that teams actually work toward.

OKR (Objectives and Key Results) is a proven framework for that translation — used by Google, Intel, and increasingly by Norwegian public sector organizations like NAV, FINN.no, and Direktoratet for digital tjenesteutvikling. But adopting OKR is hard. The methodology sounds simple ("write inspiring goals with measurable results") until you try it. Then you hit real questions:

- *How do we connect our OKR to the goals in our tildelingsbrev?*
- *What's a good Key Result vs. just an activity disguised as one?*
- *How do we handle it when political priorities shift mid-cycle?*
- *Are we actually getting better at this, or just going through the motions?*

This plugin is an AI coach that helps with all of these. It's built specifically for Norwegian public sector — 4-month tertial cycles, DFO's "mål- og resultatstyring" framework, tillitsvalgt involvement, and the governance chain from Stortingsmelding to team OKR.

### What makes it different from a methodology guide?

A methodology guide explains OKR theory. This plugin *knows your organization*.

After a one-time onboarding conversation, it remembers your maturity level, your strategic documents, your current OKR, and your cultural challenges. Every interaction builds on that knowledge. When you ask it to write new OKR, it already knows what your organization is trying to achieve. When you check quality, it checks alignment against your actual strategy — not a generic rubric.

Over time, it tracks how your OKR practice evolves. It spots recurring mistakes, shows score trends, and coaches you based on where you are in the cycle. Early in the cycle? Focus on alignment. Midway? Time for a progress check. Near the end? Let's prepare the retrospective.

---

## What It Does

### From Strategy to OKR

The core workflow: take your strategic goals (from virksomhetsplan, tildelingsbrev, etatsstrategi, or any strategic document) and transform them into well-structured OKR.

```
> /okr:skriv We want to make the application process faster for citizens
```

The plugin guides you through writing an inspiring Objective and measurable Key Results, calibrating ambition, and checking alignment against your organization's strategic direction.

### Quality That Goes Beyond Spell-Check

```
> /okr:kvalitet
```

Checks your OKR against 19 named antipatterns (like "activity disguised as a Key Result", "sandbagging", or "set-and-forget") and scores quality across multiple dimensions. If your OKR has issues, you get concrete improvement suggestions — not just "try harder."

### Strategy Alignment

```
> /okr:kaskade
```

Cascades OKR from organizational level down to teams. Shows which strategic goals have team support and which are orphaned. If you've stored your org-level OKR, it reads them automatically.

### Gap Analysis

```
> /okr:gap
```

Compares your strategic documents (tildelingsbrev, virksomhetsplan) against your current OKR and produces a coverage matrix: which requirements are fully covered, which are partially covered, and which are completely missing. For each gap, it suggests OKR formulations.

### Progress Tracking

```
> /okr:sporing
```

Calculates scores (0.0–1.0), assesses confidence levels, generates forecasts, and flags Key Results that are at risk. If you use Linear, it can sync status there too.

### Cross-Cycle Learning

```
> /okr:analyse
```

After your first completed cycle, this is where the real value begins. Reads your archived cycles and shows:
- **Score trends** — are you improving? Visualized with charts.
- **Recurring antipatterns** — the same mistakes across cycles get flagged explicitly.
- **Alignment progression** — is your team coverage of org goals getting better?

### Proactive Coaching

You don't have to remember to check in. When you start a session, the plugin automatically tells you where you are in the cycle and what to focus on:

> *"OKR coaching: Week 12 of 16 in T1-2026. Approaching cycle end — focus on final scoring and retrospective preparation. 2 KR flagged as at-risk in last status update."*

### Meetings and Facilitation

```
> /okr:moter
```

Generates tailored agendas for OKR workshops, check-ins, reviews, and 1:1 conversations using the CFR (Conversations, Feedback, Recognition) framework — adapted for public sector where bonuses aren't an option.

### Adoption and Change Management

```
> /okr:innforing
```

Planning to introduce OKR in your organization? Get a phased rollout plan with resistance-handling strategies, maturity assessment, and guidance on involving tillitsvalgte — because in Norwegian public sector, change management without union involvement doesn't work.

### Governance and Compliance

```
> /okr:governance
```

Translate tildelingsbrev requirements into OKR. Map the governance chain (Stortingsmelding → tildelingsbrev → etatsstrategi → OKR). Verify that your OKR documentation meets Riksrevisjon standards.

---

## Getting Started

### Install

Add to your Claude Code plugin configuration:

```json
{
  "enabledPlugins": {
    "okr@ktg-plugin-marketplace": true
  }
}
```

### First Conversation

```
> /okr:oppsett mvp
```

Six questions, five minutes. The plugin learns your organization, maturity level, tools, and cycle phase. From that point on, every command adapts to your context.

Want the full experience? `/okr:oppsett full` runs a deeper interview (15-20 minutes) that also captures your strategic context, cultural challenges, and organizational structure.

### Typical Workflow

**Starting fresh:**
```
/okr:oppsett full       # One-time setup
/okr:skriv              # Write your first OKR
/okr:kvalitet           # Quality check
/okr:kaskade            # Align with org goals
```

**During a cycle:**
```
/okr:sporing            # Update progress
/okr:moter              # Prepare check-in meeting
```

**End of cycle:**
```
/okr:oppsett arkiver    # Archive with retrospective
/okr:analyse            # See how you're trending
/okr:skriv              # Start the next cycle
```

---

## Built for Norwegian Public Sector

### What's different about OKR in offentlig sektor?

| Challenge | How the plugin helps |
|-----------|---------------------|
| 4-month tertial cycles (not quarterly) | Built-in tertial support with correct week counting and phase detection |
| Tildelingsbrev drives priorities | `/okr:governance` and `/okr:gap` translate and check coverage |
| DFO uses different terminology | Built-in mapping between "mål- og resultatstyring" and OKR concepts |
| Riksrevisjonen requires documentation | Audit-ready format with baseline, target, data source per KR |
| No performance bonuses | CFR framework designed for recognition without financial incentives |
| Tillitsvalgte must be involved | Guidance on drøftingsplikt, transparent KR, and union involvement |
| Consensus culture | Advice calibrated for organizations where stretch goals feel risky |
| Political priorities can shift mid-cycle | Strategies for handling mid-cycle mandate changes |

### The governance chain

```
Stortingsmelding / NTP
        |
Tildelingsbrev fra departement
        |
Etatsstrategi / Virksomhetsplan
        |
Org-level OKR (annual, strategic)
        |
Cycle OKR (tertial, tactical)
        |
Team OKR
```

The plugin understands this hierarchy and helps you maintain alignment at every level.

---

## Under the Hood

### Agents

7 specialized agents activate automatically:

| Agent | Role |
|-------|------|
| kvalitetssjekker | Score quality, detect antipatterns, check alignment |
| kaskadebygger | Build cascades between organizational levels |
| fremdriftssporer | Calculate scores, forecast completion, flag risks |
| møtefasilitator | Generate meeting agendas and facilitation materials |
| styringsrådgiver | Governance analysis, tildelingsbrev translation, audit compliance |
| gapanalytiker | Coverage matrix between strategic documents and OKR |
| trendanalytiker | Cross-cycle pattern analysis with trend visualization |

### Hooks

| Event | What it does |
|-------|-------------|
| SessionStart | Proactive coaching — tells you where you are in the cycle and what to focus on |
| UserPromptSubmit | Injects your organization profile and available context files into every interaction |
| PreCompact | Preserves OKR draft state if the conversation gets long |
| Stop | Reminds you to save work to your tracking system |

### Knowledge Base

16 reference files covering OKR methodology, Norwegian public sector governance, antipatterns, meeting guides, metrics library, integration patterns, and more. The plugin reads only what's relevant to each interaction — never the whole library at once.

### Persistent Context

```
.claude/
  okr.local.md                    # Your organizational profile
  okr/
    strategisk-kontekst/           # Strategic documents you provide
    syklus/T1-2026/                # Active cycle OKR and status
    historikk/                     # Archived cycles with retrospectives
    dokumenter/                    # Any other relevant documents
```

---

## Limitations

- Designed for Norwegian public sector — may not fit other contexts without adaptation
- Not yet tested in a real multi-cycle OKR program
- Linear is the only supported tracking integration
- Norwegian language for all user-facing interactions

---

## Version History

| Version | Date | Highlights |
|---------|------|------------|
| **1.3.0** | 2026-04-08 | Gap analysis, cross-cycle analytics with Mermaid visualizations, proactive SessionStart coaching |
| **1.1.0** | 2026-04-08 | Persistent context, deep onboarding, context-aware commands, cycle archival |
| **1.0.0** | 2026-04-08 | Architecture overhaul, self-contained commands, hooks, marketplace-ready |
| 0.5.0 | 2026-02-07 | First formal version |

See [CHANGELOG.md](CHANGELOG.md) for full details.

---

## License

[MIT](LICENSE)
