# =============================================================================
# vocabulary.seed.yaml — CVH Profile v0.2 · Day-0 instantiation template
# =============================================================================
# Canonical vocabulary contract for a NEW project, born with the policy rooted.
# Replace placeholders: {{PROJECT}} {{PREFIX}} {{DOMAIN}} {{OPERATOR_ID}}
#                       {{CORE_MODULE}} {{YYYY-MM-DD}}
#
# Conventions (profile §1):
#   - Normative descriptions in EN; skos:prefLabel pairs demonstrate I2.
#   - Sentences are BRIDGED, not duplicated: skos:definition in the language
#     opposite to sourceLanguage (term:semantic-bridge-rule).
#   - SECTION A/B/C terms are Day-0 governance — do not remove (I-root set).
#   - SECTION D grows ONLY via the ingestion rite (profile §8).
#   - One file, one scheme: planes are SECTIONS, never separate files (P1).
# Profile reference: https://ssot.com.br/ns/cvh#profile@v0.3 (placeholder IRI)
# =============================================================================

"@context":
  schema: https://schema.org/
  dcterms: http://purl.org/dc/terms/
  prov: http://www.w3.org/ns/prov#
  skos: http://www.w3.org/2004/02/skos/core#
  # F1 — MUST be a dereferenceable IRI under the operator's domain from Day-0.
  # Content publication may come later (L3); the IRI never changes.
  "{{PREFIX}}": "https://{{DOMAIN}}/ns/{{PROJECT}}#"
  cvh: "https://ssot.com.br/ns/cvh#"
  # isBasedOn coerced to @id so conformance is a real IRI edge to the profile, not a literal.
  "schema:isBasedOn": {"@id": "schema:isBasedOn", "@type": "@id"}

"@type":
  - schema:DefinedTermSet
  - skos:ConceptScheme
"@id": "{{PREFIX}}:vocabulary"
"schema:name": "{{PROJECT}} Canonical Vocabulary"
"skos:prefLabel":
  - "@language": pt-BR
    "@value": "Vocabulário canônico {{PROJECT}}"
  - "@language": en
    "@value": "{{PROJECT}} canonical vocabulary"
"schema:version": v0
"dcterms:created": "{{YYYY-MM-DD}}"
"dcterms:creator": "{{PREFIX}}:agent:operator"
"schema:isBasedOn": "https://ssot.com.br/ns/cvh#profile@v0.3"
# Governance terms below are natively en; domain terms declare their own.
"{{PREFIX}}:defaultSourceLanguage": en

# --- I3 — driftGuard ---------------------------------------------------------
"{{PREFIX}}:driftGuard": >
  No executive or operational output may be derived from undefined terms,
  ad-hoc fields, or free LLM interpretation. LLM does not replace
  deterministic computation, registry, harness, or operator consent. Truth
  must be traceable to vocabulary-declared concepts, deterministic evidence,
  provenance, and operator gates.

# --- I4 — moduleBoundary (root) ----------------------------------------------
"{{PREFIX}}:moduleBoundary":
  "{{PREFIX}}:moduleId": "{{CORE_MODULE}}"
  "{{PREFIX}}:mustOwn":
    - "deterministic evidence loading"
    - "reconciliation and parity checks"
    - "lifecycle gate evaluation"
  "{{PREFIX}}:mustNotOwn":
    - "LLM interpretation as source of truth"
    - "free-form business truth inference"
    - "rendering concerns"

"schema:hasDefinedTerm":

  # ===========================================================================
  # SECTION A — Self-describing governance terms (Day-0 · do not remove)
  # ===========================================================================

  - "@id": "{{PREFIX}}:term:bilingual-label-invariant"        # I2
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Invariante de rótulo bilíngue"}
      - {"@language": en, "@value": "Bilingual label invariant"}
    "schema:description": >
      Every concept MUST declare exactly one skos:prefLabel per active
      language tag (pt-BR, en) at ingestion time. The @id stays
      language-neutral. Surfaces project labels: operator-facing renders
      prefLabel@pt-BR; payload/event identifiers use the @id (or en).
      Aliases go to skos:altLabel; typos and legacy strings to
      skos:hiddenLabel. Identical strings across tags are valid (proper
      nouns). Sentence-level semantics are
      bridged, not duplicated — see term:semantic-bridge-rule. The parity validator MUST reject new terms missing the pair.
    "dcterms:created": "{{YYYY-MM-DD}}"

  - "@id": "{{PREFIX}}:term:semantic-bridge-rule"             # I2 extension
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Regra da ponte semântica"}
      - {"@language": en, "@value": "Semantic bridge rule"}
    "skos:related": "{{PREFIX}}:term:bilingual-label-invariant"
    "schema:description": >
      Labels are paired (bilingual invariant); sentences are NOT blindly
      duplicated — full duplication doubles the drift surface and the
      sync cost (I10). Instead: every term declares its native language
      via {{PREFIX}}:sourceLanguage (pt-BR or en; scheme default
      applies). Normative descriptions default to en-US, the model-pivot
      language. The term MUST carry a skos:definition in the language
      OPPOSITE to its native one, acting as a bridge — an explanation
      written FOR the other-language reader, never a literal
      translation. Examples: native pt-BR "vendedor" -> definition@en
      "a vendedor is a seller in the Brazilian sales context; sales
      teams (equipes de vendas) are composed of vendedores"; native en
      "SSOT" -> definition@pt-BR "Fonte Única de Verdade (Single Source
      of Truth): registro canônico do qual as demais superfícies
      derivam, com regras estritas de certificação de entrada".
      Same-language definition is optional. Explicit for robot agents:
      this rule lives here, machine-readable — any consumer knows
      deterministically which side is the original term and which is
      the bridge. The parity validator rejects new terms missing
      sourceLanguage resolution or the opposite-language definition.

  - "@id": "{{PREFIX}}:term:operator-approval"                 # I8
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Aprovação do operador"}
      - {"@language": en, "@value": "Operator approval"}
    "skos:altLabel":
      - {"@language": pt-BR, "@value": "aval"}
      - {"@language": en, "@value": "approval gate"}
    "schema:description": >
      Destructive operations, architectural route changes, fixed-scope
      escape, and high engine impact happen ONLY with explicit ROOT operator
      approval. Use approve/approval (en) and aprovar/aprovação (pt-BR).
    "{{PREFIX}}:deprecatedTerms": [ratify, ratification, ratificar, ratificação]

  - "@id": "{{PREFIX}}:term:ingestion-rite"                    # profile §8
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Rito de ingestão"}
      - {"@language": en, "@value": "Ingestion rite"}
    "schema:description": >
      Single enforcement gate for new terms/features: classify
      (codelist:ingestion-policies) -> declare here (@id + prefLabel pair
      + sourceLanguage resolution + opposite-language bridge definition
      per term:semantic-bridge-rule + status proposed + dcterms:creator) -> reflect on required surfaces
      (registry, TUI, derived prose) -> parity validator passes -> operator
      approval -> status active. Nothing enters code, payload, UI, or
      prompts before being declared. (I1)

  - "@id": "{{PREFIX}}:term:operator-gateway"                 # profile §8 — executor
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Gateway do operador (TUI ROOT)"}
      - {"@language": en, "@value": "Operator gateway (ROOT TUI)"}
    "schema:description": >
      Canonical executor of the ingestion rite: the operator's ROOT TUI
      script (mode 700, local-only) acts as middleware between the
      operator and rings 0-1 — entry gate (rite-driven ingestion, I8
      approvals, lifecycle promotions) and exit gate (I9 evidence,
      status, backlog with reactivation paths) of the self-evolution
      loop. The gateway mediates, never owns: no state lives in it (P1);
      it is the single interactive write path to the center, and every
      write it performs is atomic (P2) and replay-safe (P3).

  - "@id": "{{PREFIX}}:term:execution-window"                 # profile §8 — window
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Janela de execução (TUI)"}
      - {"@language": en, "@value": "Execution window (TUI)"}
    "schema:description": >
      Every agent activity runs inside a typed TUI window opened by the
      operator gateway and described by the tuple
      Status(Phase) : Type : Category : Service : Feature — each
      component MUST resolve to a declared @id (Type from
      codelist:ingestion-policies; Category/Service/Feature from domain
      terms, SECTION D). A descriptor with an undeclared component does
      not open a window (I1 at runtime). Window starts RED (RED = start
      of the TDD cycle). GREEN is an ATTESTED verdict, not automatic:
      granted only IF current status / service level, plan review,
      success criteria, and execution plan are all met — never test
      passes alone (deterministic gate, P4). Version bump DEPENDS on
      GREEN plus formal window closure (TUI kill/close/restart through
      the gateway): the bump seals an atomically closed window, never a
      live one (P2). A new worktree closes the current window and
      reopens the TUI under the same convention — workspace atomicity
      (P2). Re-running a window converges (P3).

  - "@id": "{{PREFIX}}:term:interaction-language-protocol"    # profile §8 — conventions
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Protocolo de idioma da interação"}
      - {"@language": en, "@value": "Interaction language protocol"}
    "schema:description": >
      Operator-facing interaction (negotiations, initial suggestions,
      approvals) MUST be in Brazilian Portuguese (pt-BR). Internal
      reasoning and technical documentation authored by the agent MUST
      use the model's highest-assertiveness language — lowest regression
      index (currently en-US). Functional binding, not dogma: if another
      language reaches equal or higher algorithmic assertiveness, the
      rule follows it. Technical terms (Harness, SSOT, Leverage) stay in
      EN on both surfaces. Complements term:bilingual-label-invariant —
      that one governs DATA labels; this one governs DISCOURSE.

  - "@id": "{{PREFIX}}:term:tropicalization-br"               # profile §8 — conventions
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Tropicalização (contexto BR)"}
      - {"@language": en, "@value": "Tropicalization (BR context)"}
    "schema:description": >
      Default regional grounding for business facts presented to the
      operator: market = Brazil / LATAM (BRASILEIRO = LATINO-AMERICANO);
      currency = BRL (R$); compact pt-BR digit notation (1.2Mi, 990.9k,
      1.8k); timezone America/Sao_Paulo (GMT-3); phone +55. Applies when
      determining goal, MVP, seed round, stage, and available investment
      programs. International (en-US) framing only on explicit request.

  - "@id": "{{PREFIX}}:term:operator-decision-protocol"       # profile §8 — conventions
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Protocolo de decisão do operador"}
      - {"@language": en, "@value": "Operator decision protocol"}
    "schema:description": >
      The human operator approves and decides direction; the agent never
      decides for him (I8). Uncertainty is presented as a selective menu
      of at least 3 options. In grill-me mode (deep elicitation,
      operator-engaged) the agent may raise up to 10 items per domain.
      Hierarchy inversion is a protocol violation.

  - "@id": "{{PREFIX}}:term:derived-prose"                     # F3
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Prosa derivada"}
      - {"@language": en, "@value": "Derived prose"}
    "schema:description": >
      Policy documents, system prompts, and agent READMEs are projections of
      this vocabulary, never sources. Every derived artifact MUST carry the
      header "generated-from: {{PREFIX}}:vocabulary@{version}". Divergent
      prose copies are a parity-validator failure, not an editorial issue.
      Projection generation MUST be idempotent (P3): the validator
      regenerates from vocabulary@version and compares byte by byte.

  - "@id": "{{PREFIX}}:term:evidence-contract"                 # I9
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Contrato de evidência"}
      - {"@language": en, "@value": "Evidence contract"}
    "schema:description": >
      Every data source MUST emit manifest + checksum + deterministic
      summary, mechanically reconciled against the original query matrix.
      Without automatic reconciliation, the source is a tombstone. Known
      noise (e.g. captured 404) is classified and preserved as evidence,
      never promoted, never deleted.

  - "@id": "{{PREFIX}}:feature:parity-validator"               # I10
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Validador de paridade"}
      - {"@language": en, "@value": "Parity validator"}
    "schema:description": >
      Machine check across surfaces: vocabulary <-> registry <-> prose
      policies <-> TUI <-> code enums <-> doc copies. Runs as a build/CI
      gate; drift is a build error. Registered itself as a feature with
      ingestion_policy EVAL — the law polices itself.
    "{{PREFIX}}:ingestionPolicy": EVAL
    "{{PREFIX}}:status": proposed

  - "@id": "{{PREFIX}}:term:concentric-authority"             # P1
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Autoridade concêntrica"}
      - {"@language": en, "@value": "Concentric authority"}
    "schema:description": >
      Truth has one center and projection rings, never peer fragments.
      Ring 0: this vocabulary (semantic truth; edited only via the rite).
      Ring 1: registry/harness (operational state, validated inward).
      Ring 2: generated projections (prose, prompts, code enums).
      Ring 3: runtime surfaces. Conflicts resolve inward; verification
      points inward. Physical segmentation only by NATURE (declaration vs
      state — hence exactly two files at the center), never by domain.
      Ring 0 is injected whole, by contract — binary state, no fragments.

  - "@id": "{{PREFIX}}:term:atomicity"                        # P2
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Atomicidade"}
      - {"@language": en, "@value": "Atomicity"}
    "schema:description": >
      Units enter whole or not at all. The term is the semantic atom
      (@id); the ingestion rite is an all-or-nothing transaction (no
      half-ingested term); agent components expose closed I/O schemas
      with mustOwn as a declaration of responsibility atomicity; context
      is atomic (ring 0 whole, P1).

  - "@id": "{{PREFIX}}:term:idempotency"                      # P3
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Idempotência"}
      - {"@language": en, "@value": "Idempotency"}
    "schema:description": >
      f(f(x)) = f(x): replaying any step converges to the same state and
      never duplicates effect. Idempotency pairs (correlation id +
      operation name), skip-if-exists + checksum downloads, re-runnable
      validators, byte-stable projection regeneration (enables F3
      verification). The harness is replay-safe for any agent, human or AI.

  - "@id": "{{PREFIX}}:term:determinism"                      # P4
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Determinismo"}
      - {"@language": en, "@value": "Determinism"}
    "schema:description": >
      Same input, same output on the truth path. LLMs stay OFF that path
      (driftGuard is P4 applied to the agentic era); formulas, manifests,
      checksums, and gates stay ON it. Combined with P1-P3 it yields safe
      convergence: any step may be re-executed without fear.

  # ===========================================================================
  # SECTION B — Foundational codelists (I5 · I7)
  # ===========================================================================

  - "@id": "{{PREFIX}}:codelist:shelf-status"                  # I5
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Status de prateleira"}
      - {"@language": en, "@value": "Shelf status"}
    "{{PREFIX}}:validValues": [proposed, active, archived]
    "schema:description": >
      Lifecycle codelist. proposed: awaits operator approval; referenced
      with soft warning. active: in production; references must resolve.
      archived: MUST carry backlog_visibility + reactivation_path (or a
      technical impossibility note). Removal without visible backlog is
      vetoed. (Sotão-strength rule, adopted profile-wide.)

  - "@id": "{{PREFIX}}:codelist:ingestion-policies"            # I7
    "@type": [schema:DefinedTerm, skos:Concept]
    "skos:prefLabel":
      - {"@language": pt-BR, "@value": "Políticas de ingestão"}
      - {"@language": en, "@value": "Ingestion policies"}
    "{{PREFIX}}:validValues":
      [INCREMENTAL, EXTENSAO, STATUS, AJUSTE, FIX, UPGRADE,
       EVAL, BETA, LEGACY, REFINE, FINE-TUNE]
    "schema:description": >
      Closed enumeration classifying every ingestion event. Code copies
      (JSON registry, Pydantic Literals, prose) are caches of this entry;
      the parity validator enforces equality.

  # ===========================================================================
  # SECTION C — Provenance agents (I6)
  # ===========================================================================

  - "@id": "{{PREFIX}}:agent:operator"
    "@type": prov:Agent
    "schema:name": "{{OPERATOR_ID}}"
    "schema:description": >
      ROOT human operator. Source of authority for approvals (I8) and
      lifecycle promotions (I5).

  - "@id": "{{PREFIX}}:agent:ai-assistant"
    "@type": prov:Agent
    "schema:name": "AI agent (template)"
    "schema:description": >
      Template for AI agents authoring entries under operator supervision.
      Each contribution carries dcterms:creator pointing here (or to a
      per-agent @id) and SHOULD carry an opaque correlation id
      (ULID/UUIDv7, emitted once at the envelope boundary and propagated —
      MCID pattern). Never a raw business key.

  # ===========================================================================
  # SECTION D — Domain terms
  # ===========================================================================
  # Grows ONLY via {{PREFIX}}:term:ingestion-rite. Declare-before-use (I1).
  # First domain entries typically: core entities, axes/phases, source
  # systems, event topics. Keep ALL planes (business, design tokens,
  # release process) as SECTIONS of this single file — concentric
  # authority (P1): segment by nature, never by domain. External
  # consumers receive generated projections (ring 2), never editable
  # fragments of the center.
