package com.lingyue.ai.dto.ner;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 实体信息
 *
 * @author lingyue
 * @since 2026-01-19
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema(description = "实体信息")
public class EntityInfo {

    @Schema(description = "实体名称")
    private String name;

    @Schema(description = "实体类型", example = "PERSON/ORG/LOC/DATE/NUMBER/DEVICE/TERM")
    private String type;

    @Schema(description = "实体值")
    private String value;

    @Schema(description = "位置信息")
    private PositionInfo position;

    @Schema(description = "上下文片段")
    private String context;

    @Schema(description = "置信度", example = "0.95")
    private Double confidence;

    @Schema(description = "临时ID，用于关系抽取时引用")
    private String tempId;
}
