{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "reasoning-effort",
  "title": "Reasoning Effort",
  "description": "How hard the model thinks, as a row of levels with a mark that slides to the chosen one.",
  "dependencies": [
    "@kind-ui/agent-ui@0.9.0",
    "@ui-sdk/core@0.1.0-beta.17",
    "@ui-sdk/react@0.1.0-beta.17"
  ],
  "registryDependencies": [
    "@kind-ui/agent-ui-setup",
    "@kind-ui/internal-segmented-control"
  ],
  "files": [
    {
      "path": "packages/agent-ui/src/react/reasoning-effort.tsx",
      "content": "\"use client\";\n\nimport { reasoningEffortPrimitive } from \"@kind-ui/agent-ui/core\";\nimport { createParts } from \"@ui-sdk/react/primitive\";\nimport type { ComponentProps, ReactNode } from \"react\";\nimport {\n  KindSegmentedControl,\n  KindSegmentedControlIndicator,\n  KindSegmentedControlItem,\n} from \"./internal/segmented-control\";\n\nconst parts = createParts(reasoningEffortPrimitive, { root: \"div\" });\n\nexport type ReasoningEffortProps = Omit<ComponentProps<typeof parts.Root>, \"children\"> & {\n  children?: ReactNode;\n};\n\n/**\n * How hard the model thinks, as a row of levels with a mark that slides to the chosen one. Any `children` replace the\n * mark and the levels, inside the Segmented Control.\n */\nexport function ReasoningEffort({ children, ...props }: ReasoningEffortProps) {\n  return (\n    <parts.Root {...props}>\n      {({ levels, ...control }) => (\n        // Hidden from agents, which use the Reasoning Effort's own `setValue`.\n        <KindSegmentedControl {...control} data-agent-hidden=\"\">\n          {children !== undefined ? (\n            children\n          ) : (\n            <>\n              <ReasoningEffortIndicator />\n              {levels.map((level) => (\n                <ReasoningEffortItem key={level.value} value={level.value}>\n                  {level.label}\n                </ReasoningEffortItem>\n              ))}\n            </>\n          )}\n        </KindSegmentedControl>\n      )}\n    </parts.Root>\n  );\n}\n\n/** The mark behind the chosen level. */\nexport const ReasoningEffortIndicator = KindSegmentedControlIndicator;\n\n/** A level, whose `value` is what the host receives. */\nexport const ReasoningEffortItem = KindSegmentedControlItem;\n",
      "type": "registry:ui",
      "target": "@ui/reasoning-effort.tsx"
    }
  ],
  "meta": {
    "layer": "react"
  },
  "type": "registry:ui"
}
