# #region AxiomConfig [C:5] [TYPE Block] [SEMANTICS config,axiom,indexing]
# @BRIEF Axiom engine configuration — anchor format, indexing rules, tag schema.
# @RATIONALE Single source of truth for the semantic indexing engine. All descriptions in English per MLA token efficiency. Complexity rules use a global tag catalog rather than per-tier duplication (all tags allowed at all tiers per SSOT protocol).

# #region AnchorConfig [C:3] [TYPE Block] [SEMANTICS config,anchor]
anchor:
  format: region
  overrides:
    docs/: brace
    specs/: brace
  syntax: {}
# #endregion AnchorConfig

# #region IndexingConfig [C:3] [TYPE Block] [SEMANTICS config,indexing]
indexing:
  include: []
  exclude:
  - .ai/
  - .git/
  - .venv/
  - __pycache__/
  - node_modules/
  - .pytest_cache/
  - .axiom/
  - '*.txt'
  - '*.log'
  - '*.yaml'
  - '*.yml'
  - '*.json'
  - '*.toml'
  source_dirs:
  - src
  - tests
  - routes
  doc_dirs:
  - docs
  - specs
  - .opencode
  - .specify
  - .opencode/agents
  - .opencode/skills
  - .opencode/command
  - .specify/memory
  - .specify/templates
# #endregion IndexingConfig

# #region GlobalTagCatalog [C:5] [TYPE Block] [SEMANTICS config,tags,global]
# @BRIEF All recognized @-tags — informational, allowed at any tier (C1-C5) per SSOT protocol.
# @INVARIANT Every tag in this catalog has a definition. No tag is forbidden at any tier.
# @RATIONALE Per-tier duplication eliminated — tiers are descriptive, not gatekeeping.
#           A single global catalog enforces the rule: all tags allowed everywhere.
global_tags:
  allowed:
  - ACTION
  - ATOM
  - BRIEF
  - STATE
  - PURPOSE
  - EXAMPLE
  - ERROR
  - RAISES
  - THROWS
  - PRE
  - POST
  - RATIONALE
  - REJECTED
  - INVARIANT
  - DATA_CONTRACT
  - SIDE_EFFECT
  - RELATION
  - LAYER
  - PUBLIC_API
  - SEMANTICS
  - STATUS
  - DEPRECATED
  - REPLACED_BY
  - TEST_CONTRACT
  - TEST_EDGE
  - TEST_INVARIANT
  - TEST_FIXTURE
  - TEST_SCENARIO
  - UX_STATE
  - UX_FEEDBACK
  - UX_RECOVERY
  - UX_REACTIVITY
  - UX_TEST
  - RESTRICTION
  - PARAM
  - RETURN
  - YIELDS
  - TEST
  - DEBT
  - NOTE
  - PROPERTY
  - TYPEDEF
  - CONSTRAINT
  - CONTRACT
  - CRITICAL_TRACE
  - FRAGILE
  - INVARIANT_VIOLATION
  - VALIDATION
  - TEST_DATA
# #endregion GlobalTagCatalog

# #region TagSchema [C:5] [TYPE Block] [SEMANTICS config,tags,schema]
tags:
  C:
    type: string
    multiline: false
    deprecated: true
    deprecated_since: '2026-05-19'
    alias_for: COMPLEXITY
    description: 'DEPRECATED. Use [C:N] in #region header line. @C no longer used.'
    protected: true
    orthogonal: false
    decision_memory: false
  COMPLEXITY:
    type: string
    multiline: false
    enum: ['1','2','3','4','5']
    description: 'Complexity tier (1-5). Canonical format is [C:N] in the #region anchor header. @COMPLEXITY as a tag is accepted for backward compatibility, but [C:N] is preferred.'
    protected: true
    orthogonal: false
    decision_memory: false
  ACTION:
    type: string
    multiline: true
    description: 'Model action. Documents a public model method that mutates state. Svelte 5 Model tag.'
  ATOM:
    type: string
    multiline: false
    description: 'Model state atom. Documents an atomic $state field. Svelte 5 Model tag.'
  BRIEF:
    type: string
    multiline: true
    description: 'Contract purpose. Canonical format for describing what the contract does. Recommended on every function. Preferred over legacy @PURPOSE.'
  PURPOSE:
    type: string
    multiline: true
    alias_for: BRIEF
    description: 'Alias for BRIEF (legacy). Use @BRIEF in new code.'
  STATE:
    type: string
    multiline: true
    description: 'UX FSM state. Documents possible screen states. Svelte 5 Model tag.'
  EXAMPLE:
    type: string
    multiline: true
    description: 'Usage example.'
  ERROR:
    type: string
    multiline: true
    description: 'Exception. @ERROR ValueError. Aliases: RAISES, THROWS.'
  RAISES:
    type: string
    multiline: true
    alias_for: ERROR
    description: 'Alias for ERROR.'
  THROWS:
    type: string
    multiline: true
    alias_for: ERROR
    description: 'Alias for ERROR.'
  DEPRECATED:
    type: string
    multiline: true
    description: 'Deprecation marker. @DEPRECATED v2.5.'
    decision_memory: true
  REPLACED_BY:
    type: string
    multiline: false
    is_reference: true
    description: 'Replacement pointer. @REPLACED_BY NewService.run.'
    decision_memory: true
  SEMANTICS:
    type: array
    multiline: false
    separator: ','
    description: 'Semantic keywords for DSA Indexer search. Orthogonal. Survivability-critical: same-domain contracts must share primary keyword.'
    orthogonal: true
  SIDE_EFFECT:
    type: string
    multiline: false
    description: 'Side effects (I/O, DB, API, network). Recommended on functions with mutations.'
  STATUS:
    type: string
    multiline: false
    description: 'Status: ACTIVE, DEPRECATED, EXPERIMENTAL.'
    orthogonal: true
  TEST_CONTRACT:
    type: string
    multiline: false
    description: 'What the test verifies. Orthogonal.'
    orthogonal: true
  TEST_EDGE:
    type: string
    multiline: false
    description: 'Edge case scenario. Orthogonal. Minimum 3 per production contract: missing_field, invalid_type, external_fail.'
    orthogonal: true
  TEST_FIXTURE:
    type: string
    multiline: false
    description: 'Test fixture. Orthogonal. Use hardcoded values — never algorithmic computation that mirrors implementation.'
    orthogonal: true
  TEST_INVARIANT:
    type: string
    multiline: false
    description: 'Test invariant mapping. @TEST_INVARIANT: name -> VERIFIED_BY: [test_name]. Orthogonal.'
    orthogonal: true
  TEST_SCENARIO:
    type: string
    multiline: false
    description: 'Test scenario. Orthogonal.'
    orthogonal: true
  UX_FEEDBACK:
    type: string
    multiline: false
    description: 'UX feedback format (Toast, Shake, RedBorder, Modal). Component only.'
    orthogonal: true
  UX_REACTIVITY:
    type: string
    multiline: false
    description: 'Reactive model declaration. Component only.'
    orthogonal: true
  UX_RECOVERY:
    type: string
    multiline: false
    description: 'Recovery strategy after error/degraded state. Component only.'
    orthogonal: true
  UX_STATE:
    type: string
    multiline: false
    description: 'UX FSM state mapping. Recommended for multi-state components. Example: @UX_STATE Loading -> Spinner visible, btn disabled.'
  RELATION:
    type: string
    multiline: false
    is_reference: true
    description: 'Graph dependency edge. Links contracts. Recommended on any function/module with external dependencies.'
    allowed_predicates: [DEPENDS_ON, CALLS, INHERITS, IMPLEMENTS, DISPATCHES, BINDS_TO, CALLED_BY, VERIFIES, USES, CONTAINS, BELONGS_TO, ASSOCIATED_WITH]
  PRE:
    type: string
    multiline: true
    description: 'Preconditions. Enforce via explicit if/raise guards — NEVER use assert. Recommended on functions with non-trivial input requirements.'
  POST:
    type: string
    multiline: true
    description: 'Output guarantees. Cascading protection: do NOT alter @POST without verifying upstream @RELATION CALLS consumers.'
  RATIONALE:
    type: string
    multiline: true
    description: 'Architectural decision rationale. WHY this implementation was chosen. Decision Memory — prevents regression loops.'
    decision_memory: true
  REJECTED:
    type: string
    multiline: true
    description: 'Rejected alternative and disqualification reason. WHAT was tried and WHY it failed. Decision Memory — active guardrail against re-implementation.'
    decision_memory: true
  DATA_CONTRACT:
    type: string
    multiline: false
    description: 'DTO mapping: Input -> Output. Recommended on any contract with clear input/output types. Critical for cross-stack alignment (backend Pydantic <-> frontend TypeScript).'
  INVARIANT:
    type: string
    multiline: true
    description: 'Invariant — condition always true. Documents unbreakable guarantees at any level.'
  UX_TEST:
    type: string
    multiline: false
    description: 'Browser-verifiable UX test scenario. Component only.'
    orthogonal: true
  LAYER:
    type: string
    multiline: false
    description: 'Architecture layer: Core, Domain, API, UI, Service, Infrastructure, Plugin, Tests.'
    enum: [Core, Domain, API, UI, Service, Infrastructure, Plugin, Tests, Infra, Frontend, Feature, Page, Component, Widget, Panel, Store, Layout]
    orthogonal: true
  RESTRICTION:
    type: string
    multiline: true
    description: 'Contract restriction (e.g., EXAMPLES ONLY — do not redefine rules from SSOT).'
    orthogonal: true
  PARAM:
    type: string
    multiline: true
    description: 'Function parameter documentation.'
  RETURN:
    type: string
    multiline: true
    description: 'Return value documentation.'
  YIELDS:
    type: string
    multiline: true
    description: 'Generator yield value documentation.'
  RETURNS:
    type: string
    multiline: true
    alias_for: RETURN
    description: 'Alias for RETURN (JSDoc-style).'
  TEST:
    type: string
    multiline: true
    description: 'Test scenario description.'
    orthogonal: true
  DEBT:
    type: string
    multiline: true
    description: 'Documented technical debt.'
    orthogonal: true
  NOTE:
    type: string
    multiline: true
    description: 'Developer note.'
    orthogonal: true
  PROPERTY:
    type: string
    multiline: true
    description: 'Object property/field (JSDoc-style).'
    orthogonal: true
  TYPEDEF:
    type: string
    multiline: true
    description: 'Type definition (JSDoc-style).'
    orthogonal: true
  UI_STATE:
    type: string
    multiline: false
    alias_for: UX_STATE
    description: 'Alias for UX_STATE (legacy). Use @UX_STATE in new code.'
  UX_REATIVITY:
    type: string
    multiline: false
    alias_for: UX_REACTIVITY
    description: 'Typo alias for UX_REACTIVITY (legacy). Use @UX_REACTIVITY.'
  TEST_DATA:
    type: string
    multiline: true
    description: 'Test data or fixture.'
    orthogonal: true
  CONSTRAINT:
    type: string
    multiline: true
    alias_for: INVARIANT
    description: 'Alias for INVARIANT.'
  CONTRACT:
    type: string
    multiline: true
    description: 'Contract or agreement description.'
    orthogonal: true
  CRITICAL_TRACE:
    type: string
    multiline: true
    description: 'Critical trace marker for debugging.'
    orthogonal: true
  FRAGILE:
    type: string
    multiline: true
    description: 'Fragile code/test — may break from changes.'
    orthogonal: true
  INVARIANT_VIOLATION:
    type: string
    multiline: true
    description: 'Documented invariant violation.'
    orthogonal: true
  THROW:
    type: string
    multiline: true
    alias_for: ERROR
    description: 'Alias for ERROR (JSDoc-style).'
  VALIDATION:
    type: string
    multiline: false
    description: 'Validation rule.'
    orthogonal: true
  PUBLIC_API:
    type: string
    multiline: false
    description: 'Public API surface — which classes/functions are entry points.'
    orthogonal: true
# #endregion TagSchema

# #region InfrastructureConfig [C:2] [TYPE Block] [SEMANTICS config,embedding,http]
embedding: null
http_api:
  http_enabled: false
  http_host: 127.0.0.1
  http_port: 8420
  http_api_key: '123'
doc_mode: null
doc_tag_mapping: null
doc_stripped_output: null
doc_symbol_types: null
tier_thresholds: {}
# #endregion InfrastructureConfig

# #endregion AxiomConfig
