Skip to content

API Reference parrot.knowledge.wiki.decisions.ingest

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot.knowledge.wiki.decisions.ingest

View source

ADR discovery and idempotent source refresh (FEAT-578 Module 3).

The only writer of adr:doc: records. Candidate (adr:candidate:) records are read to resolve links but NEVER written here — a documented refresh must not disturb independently reviewed candidates (spec §2, AC7).

Alias ADR_READ_ONLY

Re-exported from parrot.knowledge.wiki.decisions.models.ADR_READ_ONLY.

Alias ADR_REFERENCE_AMBIGUOUS

Re-exported from parrot.knowledge.wiki.decisions.models.ADR_REFERENCE_AMBIGUOUS.

Alias ADR_REFERENCE_MISSING

Re-exported from parrot.knowledge.wiki.decisions.models.ADR_REFERENCE_MISSING.

Alias ADR_SOURCE_UNAVAILABLE

Re-exported from parrot.knowledge.wiki.decisions.models.ADR_SOURCE_UNAVAILABLE.

Alias BaseWikiStore

Re-exported from parrot.knowledge.wiki.store.BaseWikiStore.

Alias DecisionConfig

Re-exported from parrot.knowledge.wiki.decisions.models.DecisionConfig.

Alias DecisionDiagnostic

Re-exported from parrot.knowledge.wiki.decisions.models.DecisionDiagnostic.

Alias DecisionError

Re-exported from parrot.knowledge.wiki.decisions.models.DecisionError.

Alias DecisionLink

Re-exported from parrot.knowledge.wiki.decisions.models.DecisionLink.

Alias DecisionRecord

Re-exported from parrot.knowledge.wiki.decisions.models.DecisionRecord.

Alias DecisionRepository

Re-exported from parrot.knowledge.wiki.decisions.repository.DecisionRepository.

Alias EvidenceRef

Re-exported from parrot.knowledge.wiki.decisions.models.EvidenceRef.

Alias SCAN_EXCLUDE_DIRS

Re-exported from parrot.knowledge.scan_excludes.SCAN_EXCLUDE_DIRS.

Alias SEED_HEADING

Re-exported from parrot.knowledge.wiki.decisions.spec_entries.SEED_HEADING.

Alias SyncResult

Re-exported from parrot.knowledge.wiki.decisions.models.SyncResult.

Alias build_evidence

Re-exported from parrot.knowledge.wiki.decisions.evidence.build_evidence.

Alias content_fingerprint

Re-exported from parrot.knowledge.wiki.decisions.codec.content_fingerprint.

Alias decision_to_page

Re-exported from parrot.knowledge.wiki.decisions.codec.decision_to_page.

Function discover_adr_sources

Repository-relative POSIX paths of every eligible ADR document.

Applies config.adr_globs AND the project's normal relevance / exclusion rules — a matching glob inside an excluded directory is still excluded (spec §2). A file carrying a ## Decision Metadata block is a seed ADR and is never a legacy source: it enters only through its approved batch (AC13). When approved_specs is given, the result is instead the batch sources: those seed files plus every approved spec path that exists under root (missing or out-of-root paths are skipped silently).

discover_adr_sources(root: Path, config: DecisionConfig, *, approved_specs: list[str] | None = None) -> list[str]

Parameter Type Default Description
root Path
config DecisionConfig
approved_specs list[str] | None None

Returns: list[str]

Alias discover_python_files

Re-exported from parrot.knowledge.graphindex.cli.discover_python_files.

Alias extract_python_citations

Re-exported from parrot.knowledge.wiki.decisions.evidence.extract_python_citations.

Attribute logger

Alias parse_adr

Re-exported from parrot.knowledge.wiki.decisions.parser.parse_adr.

Function project_links

Rebuild the navigational edge projection for records.

Edges are a rebuildable cache, never authority: retrieval validates the corresponding record link, so a stale projected edge can never establish applicability (spec §2). Safe to re-run.

project_links(store: BaseWikiStore, records: list[DecisionRecord]) -> int

Parameter Type Default Description
store BaseWikiStore
records list[DecisionRecord]

Returns: int

Function refresh_decisions

Refresh documented ADR records and their links, idempotently.

refresh_decisions(store: BaseWikiStore, root: Path, config: DecisionConfig, paths: list[str] | None = None) -> SyncResult

Parameter Type Default Description
store BaseWikiStore
root Path
config DecisionConfig
paths list[str] | None None Repository-relative paths to refresh, or None for the full configured inventory. An incremental run still re-resolves aliases against the FULL stored inventory.

Returns: SyncResult — Counts plus diagnostics. Never raises for a per-record failure — writes are per-record atomic, so a retry converges (spec §2).

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally