---
title: "Algorithmic Fundamentals: K-Framework Layer A.03"
description: "Validate the Algorithmic Fundamentals layer: defensible retrieval, rerank, and decoding choices recorded in ADRs, and a pipeline you can debug stage by stage. A CEO/CTO field guide."
source: "https://www.kensink.com/k-framework/algorithmic-fundamentals/"
canonical: "https://www.kensink.com/k-framework/algorithmic-fundamentals/"
---
[‹](/k-framework/data-strategy/ "Data Strategy") [›](/k-framework/ethics-safety/ "Ethics & Safety")

[← The K-Framework](https://www.kensink.com/k-framework/)

★ Foundations · Systems Thinking Layer 3 of 16 Visual guide

PILLAR A · LAYER 03 · A.03

# Algorithmic Fundamentals.

Understand core algorithms.

What a CEO/CTO needs to know  
When the system degrades, can your team say whether it was retrieval, rerank, prompt, or model? If the LLM is a black box to them, every fix is a guess.

A retrieval pipeline where every stage is inspectable, so a quality drop has an address.

\[WHAT IT IS\]

## The engineer’s view, in plain language.

We do not import and pray. Knowing why an algorithm works, and when it does not, is non-negotiable. The team that built the system can debug it at the algorithmic level when the abstraction leaks, because abstractions always leak.

\[HOW WE BUILD IT\]

## What “done right” looks like.

01

### Every choice defensible

Embedding model, retrieval strategy, reranker, decoding parameters: each is a decision the team can defend from first principles, not a default nobody questioned.

02

### Trade-offs in writing

Why this approach and not the obvious alternative is recorded in an ADR, so the reasoning survives the engineer who made it.

03

### Debuggable to the layer

When quality drops, the team isolates the failing stage instead of swapping the whole pipeline and hoping.

\[ MATURITY LADDER \]

## Where does your build sit?

Four rungs from absent to production-grade. Level 3 is the target, and the only one that survives a real production incident.

L0

Absent

The pipeline is a black box. Tuning is copy-pasted from blog posts.

L1

Ad-hoc

The team knows the parts but cannot explain why each was chosen.

L2

Managed

Most choices are documented, but debugging still means swapping whole stages.

L3 Target

Production-grade

Every algorithmic choice is defensible from first principles and recorded in ADRs; failures isolate to a stage.

\[VALIDATE IT YOURSELF\]

## How to check it’s really there.

You do not need to read the code. Ask these questions and demand these artifacts. Vague answers are the finding.

★ Ask your team

-   ? Why did we pick this embedding model and reranker over the alternatives?
-   ? When answer quality drops, how do we know which stage caused it?
-   ? Who on our team can defend the decoding parameters?

★ Demand to see

-   ADRs for embedding, retrieval, rerank, and decoding choices
-   A way to evaluate each pipeline stage in isolation
-   An engineer who can whiteboard the pipeline end to end

● WHAT L0 LOOKS LIKE

## The failure mode, in production.

Treating the LLM as a black box. Stack-Overflow-driven retrieval tuning. When the system degrades, nobody can say whether it is the retrieval, the rerank, the prompt, or the model.

Useful for a CEO or CTO sizing up an AI build? Share the Algorithmic Fundamentals layer.

Share[](https://twitter.com/intent/tweet?url=https%3A%2F%2Fwww.kensink.com%2Fk-framework%2Falgorithmic-fundamentals%2F&text=Algorithmic%20Fundamentals%3A%20K-Framework%20A.03%20%C2%B7%20Kensink%20Labs)[](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fwww.kensink.com%2Fk-framework%2Falgorithmic-fundamentals%2F)

[View .md](https://www.kensink.com/k-framework/algorithmic-fundamentals.md)

[← Layer 2 Data Strategy](https://www.kensink.com/k-framework/data-strategy/) [Layer 4 → Ethics & Safety](https://www.kensink.com/k-framework/ethics-safety/)

## Want this layer audited in your stack?

We run the K-Framework against your AI build and hand you the gap list, ranked by what it will cost you in production.

[Book a K-Framework audit →](https://www.kensink.com/contact) [All 16 layers](https://www.kensink.com/k-framework/)
