{
  "schema": "freshvibe-way-v8.smart-hooks",
  "schema_version": "1.0.0",
  "app_id": "studio.oscar.platform",
  "version": "0.1.0",
  "doctrinal_basis": "FWV v8 v0.10.0 §16.5 (hooks.json declares which hooks smart features expose)",

  "hooks": {
    "askOscar": {
      "id": "askOscar",
      "module": "assistant",
      "file": "app/src/assistant/ask.ts",
      "signature": "(prompt: string, history?: string[]) => Promise<AskResult>",
      "exposed_by": ["writing/draft.ts", "SmartAdapter.complete()"],
      "purpose": "Single entrypoint for ALL AI generation (writing + assistant)"
    },
    "onAnchorPush": {
      "id": "onAnchorPush",
      "module": "assistant",
      "file": "app/src/assistant/BackStack.ts",
      "signature": "(anchor: Anchor) => void",
      "exposed_by": ["SheetFull", "SheetMin"],
      "purpose": "BackStack emits on push (preserves anchors per RT-1.2)"
    },
    "onStateTransition": {
      "id": "onStateTransition",
      "module": "assistant",
      "file": "app/src/assistant/state-machine.ts",
      "signature": "(trigger: TransitionTrigger) => DockState",
      "exposed_by": ["AssistantDock"],
      "purpose": "Dock state machine transitions"
    },
    "setActiveAdapter": {
      "id": "setActiveAdapter",
      "module": "intelligence",
      "file": "app/src/intelligence/ArboricultureProvider.ts",
      "signature": "(adapter: LlmAdapter) => void",
      "exposed_by": ["Settings (provider select)"],
      "purpose": "Switch active LLM adapter (stub/smart/anthropic/openai/local)"
    },
    "onSave": {
      "id": "onSave",
      "module": "ux",
      "file": "app/src/ux/UndoToast.tsx",
      "signature": "(action: string, undo: () => void) => void",
      "exposed_by": ["Survey/Note/Report/Blog save flows"],
      "purpose": "UndoToast hook (currently UNWIRED per Phase 8 audit; will be wired in B2)"
    }
  }
}
