Generated banner for Open Knowledge Format for Crossplane v2
Generated logo for Open Knowledge Format for Crossplane v2

Open Knowledge Format for Crossplane v2

LLM wiki kit

First committed by jkroepke

Published in jkroepke/okf-crossplane-v2. Publisher page

37 GitHub stars

What it is

LLM-wiki in OKF (Open Knowledge Format) for Crossplane v2
— the description by jkroepke

AutoGineer overview, from the brain’s own files

The okf-crossplane-v2 repository provides a versioned, source-backed knowledge catalog designed to help AI agents and developers navigate the Crossplane v2 ecosystem. It aggregates information from Go API types, CRDs, package metadata, and documentation into a structured format. By utilizing the Open Knowledge Format (OKF), it enables agents to perform precise lookups on providers, composition functions, and API definitions. The project includes a dedicated MCP server that allows agents to query live repository data, such as CRD definitions, versioning, and examples, ensuring that the information retrieved is grounded in specific, versioned source code.

How it works

Memory model: LLM wiki

AutoGineer overview, from the brain’s own files

The system organizes technical knowledge into a catalog of Markdown files stored in the catalog folder. These files contain OKF metadata and provenance links. An MCP server, which can be self-hosted or used via a public endpoint, ingests this catalog into a DuckDB instance. Agents interact with this data through specific tools that resolve provider versions, search CRDs, and retrieve documentation or examples. The system relies on specialized researcher agents defined in the .agents folder to maintain and validate the knowledge base, ensuring that facts are linked to stable source code and documentation.

Folders
FolderRoleFiles
.codexagent-config25
.githubagent-config2
skillsagent-instructions1
.agentsfolder37
.codex-pluginfolder1
.okffolder2
.pifolder27
.pluginfolder1
catalogfolder120
mcpfolder12

Requirements

Apps: Docker

API keys (by name): GITHUB_TOKEN

Works with: Claude Code, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Amp, Cline, JetBrains Junie, Devin (ex-Windsurf)

Set it up

  1. Download the brain as a ZIP and unzip it where you keep your notes or project: https://mp-staging.autogineer.com/agent-brains/jkroepke/okf-crossplane-v2/download
  2. Point Claude Code at .codex-plugin/plugin.json: it does not read that file on its own.

  3. cd okf-crossplane-v2 && claude

  4. AutoGineer scanned these files at commit df24ac2.

  5. Add crossplane-v2-okf to .mcp.json:

    {
      "mcpServers": {
        "crossplane-v2-okf": {
          "type": "http",
          "url": "https://crossplane.mcp.jkroepke.de/mcp"
        }
      }
    }
    
  6. Or add it with the Claude Code CLI:

    claude mcp add --transport http crossplane-v2-okf https://crossplane.mcp.jkroepke.de/mcp
  7. Your data is sent to crossplane.mcp.jkroepke.de.

  8. First committed by jkroepke. Published in jkroepke/okf-crossplane-v2. Licence: Apache License 2.0.

Usage

AutoGineer overview, from the brain’s own files

  • Querying CRD definitions for specific Crossplane providers
  • Retrieving versioned examples for composition functions
  • Resolving stable provider versions and their associated documentation
  • Integrating Crossplane knowledge into AI agent workflows via MCP
“Find the latest version of the AWS provider and list its CRDs.”
The agent uses the get_versions and provider_crd_search tools to return the canonical repository name and a list of available CRDs for the specified provider.
“Show me the definition for the S3Bucket CRD in the latest AWS provider.”
The agent retrieves the YAML definition of the requested CRD using the provider_crd_get_definition tool, ensuring the output is token-efficient.

Documentation by jkroepke

Image: CI Image: GitHub license Image: GitHub Repo stars Image: BundleDex

Open Knowledge Format for Crossplane v2

This repository provides a structured knowledge catalog for the Crossplane v2 ecosystem using Open Knowledge Format v0.2.

The goal is to make Crossplane concepts, APIs, providers, composition functions, documentation, and practical examples easier to discover and understand. The catalog is designed for both humans and knowledge-aware tools.

Installation

WARNING
The public MCP server is a temporary early-access service for early adopters. Its availability is not guaranteed, and it may change or be removed without notice. It is intended to bridge the current tooling gap until the OKF ecosystem provides practical, end-user-friendly solutions that run locally. For reliable or production use, self-host the included container.

Install the companion skill and hosted OKF-aware MCP server together as a plugin for every detected supported agent:

npx plugins add jkroepke/okf-crossplane-v2

Pass --target codex to install only in Codex. Restart the selected agents after installation.

Alternatively, install the hosted OKF-aware MCP server globally:

npx add-mcp \
  https://crossplane.mcp.jkroepke.de/mcp \
  --name crossplane-v2-okf \
  --global

Then install the companion skill so the agent prefers this bundle over generic documentation providers for Crossplane v2 questions:

npx skills add jkroepke/okf-crossplane-v2 \
  --skill crossplane-v2-okf \
  --global

Both standalone installers detect supported agents and ask where the integration should be installed. Restart the selected agent after installation.

The public MCP health endpoint is available at https://crossplane.mcp.jkroepke.de/healthz.

Self-hosting the MCP server

The included container fetches this repository, ingests catalog/ into a DuckDB catalog, and serves the okf-mcp tools over Streamable HTTP.

docker compose up --build --detach

To authenticate the server's GitHub requests, export GITHUB_TOKEN before starting the container. The token is optional.

The local MCP endpoint is http://127.0.0.1:8000/mcp. Put it behind a TLS reverse proxy for crossplane.mcp.jkroepke.de.

The catalog is refreshed at container startup. If fetching or ingestion fails and a previous catalog exists in the volume, the server continues with that last successful catalog.

The MCP tools are read-only, but the public endpoint has no application-level authentication. Apply request limits and access controls at the reverse proxy when required.

Crossplane package tools

The server adds these tools backed by OSS GitHub repositories:

  • get_versions(name) resolves an OSS provider or function repository and returns its canonical repository name, versions.latest, a compact list of recent stable versions, and tag counts. Pass the returned provider name to the CRD tools.

  • provider_crd_search(provider_name, provider_version, crd_search_term) searches CRDs in one explicit provider package version. The search term supports case-insensitive shell-style wildcards.

  • provider_crd_get_definition(provider_name, provider_version, crd_name, path?) returns the complete CRD definition as token-efficient YAML. Use a dotted path such as .spec or .spec.versions[0] to return only a subtree.

  • provider_crd_get_examples(provider_name, provider_version, crd_name) returns GitHub repository paths for generated and handwritten examples. Without an API version, it selects the latest served CRD API version, for example examples-generated/namespaced/ec2/v1beta2/route.yaml.

  • provider_crd_get_terraform_docs(provider_name, provider_version, crd_name) returns the Terraform provider repository, version, and documentation path. It reads the Crossplane provider Makefile and the generated controller mapping instead of inferring the Terraform resource name.

crd_name accepts a Kind, group/Kind, group/version/Kind, or a YAML fragment containing apiVersion and kind.

Use an OSS GitHub repository name such as crossplane-contrib/provider-upjet-aws or crossplane-contrib/function-go-templating. A small set of historical package aliases is mapped to their known OSS source repositories; unmapped upbound/... names are rejected rather than guessed.

The CRD tools require an explicit provider version. The value latest is also supported and selects the highest stable semantic-version Git tag. Self-hosted deployments need outbound HTTPS access to GITHUB_API_URL and GITHUB_RAW_URL.

Successful remote fetches are cached in memory. Git tag listings use the configurable short FETCH_CACHE_TTL_SECONDS (default: 300 seconds); CRDs, definitions, examples, and Terraform metadata resolved at immutable Git tags are cached for 30 days. FETCH_CACHE_MAX_ENTRIES (default: 512) bounds memory use.

Why this repository exists

Crossplane knowledge is distributed across many repositories and kinds of sources:

  • Go API types and runtime implementations

  • CustomResourceDefinitions and OpenAPI schemas

  • package metadata

  • tests and executable examples

  • official Crossplane documentation

  • community implementations and real-world composition examples

Upjet-based providers add another layer. Their Crossplane managed resources are generated from Terraform provider resources, while the Terraform documentation often contains more details about the underlying cloud APIs and configuration fields.

This repository connects these sources in one versioned catalog without replacing the original documentation.

Knowledge structure

Knowledge is stored as small Markdown documents under catalog/. Each document represents an independently useful concept and includes OKF metadata, provenance in sources, keyed claim footnotes, and relationships to related concepts.

Repository validation pins okf-ingest 0.11.0, which adds OKF v0.2 core support, including generated.at freshness fallback and preservation of the new frontmatter families (upstream support commit).

If the task is to build a Crossplane v2 Composition, start with the Composition developer route. It routes agents through separate API/provider, pipeline/security, and testing/packaging concepts without pretending that provider-specific schemas or credentials are universal.

The catalog is intended to be:

  • Source-backed: important statements link to source code, schemas, tests, examples, or official documentation.

  • Version-aware: sources are tied to specific repository revisions.

  • Navigable: overview documents connect related concepts without requiring readers to know the source repository layout.

  • Incremental: providers, functions, services, documentation areas, and example repositories can be added in focused batches.

License

This project is licensed under the Apache License 2.0.

catalog/core/managed-resource-references-and-provider-config.md


type: concept title: Managed resource references and ProviderConfig description: Provider-generated cross-resource references, typed provider configuration selection, usage tracking, and connection detail publication. resource: https://docs.crossplane.io/v2.3/managed-resources/managed-resources/ tags: [crossplane, core, managed-resources, references, providerconfig] generated: { by: "process:okf-v0.2-migration", at: "2026-08-20T06:45:13Z" } sources:


References and selectors

A Provider may generate a literal external-identifier field plus *Ref and *Selector alternatives. A reference uses a Kubernetes MR name; selectors may match labels or matchControllerRef to select a resource controlled by the same object, such as the same XR.[^documented-references-and-selectors]

Providers define each MR's available settings, so *Ref and *Selector are not universal alternatives for every identifier field. Prefer generated references when the selected Provider CRD exposes them, but inspect that exact Provider release's CRD and generated controller/schema before depending on a field such as vpcIdRef or vpcIdSelector.[^documented-references-and-selectors]

When a concrete MR implements generated reference resolution, the runtime calls it before external reconciliation. It server-side applies the fields changed by the Provider implementation with force ownership under the dedicated managed.crossplane.io/api-simple-reference-resolver field manager.[^generated-reference-resolution-and-field-owner][^field-manager-constant] Target kinds, readiness rules, selectors, extractors, and assigned fields remain provider-defined.

Composition fallback and field ownership

When a required relationship has no generated reference field, a Composition can explicitly place the prerequisite resource's observed identifier into the dependent resource's desired input. Composition functions receive the observed composed resources; the documented Patch and Transform pattern copies a status.atProvider.id value into composition environment data for a later resource.[^composition-observed-state-and-status-to-environment-example][^observed-identifier-environment-example] Treat this as a provider-specific composition pattern, not a universal fallback: verify the exact observed field, its readiness condition, and the dependent input field in the selected Provider CRD.

Do not edit a generated literal field as though it were an independently owned configuration value. With the runtime's generic resolver pattern, a non-empty resolved literal is cached by default, while clearing it causes a later reconciliation to resolve it again unless the Provider chose a different implementation or policy.[^reference-resolver-literal-cache-and-re-resolution] The runtime proves this behavior only for MRs that implement generated resolution through that pattern; it does not prove that every Provider or *Ref/*Selector field will repopulate a particular literal such as forProvider.vpcId.[^generated-reference-resolution-and-field-owner][^field-manager-constant][^reference-resolver-literal-cache-and-re-resolution]

The dedicated server-side apply field owner explains why field ownership can be surprising when another client changes a resolved literal. It does not, by itself, establish a universal outcome for kubectl edit, client-side kubectl apply, or any specific Provider CRD. Verify those interactions using the selected Provider's controller and a managed-fields reproduction before relying on them operationally.[^generated-reference-resolution-and-field-owner][^field-manager-constant]

ProviderConfig

Modern MRs carry a typed providerConfigRef with name and kind. ProviderConfig selects configuration and credentials, but authentication fields and Secret layouts are provider-specific.[^typed-providerconfig-reference-contract]

Usage tracking applies a ProviderConfigUsage keyed to the MR and typed configuration before attempting to use the configuration, so references remain tracked even when configuration is invalid.[^providerconfig-usage-tracking] Core supplies reusable usage contracts but Providers define the served ProviderConfig and usage CRDs.

The v2.3 docs conflict internally about the omitted-reference default. The released namespaced common type is authoritative: it defaults to ClusterProviderConfig/default.[^namespaced-common-spec-defaults]

Platform selection guidance

Set providerConfigRef explicitly in platform-owned MRs and Compositions. An omitted reference silently selects ClusterProviderConfig/default, which can hide the intended credential boundary.[^namespaced-common-spec-defaults]

Keep provider selection out of the XR API by default

An XRD defines the custom API that people use to create XRs; a Composition defines how that API creates managed resources.[^xr-custom-api-and-composition-responsibility-split] Do not expose a raw providerConfigRef (kind and name) in a human-orderable XR schema by default. It selects the credentials and configuration for a composed managed resource, so it is ordinarily a platform implementation detail. Set it in the Composition or in the Function-produced managed-resource template instead.[^managed-resource-providerconfig-selection]

This is a platform API design recommendation, not a Crossplane validation rule. Crossplane does not prohibit an XRD from carrying such fields. If a product deliberately allows an authorized tenant to choose between approved account or credential boundaries, expose a constrained, platform-owned selector—not an unrestricted ProviderConfig or ClusterProviderConfig name and kind. Define that selector's authorization, allowed values, and tenancy semantics for the selected provider rather than relying on implicit defaults.

The documented Function Patch and Transform resource base is a managed resource manifest and may set its spec.providerConfigRef there.[^function-patch-and-transform-managed-resource-base] This keeps a provider-specific kind, scope, and default out of the XR contract.

For tenant-local credentials, prefer the selected provider's namespaced modern ProviderConfig API. A namespaced ProviderConfig cannot be referenced across namespaces; use a ClusterProviderConfig only for an intentional shared or central account, with the least permissions required. This is platform security guidance: the actual ProviderConfig GVK and credential schema are provider-specific.[^typed-providerconfig-reference-contract]

For a central account, subscription, or project (for example, network, identity, or security) used by tenant compositions, choose deliberately:

  • a least-privileged ClusterProviderConfig for the shared account;

  • a tenant-local ProviderConfig for that account in every tenant namespace; or

  • a composition pattern that keeps the composed resource in the tenant namespace, subject to the namespaced-composition boundary.

The last option is constrained by namespaced composition boundaries; Crossplane does not permit a namespaced XR to compose a resource into another namespace.[^namespaced-composition-namespace-enforcement]

Connection details

writeConnectionSecretToRef selects a Secret destination for provider-published credentials or endpoints. Providers decide whether to publish and which keys exist. Alpha MRDs can document available keys, but the docs warn that many Providers do not populate that metadata.[^connection-secret-guidance][^mrd-metadata-limitation]

For a Crossplane managed resource, retrieve the selected provider release's resource-specific connection-detail implementation. An Upjet-based Crossplane provider may configure AdditionalConnectionDetailsFn; another provider may return typed managed.ConnectionDetails and pass it to its reconciler. The CRD destination schema and status.atProvider do not replace that provider-specific implementation evidence; see provider connection-detail source retrieval.

[^documented-references-and-selectors]: Documented references and selectors [^generated-reference-resolution-and-field-owner]: Generated reference resolution and field owner and field-manager constant [^field-manager-constant]: field-manager constant [^typed-providerconfig-reference-contract]: Typed ProviderConfig reference contract [^providerconfig-usage-tracking]: ProviderConfig usage tracking [^namespaced-common-spec-defaults]: Namespaced common spec defaults [^connection-secret-guidance]: Connection Secret guidance and MRD metadata limitation [^mrd-metadata-limitation]: MRD metadata limitation [^namespaced-composition-namespace-enforcement]: Namespaced composition namespace enforcement [^composition-observed-state-and-status-to-environment-example]: Composition observed state and status-to-environment example and observed identifier environment example [^observed-identifier-environment-example]: observed identifier environment example [^reference-resolver-literal-cache-and-re-resolution]: Reference resolver literal cache and re-resolution [^xr-custom-api-and-composition-responsibility-split]: XR custom-API and Composition responsibility split [^function-patch-and-transform-managed-resource-base]: Function Patch and Transform managed-resource base [^managed-resource-providerconfig-selection]: Managed-resource ProviderConfig selection

242 files

Advantages

  • Provides version-aware knowledge by linking facts to specific repository revisions. evidence: README.md
  • Connects distributed sources like Go APIs, CRDs, and documentation into a single navigable catalog. evidence: README.md

Limitations

  • The public MCP server is provided as an early-access service and is not intended for production use without self-hosting. evidence: README.md
  • Requires explicit provider versions for CRD tools, as it does not guess or infer versions automatically. evidence: README.md

Security

Risk level: Low risk

This brain runs

Agent instructions that run or fetch something (26)

  • .agents/agents/okf-function-go-templating-researcher/AGENT.md: Write for Crossplane users who want to install and use `function-go-templating` in Compositions.
  • .agents/agents/okf-reviewer/AGENT.md: `mise run lint` succeeds after the final fixes and before the root or parent agent creates a commit.
  • .agents/agents/okf-reviewer/AGENT.md: Run `mise run lint` as the final validation command.
  • .agents/skills/okf-open-knowledge-format/SKILL.md: If the user agrees to install:
  • .agents/skills/okf-open-knowledge-format/SKILL.md: uv tool install okflint
  • .agents/skills/okf-open-knowledge-format/SKILL.md: pip install okflint
  • .agents/skills/okf-open-knowledge-format/SKILL.md: kcmd push --dry-run
  • .agents/skills/okf-updates/SKILL.md: Run this workflow only after the user explicitly invokes `$okf-updates`, `/skill:okf-updates`, or `/okf-updates`.
  • .agents/skills/okf-updates/SKILL.md: Run at most three direct researchers at once.
  • .agents/skills/okf-updates/SKILL.md: A requester reply that selects one or more candidate IDs from this explicitly invoked workflow is explicit permission to run the normal OKF update logic for those candidates.
  • .agents/skills/okf-updates/SKILL.md: Run deterministic validation, `okf-reviewer`, and `mise run lint`.
  • .agents/skills/okf/SKILL.md: Run this workflow only after the user explicitly invokes `$okf`, `/skill:okf`, or `/okf`.
  • .agents/skills/okf/SKILL.md: After all review fixes, run `mise run lint`.
  • .agents/skills/okf/SKILL.md: Commit every intended file only after reviewer approval and a successful lint run.
  • .agents/skills/okf/SKILL.md: Run the Core docs and Core code researchers together when a concept needs both user-facing guidance and exact served API shape.
  • .agents/skills/okf/SKILL.md: Run independent read-heavy research in parallel, with at most three direct agents.
  • .agents/skills/okf/SKILL.md: After all fixes, run `mise run lint` and fix every reported issue.
  • .agents/skills/okf/SKILL.md: The reviewer may return `APPROVED` only after the final lint run succeeds.
  • .agents/skills/okf/SKILL.md: Non-thinking coding models such as Qwen3-Coder-Next can run every project agent without incompatible reasoning controls.
  • .agents/skills/okf/SKILL.md: deterministic validation and `mise run lint` results
  • AGENTS.md: Run the normal workflow only when the user explicitly invokes `$okf`, `/skill:okf`, or `/okf`, or selects a feature candidate returned by an explicitly invoked `$okf-updates`, `/skill:okf-updates`, or `/okf-updates` workflow.
  • AGENTS.md: Run update discovery only when the user explicitly invokes `$okf-updates`, `/skill:okf-updates`, or `/okf-updates`.
  • AGENTS.md: Run deterministic validation and the `okf-reviewer` before committing the changes.
  • AGENTS.md: After the final review fixes, run `mise run lint` before creating any commit.
  • AGENTS.md: After reviewer approval and a successful lint run, commit every intended change.
  • AGENTS.md: Create commits with a Developer Certificate of Origin sign-off by default by using `git commit --signoff` (or `git commit -s`).

MCP servers (1)

  • .mcp.json (crossplane-v2-okf): https://crossplane.mcp.jkroepke.de/mcp · uses the network
  • Low risk: network-instructions (.agents/skills/okf-open-knowledge-format/SKILL.md:214)

Attribution and licence

First committed by
GitHub avatar of jkroepkejkroepke
Publisher
Jan-Otto Kröpke (Community)
Source
jkroepke/okf-crossplane-v2 · commit df24ac2
Licence
Apache License 2.0 (files served here)
  • ATTRIBUTION.md (written by AutoGineer)
Synced
Contributors
jkroepke

AutoGineer is not affiliated with or endorsed by jkroepke.

Download

The ZIP holds the files AutoGineer serves, with ATTRIBUTION.md and the licence. Download okf-crossplane-v2.zip