import 'package:json_annotation/json_annotation.dart';

import '../../bean/ai_model.dart';
import '../../bean/intimacy_analyze_direction.dart';

part 'intimacy_analyze_config_response.g.dart';

/// 亲密度配置
@JsonSerializable()
class IntimacyAnalyzeConfigResponse {
  /// 默认分析结果，markdown格式
  @JsonKey(name: 'defaultContent')
  String? defaultContent;

  /// 最大图片上传数
  @JsonKey(name: 'maxImageCount')
  int? maxImageCount;

  /// 最小图片上传数
  @JsonKey(name: 'minImageCount')
  int? minImageCount;

  /// 是否可以自定义方向
  @JsonKey(name: 'custom')
  bool? custom;

  /// 最大自定义字符数
  @JsonKey(name: 'maxCustomWords')
  int? maxCustomWords;

  /// 最小自定义字符数
  @JsonKey(name: 'minCustomWords')
  int? minCustomWords;

  /// 预测方向
  @JsonKey(name: 'direction')
  List<IntimacyAnalyzeDirection>? direction;

  /// 模型选项列表
  @JsonKey(name: 'modes')
  List<AiModel>? modes;

  IntimacyAnalyzeConfigResponse(
    this.defaultContent,
    this.maxImageCount,
    this.minImageCount,
    this.custom,
    this.maxCustomWords,
    this.minCustomWords,
    this.direction,
    this.modes,
  );

  factory IntimacyAnalyzeConfigResponse.fromJson(Map<String, dynamic> json) =>
      _$IntimacyAnalyzeConfigResponseFromJson(json);

  Map<String, dynamic> toJson() => _$IntimacyAnalyzeConfigResponseToJson(this);
}
