Documentation and Knowledge Management Questions
Governing how teams capture and keep knowledge usable: documentation standards, ownership models (centralized, federated or dedicated team) and review cadences, incentives and culture change that get engineers to document, decision records and assumption logs, post-project reviews that preserve lessons, and knowledge-base strategy so organizational knowledge stays findable and attributed. Includes building or buying a knowledge platform, migration and consolidation plans, taxonomy, tagging and search quality, linking docs to code, capturing tacit expertise into the knowledge base, detecting and remediating stale docs across a documentation estate, and versioning and change policies for shared reports and metric definitions. Covers the governance and lifecycle of a body of documentation, not the craft of writing any single document.
Design a searchable tagging and metadata model for an internal documentation portal that must serve thousands of datasets and hundreds of engineers. What fields would be mandatory, how would you keep the tag vocabulary from sprawling, and how would tags connect to team ownership and access controls?
Sample Answer
Direct answer
Give every doc or dataset entry a small mandatory core (type, owning team, lifecycle state, sensitivity), a controlled vocabulary for tags with a named steward, and make ownership and access derive from the metadata rather than being maintained separately. Search then works on structured fields first, free-text tags second.
Terms
- Metadata: data about a document (who owns it, what kind it is).
- Tag: a label attached to a doc for search and filtering.
- Controlled vocabulary: an approved list of tag values, changed only through a process.
- Steward: the person responsible for a domain's tags and doc quality.
- ACL (access control list): a rule saying which people or groups may see an item.
- Lifecycle state: draft, active, deprecated or archived.
- Sensitivity: how restricted the content is (public, internal, restricted).
- Model card: a short document describing a machine-learning model's purpose, data and limits.
- Facets: fixed filter categories in search, such as type or domain, shown as checkboxes or dropdowns.
- Alias: an alternative name that points at an approved tag, so "customers" finds docs tagged "customer".
- Recall (in search): how many of the relevant docs a search actually returns. Inconsistent tags hide relevant docs, so recall drops.
- Lineage: the record of where a dataset came from and which datasets or reports are built from it.
- Refresh cadence: how often a dataset is updated (hourly, daily). Schema: the list of columns and their types.
- Identity system: the company directory of people and groups (for example the single sign-on provider).
Mandatory fields (eight rows below, covering eleven individual fields: id, title, type, owner_team, steward, lifecycle, sensitivity, domain, last_reviewed, review_every_days, links; auto-fill most so people complete them)
| Field | Purpose |
|---|---|
| id, title | Stable identity and display |
| type (dataset, runbook, dashboard, model_card, architecture_doc) | Selects the template and extra fields |
| owner_team and steward | Who answers questions and reviews |
| lifecycle | Hides deprecated content from default search |
| sensitivity | Drives access and audit. Policy: restricted content must be reviewed at least every 90 days, stricter than the owner's normal window |
| domain (one value from a fixed list) | Primary browse path |
| last_reviewed and review_every_days | Freshness checks |
| links (code, upstream and downstream datasets) | Connects docs to reality |
Type-specific fields sit on top: a dataset adds schema and refresh cadence, a runbook adds the system and severity it covers, a model card adds training data and intended use.
Typed artifact example (sample record)
{
"id": "doc-4127",
"type": "runbook",
"title": "Orders pipeline: recovering a stuck nightly load",
"owner_team": "data-platform",
"steward": "priya.n",
"lifecycle": "active",
"sensitivity": "internal",
"domain": "orders",
"last_reviewed": "2026-03-02",
"review_every_days": 90,
"links": {"code": "repo://data-platform/orders-etl", "dataset": "ds-orders-daily"}
}
Finding stale or sensitive docs (runnable, with output)
The query computes days since last review (julianday is SQLite's date-to-number function, so subtracting two of them gives elapsed days) and compares it to each doc's window. On the sample date, 2026-09-28: doc-4127 was reviewed 210 days ago against a 90-day window, doc-2001 331 days ago against 180, doc-3310 100 days against 180 (fine), doc-2050 75 days against 180 (fine).
import sqlite3
db = sqlite3.connect(":memory:")
db.execute("""create table docs(id text, type text, owner_team text, lifecycle text,
sensitivity text, last_reviewed text, review_every_days int)""")
db.executemany("insert into docs values (?,?,?,?,?,?,?)", [
("doc-4127", "runbook", "data-platform", "active", "internal", "2026-03-02", 90),
("doc-2001", "dataset", "payments", "active", "restricted", "2025-11-01", 180),
("doc-3310", "model_card", "ml-platform", "active", "internal", "2026-06-20", 180),
("doc-1500", "dashboard", "bi", "deprecated", "internal", "2025-01-10", 90),
("doc-2050", "dataset", "payments", "active", "restricted", "2026-07-15", 180),
])
TODAY = "2026-09-28"
print("stale:")
for row in db.execute("""select id, type, owner_team from docs
where lifecycle = 'active'
and julianday(?) - julianday(last_reviewed) > review_every_days
order by id""", (TODAY,)):
print(row)
print("restricted and not reviewed in 90 days:")
for row in db.execute("""select id, type, owner_team from docs
where sensitivity = 'restricted'
and julianday(?) - julianday(last_reviewed) > 90
order by id""", (TODAY,)):
print(row)
Output:
stale:
('doc-2001', 'dataset', 'payments')
('doc-4127', 'runbook', 'data-platform')
restricted and not reviewed in 90 days:
('doc-2001', 'dataset', 'payments')
The runbook is flagged because 210 days is over its 90-day window, while the dataset entry doc-2001 is flagged twice: 331 days is past its 180-day window and, being restricted, past the stricter 90-day sensitive review rule. doc-2050 is also restricted but only 75 days old, so it is not flagged.
Stopping tag sprawl
- Two tiers: fixed facets (type, domain, lifecycle, sensitivity are dropdowns, never free text) and a governed tag list that a steward approves.
- Request flow: propose a tag, the steward checks for a synonym, then adds it as an alias (for example "customers" maps to "customer") instead of a new tag.
- Quarterly cleanup: merge tags used by fewer than a handful of docs, and report the tag count.
- Autocomplete from the approved list at authoring time prevents most duplicates.
Connecting tags to ownership and access
- owner_team maps to a group in the identity system, so ownership is reassigned in one place when teams reorganize.
- Sensitivity maps to an access rule: internal means all engineers, restricted means the owner group plus named approvers. Search filters results by the viewer's permissions, so restricted titles never leak in results.
- Access changes are logged, and a restricted doc without an owner is blocked from publication.
Trade-offs and pitfalls
- Too many mandatory fields means blanks or junk values. Auto-fill what you can (owner from the repo, type from the template).
- Free-text tags feel flexible but destroy recall in a year.
- Sensitivity set by the author alone is unreliable, so spot-check it and default new data-related pages to "internal".
- What would change my call: with only a few dozen docs a folder structure is enough.
Your knowledge base is stale and teams are repeating incidents because playbooks are obsolete. Propose a remediation program: what you clean up first, how stale content is detected automatically, how humans review, what stops recurrence, and a realistic timeline and staffing.
Sample Answer
Direct answer
Run a time-boxed remediation program aimed at the runbooks that pages and incidents actually touch. Clean up tier-1 procedures first, detect staleness automatically with checks against real infrastructure and incident history, require a human to walk each procedure before it is marked verified, and stop recurrence by making a working runbook a condition for shipping an alert and for closing a postmortem. Archive everything nobody claims instead of reviewing it.
Terms. A playbook or runbook is a step-by-step procedure for handling an operational event. A postmortem is a written review of an incident; blameless means it looks for system causes, not someone to blame. A tier-1 service is one whose failure pages people or hurts revenue; tier 2 is important but a failure degrades it rather than stopping it (for example an internal reporting tool). A paging alert is an alert that wakes someone up. A staging environment is a safe copy of production for testing. The inventory is the current list of live hosts and services, taken from your configuration database. A decommissioned host is one that has been shut down and removed.
1. What to clean up first
Rank runbooks by consequence, not by age:
- Runbooks linked from paging alerts on tier-1 services.
- Runbooks named in the last 12 months of postmortems as missing, wrong or ignored (those are the ones that already repeated an incident).
- Runbooks for tier-2 services.
- Everything else: put an archive notice on it and delete or archive after 30 days if no owner claims it.
2. Automatic staleness detection
- Nightly job: links, hostnames, service names and commands referenced in the runbook checked against the current inventory. A reference to a decommissioned host is a hard flag.
- Alert-to-runbook check: every paging alert's runbook URL must resolve and must have a verified date inside its interval.
- Incident hook: responders press "runbook was wrong or missing" during or after an incident, which creates a ticket automatically.
- What the nightly check produces, for one runbook:
db-failover step 4 references host db-eu-2 (decommissioned 2026-06-30): HARD FLAG. Ticket opened for payments-team, due in 5 business days. - Age since last verified, used as a weak signal only (age alone is a poor predictor; broken references and incident flags are stronger).
3. Human review
The owner walks the runbook step by step in a staging environment, or as a tabletop drill (a talked-through rehearsal), with a second person who did not write it. They fix wrong steps, record the date and both names, and only then is the page marked verified. Reading it and clicking "still accurate" does not count.
4. Preventing recurrence
- CI (continuous integration) lint: an automated check that runs on every proposed change and rejects it when a rule is broken, here: an alert definition cannot merge without a runbook link. Illustrative output of a small custom lint script (no standard tool prints exactly this; you define the wording) when it fails:
FAIL alerts/checkout.yaml: "CheckoutLatencyHigh" has severity=page but no runbook_url
FAIL alerts/search.yaml: runbook_url https://wiki.example.com/runbooks/search-old returns 404
- Postmortem action items include "update the runbook" and the postmortem cannot close until the change is merged.
- Runbook lives next to the service code and its owner appears in the repo's CODEOWNERS file (a file that maps paths to owning teams), so changes get reviewed.
- Quarterly drill of the tier-1 runbooks (a game day, a rehearsal where you deliberately trigger a failure).
5. Realistic timeline and staffing
Illustrative sizing: 400 runbooks, of which 40 are tier 1 and 100 are tier 2.
| Phase | Weeks | Work | Effort |
|---|---|---|---|
| 0. Inventory and triage | 1-2 | Export all runbooks, tag tier and owner | Program lead, part-time |
| 1. Tier 1 | 3-8 | Walk and fix 40 runbooks, 1.5 hours each: 60 hours | Owners of each service: 60 hours over 6 weeks is about 10 hours per week in total, so with roughly 10 owning teams that is 1 to 2 hours per week each |
| 2. Detection and CI guard | 4-10 | Build nightly reference check, alert lint | One engineer, about two weeks |
| 3. Tier 2 | 9-16 | 100 runbooks at 1 hour: 100 hours | Owners |
| 4. Long tail | 12-16 | Archive unclaimed after 30-day notice | Program lead |
Staffing: one part-time program lead, one engineer for tooling, and a small time budget from each owning team. The human review effort totals about 160 hours (60 for tier 1 plus 100 for tier 2), which is roughly 4 person-weeks spread across teams, not one team's burden.
Success measures. No paging alert without a verified runbook; postmortems citing "runbook wrong" decline quarter over quarter; nightly reference-check failures trend to zero.
Pitfalls
- Reviewing all 400 equally wastes the program's budget on the long tail.
- A one-time cleanup decays; without the CI and postmortem gates you are back here in a year.
- What would change my call: if the team is tiny, skip the tooling and run a monthly tier-1 drill instead.
Your team keeps re-debating choices made months ago because nobody can say why they were made. What should a decision record capture, which decisions deserve one and which do not, and where would you keep them so people find them?
Sample Answer
Direct answer
A decision record (in software often called an ADR, architecture decision record) is a short note written when a decision is made. It should capture the context, the options considered, the choice, the reasoning and the consequences, so a person six months later can see why without asking. Not every decision needs one: write records for decisions that are hard to reverse, costly, cross-team, surprising or likely to be asked about again. Keep them next to the work (in the repository for engineering choices, linked from the ticket or roadmap for product choices) with one index page.
Structured elaboration
What to capture (one page is plenty)
- Title and date, and status (proposed, accepted, superseded by record N).
- Decision owner and who was consulted.
- Context: the problem, the constraints and the deadline pressure at the time.
- Options considered, with the reason each was rejected. This is the part that stops re-debate, because people who propose the rejected option can see it was already weighed.
- Decision in one sentence.
- Consequences: what gets easier, what gets harder, and what we accept.
- Revisit trigger: the condition that would reopen it ("if traffic exceeds X" or "at the next vendor renewal").
Which decisions deserve one
A quick test: would a new team member reasonably ask "why did we do it this way?" in six months, and would the answer be lost if the two people who decided left? Yes means write it. Typical yes: choosing a database (the reasons live in a few heads and are costly to redo), an API style such as REST versus GraphQL (every client depends on it), build vs buy (the cost, lock-in and staffing reasoning is rarely written elsewhere), a data retention policy (the legal reasoning matters when someone later wants to delete or keep data), a metric definition (dashboards and targets hang on it). Typical no: variable naming, a reversible feature flag default, an option you can change in an afternoon.
Where to keep them
- Engineering decisions: a
docs/decisions/folder in the repository, numbered, reviewed in a pull request (PR). They travel with the code and are found by anyone who opens the repo. - Product or cross-team decisions: a decision-log space in the wiki, linked from the ticket and the roadmap item.
- One index (a table of number, title, status, date) so people can scan.
Worked example
Decision record 007: Store order data in PostgreSQL, not DynamoDB
Status: Accepted (2026-03-04)
Owner: Backend lead. Consulted: data team, finance.
Context: Finance needs ad hoc joins across orders and refunds.
Team has strong SQL experience, no DynamoDB experience.
Options: (a) PostgreSQL. (b) DynamoDB: rejected, ad hoc joins would need extra pipelines.
Decision: Use PostgreSQL with read replicas.
Consequences: Easier reporting. Harder to scale writes past one primary.
Revisit if: Sustained write load outgrows a single primary.
In plain words: PostgreSQL is a relational database queried with SQL, good at joins across tables. DynamoDB is a managed key-value database, fast for simple lookups but awkward for ad hoc joins. A read replica is an extra copy of the database that only serves read queries, which spreads reporting load. A single primary is the one main copy that accepts all writes, so if writes outgrow one machine, the design is harder to scale.
When someone asks in July "why not DynamoDB?", the answer is one link, and the debate is only reopened if the revisit trigger has actually fired.
Trade-offs and pitfalls
- Records that are too long are never written. Cap at one page and accept rough drafts.
- Do not edit an old record to change its meaning. Write a new one that supersedes it.
- Writing records after the fact from memory loses the rejected options, so write them as part of making the decision.
- A record folder nobody links to is invisible: link to it from the README (the repo's front-page file) and the PR template.
Your organization is growing fast and new hires take too long to become productive, while senior engineers are constantly interrupted with questions. How would you scale documentation and knowledge capture so ramp-up speeds up without adding load on seniors?
Sample Answer
Direct answer
Treat the interruptions as data. Log what new hires ask seniors for two weeks, write the docs for the questions that repeat, route every future question through "answer in the doc, then link it", and build a structured first-30-days path. Bound the remaining interruptions with office hours and a buddy rotation so seniors are asked on a schedule instead of continuously. Write only what gets asked twice, otherwise the docs become a second job nobody has time for.
Terms
- Runbook: step-by-step instructions for an operational task, such as deploying or restarting a service.
- README: the front-page file of a code repository that explains what it is and how to run it.
- Stub: a short placeholder page with a title and a link, to be filled in later.
- Shelfware: documentation written once, never used, and left to rot.
- Buddy rotation: a schedule assigning a different teammate each week as the person a new hire asks first.
- Office hours: fixed times when seniors are available for questions, so they are not interrupted at other times.
- Single-point-of-knowledge risk: only one person understands something, so their absence stops the team.
- Time to first merged change: days from a new hire's start until their first change is accepted into the shared code or content.
Step 1: Measure the question stream (weeks 1-2)
Ask new hires to drop every question they take to a senior into one tracker (a channel or form) with a topic tag. Suppose 40 questions arrive in two weeks and they cluster like this:
| Topic | Count |
|---|---|
| Local environment setup | 9 |
| Deploy and release process | 6 |
| Which service owns what | 5 |
| Getting access and permissions | 3 |
| How to read our alerts | 3 |
| Everything else (one-offs) | 14 |
The top five topics account for 26 of 40 questions, which is 65 percent. Five good pages remove most of the repeat load. That is where to start, and it also tells you which pages to leave unwritten.
Step 2: Capture as a by-product of work
- Answer once, in the doc. When a senior answers a repeat question, they paste the answer into the page (or the new hire does) and reply with the link. The cost is two minutes and it is paid once.
- New hires write the setup guide. They have fresh eyes and find the gaps; a senior only reviews. The page is marked "last verified by (name), (date)".
- Definition of done includes docs. The pull request (PR) template asks "does this change how someone runs, deploys or debugs this service? Update the README or runbook."
- Short recorded walk-throughs for architecture, always with a written summary above the video, because video alone is not searchable.
Step 3: Structure the ramp-up
A checklist for day 1, week 1 and day 30 with links to the pages above and a first small task (a safe first pull request in week one). A filled-in version:
Day 1: accounts requested; join team channel; meet your buddy
Week 1: run the service locally (setup page); read "Which service owns what";
make one small safe change (fix a wrong line in a doc) and get it merged
Day 30: shadow one deploy; shadow one on-call shift; write or fix one page you found unclear
The measure of success is a new hire's time to first merged change, plus questions per new hire trending down.
Step 4: Protect seniors without going silent
- Two weekly office-hour slots and a rotating "ask first" buddy (not always the same senior).
- Rule for the team channel: search the docs, then ask; the answerer links the page, and if none exists, creates a stub.
Variant: a business intelligence (BI) team with single-point-of-knowledge risk
A BI team often has one analyst who alone understands a dashboard's logic. The same idea applies with a specific structure:
- Content structure: a metric dictionary page per metric (definition, source tables, refresh schedule, known caveats) and a page per dashboard (purpose, audience, inputs).
- Example metric dictionary entry (weekly active users):
Metric: Weekly active users (WAU)
Definition: distinct user IDs with at least one login or project action in the last 7 days (UTC)
Source: events.user_activity, excluding internal test accounts
Refresh: daily at 06:00 UTC
Owner/backup: A. Analyst / B. Analyst
Caveats: API-only usage not counted; definition changed 2026-03-01, earlier values not comparable
- Ownership: every page has a named owner and a named backup owner, so no page has one person only.
- Metadata: owner, backup, last-verified date, data source, refresh cadence, audience. This makes stale or orphaned pages queryable.
- Maintenance cadence: a quarterly review where each owner re-verifies their pages, plus a trigger whenever a source table changes.
Trade-offs and pitfalls
- Writing "complete" documentation up front produces shelfware. Demand-driven docs are smaller and used.
- If seniors are also the reviewers of every doc, you moved the load, not removed it. Let the second-most-experienced person review.
- Pages with no owner and no verified date go stale in a few months. Ownership is the design, not a nice-to-have.
- What would change my call: for a very small team (under about five people), pairing and a short README beat any portal.
You are moving scattered documentation into one centralized knowledge base. Lay out your migration plan from first inventory to cutover: how you decide what to keep, merge or retire, how content gets owners and stays findable, what happens to old material, and which measures tell you the migration worked.
Sample Answer
Direct answer
Treat the migration as content curation first, tooling second: inventory everything, decide keep, merge or retire using a simple scoring rule, put owners and metadata on every kept page BEFORE moving it, migrate in waves ordered by operational criticality, leave redirects behind, and judge success by whether people find answers faster, not by how many pages moved.
Terms
- Inventory: a spreadsheet listing every doc, where it lives, who wrote it and when it last changed.
- Redirect: an old link that automatically forwards to the new location.
- Cutover: the moment the new system becomes the official source.
- Runbook: step-by-step instructions for operating or fixing a system.
Phase 1: Inventory and triage (weeks 1-2)
Crawl the wikis, shared drives and repos, and add the informal sources: chat channels and personal notes. Record for each item: location, owner, last edit, views if known, and which system it describes.
Decide keep, merge or retire with a short rule:
| Decision | Rule |
|---|---|
| Keep | Still accurate, describes a live system, and is used or operationally needed |
| Merge | Overlaps another page on the same topic; combine into one canonical page |
| Retire | Describes decommissioned systems, unedited for a long time, and nobody uses it |
| Ask a domain owner to confirm every retire in bulk, so nothing critical vanishes silently. |
Worked example (illustrative arithmetic)
Inventory finds 400 items. Triage results: 120 keep, 90 merge (they collapse into 30 pages), 190 retire. The new knowledge base receives 120 + 30 = 150 pages, 37.5 percent of the original. Every item still has a recorded fate in the inventory, so the numbers reconcile: 120 + 90 + 190 = 400.
Phase 2: Structure, ownership, findability
- Target structure: a few top-level areas (for example Services, Runbooks, Processes, Onboarding), not a mirror of the org chart.
- Tags: a small controlled list (team, system, lifecycle, audience); no free-form tags at launch.
- Every page has an owner team and a last-reviewed date; pages without an owner are not migrated.
- Search: index titles, headings and tags, boost pages by verified freshness, and test with a list of the 20 most common real questions.
Phase 3: Migrate in waves, by operational criticality
For knowledge that lives only in chat channels and personal notes, rank by "what hurts if it is missing at 3am": on-call runbooks and recovery steps first, then setup and onboarding, then background context. Capture chat knowledge by turning a decision or fix into a proper page (with the thread linked), not by dumping the export. Set a measurable onboarding-speed goal, for example that a new engineer completes the first supervised on-call shift using only the knowledge base, and measure the median days before and after.
Phase 4: Old material and cutover
Freeze the old wikis to read-only with a banner pointing to the new location, keep redirects for a defined period, archive (do not delete) retired items for legal or historical reasons, then switch off after traffic to old links falls.
Success measures
- Search: share of searches with a click and no immediate re-search, and zero-result queries falling.
- Coverage: percent of critical systems with an owned, current runbook.
- Freshness: percent of pages reviewed within their window.
- Onboarding speed (above) and fewer "where is the doc for X" questions in chat.
Trade-offs and pitfalls
- Migrating everything "just in case" copies the rot into the new home.
- No owners means the new system decays as the old one did.
- A big-bang cutover is riskier than waves, but waves prolong two sources of truth, so set a firm end date.
- What would change my call: a small team with 50 pages should skip scoring and simply re-read them.
Unlock Full Question Bank
Get access to all 32 Documentation and Knowledge Management interview questions and detailed answers.
Sign in to ContinueJoin thousands of developers preparing for their dream job.