ChatConfidenceMarker

Feedback & Status

답변 신뢰도를 등급으로 표시하는 마커.

Usage

답변 일부의 신뢰도를 등급과 함께 짧게 표시할 때 사용한다.

import

import

import { ChatConfidenceMarker } from '@mildang/design-system/unofficial/Chat';

예제를 복사해 쓸 때 필요한 준비

@mildang/styled-system 은 이 저장소에서 Panda 가 생성하는 산출물이다. 저장소 안에서는 turbo run ship 이후 쓸 수 있고, 패키지 소비자는 자기 Panda 산출물이나 다른 레이아웃 수단으로 바꿔야 한다.

API Reference

ChatConfidenceMarker Props

Prop

Type

Default

level
필수

"medium" | "high" | "low"

지정 안 함

basis

ReactNode

지정 안 함

labels

Partial<ChatConfidenceMarkerLabels>

지정 안 함

value

number

지정 안 함

같은 패밀리

@mildang/design-system/unofficial/Chat 에서 같이 내보내는 컴포넌트다.

예제

높음

import type { ComponentProps } from 'react';
import { ChatConfidenceMarker } from '@mildang/design-system/unofficial/Chat';
type Props = ComponentProps<typeof ChatConfidenceMarker>;
const DEFAULT_ARGS: Props = { level: 'high', value: 94, basis: '출처 3건 일치' };
export default function ConfidenceMarkerHighExample(props: Partial<Props> = {}) { return <ChatConfidenceMarker {...DEFAULT_ARGS} {...props} />; }

보통

import type { ComponentProps } from 'react';
import { ChatConfidenceMarker } from '@mildang/design-system/unofficial/Chat';
type Props = ComponentProps<typeof ChatConfidenceMarker>;
const DEFAULT_ARGS: Props = { level: 'medium', value: 61 };
export default function ConfidenceMarkerMediumExample(props: Partial<Props> = {}) { return <ChatConfidenceMarker {...DEFAULT_ARGS} {...props} />; }

낮음

import type { ComponentProps } from 'react';
import { ChatConfidenceMarker } from '@mildang/design-system/unofficial/Chat';
type Props = ComponentProps<typeof ChatConfidenceMarker>;
const DEFAULT_ARGS: Props = { level: 'low', basis: '검증되지 않음' };
export default function ConfidenceMarkerLowExample(props: Partial<Props> = {}) { return <ChatConfidenceMarker {...DEFAULT_ARGS} {...props} />; }

세 등급 비교

세 등급을 나란히 두어 색 대비를 확인하는 예시다.

import { css } from '@mildang/styled-system/css';
import { ChatConfidenceMarker } from '@mildang/design-system/unofficial/Chat';

const ConfidenceMarkerLevelsExample = () => (
    <div className={css({ display: 'flex', flexWrap: 'wrap', gap: '8' })}>
      <ChatConfidenceMarker level="high" value={94} basis="출처 3건 일치" />
      <ChatConfidenceMarker level="medium" value={61} basis="부분 추론" />
      <ChatConfidenceMarker level="low" value={22} basis="검증되지 않음" />
    </div>
  );

export default ConfidenceMarkerLevelsExample;

문장 인라인

문장 뒤에 인라인으로 붙여 문단 단위 표시를 대신하는 사용법이다.

import { css } from '@mildang/styled-system/css';
import { ChatConfidenceMarker } from '@mildang/design-system/unofficial/Chat';

const ConfidenceMarkerInlineExample = () => (
    <p className={css({ textStyle: 'chat-body', color: 'primary.text.base', maxWidth: '480px' })}>
      2026년 2분기 신규 등록은 전 분기 대비 18% 늘었습니다{' '}
      <ChatConfidenceMarker level="high" value={97} basis="집계 DB" />. 하반기에도 같은 흐름이
      이어질 것으로 보입니다 <ChatConfidenceMarker level="low" basis="추정" />.
    </p>
  );

export default ConfidenceMarkerInlineExample;