vigiles API reference
    Preparing search index...

    Interface InstructionChain

    The instruction-chain vocabulary PluginLayout.instructionChain speaks.

    Exported because the method is on the port: without these an adapter author cannot write a return type, which makes the interface unimplementable from outside this package. EMPTY_CHAIN is the honest answer for a harness with no instruction surface — spelling out five empty arrays at each such site invites one of them to be forgotten.

    interface InstructionChain {
        imports: readonly NamedImport[];
        loaded: readonly LoadedInstruction[];
        patterns: readonly PatternFrom[];
        redirects: readonly { path: string; to: readonly string[] }[];
        unloaded: readonly UnloadedInstruction[];
    }
    Index

    Properties

    imports: readonly NamedImport[]

    Concrete repo-relative paths the loaded files name as imports. The adapter only reports them; the domain reads them in a second, bounded pass, and an import that was named but not read is printed rather than dropped.

    loaded: readonly LoadedInstruction[]

    Loaded at a repo-root session, in the order the harness concatenates them.

    patterns: readonly PatternFrom[]

    Patterns or URLs the harness would expand at launch and the domain will NOT walk (OpenCode's instructions: ["packages/*/AGENTS.md"]). Reported so the weight can say "plus N pattern(s) not weighed" instead of a number that is silently wrong. Never read.

    redirects: readonly { path: string; to: readonly string[] }[]

    A loaded file whose ENTIRE content is import tokens — a REDIRECT, not instructions, and a finding rather than a footnote.

    🔴 WHY THIS IS A NAMED SHAPE. Four of the six real imports in the measured corpus are @AGENTS.md, written when Claude Code did not yet read AGENTS.md natively (anthropics/claude-code#34235; it does since v2.1.277 — see adapters/claude-code/dialect.ts), and the idiom that follows is a CLAUDE.md holding that one line and nothing else. THE SHAPE DID NOT GO AWAY WITH THE VENDOR CHANGE: those files are still in those repositories, the CLAUDE.md beside them SUPPRESSES the AGENTS.md, and the vendor's own table still gives the case a row. Reported as a size, such a repo has a ~14-byte instruction file — a confident wrong answer about a repository that really loads tens of kilobytes. The report says "this file is a redirect, here is what it points at" instead of printing a reassuring number.

    BINARY, NEVER A THRESHOLD: after the frontmatter, the HTML comments and the blank lines are removed, EVERY remaining line is an import token. "Mostly imports" would be a number nobody can defend.

    unloaded: readonly UnloadedInstruction[]

    Instruction-shaped keys this harness does NOT load, each with why.