// <auto-generated/>

#nullable disable

using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Linq;
using OpenAI;
using OpenAI.Evals;

namespace OpenAI.Graders
{
    [Experimental("OPENAI001")]
    public partial class GraderLabelModel : Grader
    {
        internal GraderLabelModel(string name, string model, IEnumerable<InternalEvalItem> input, IEnumerable<string> labels, IEnumerable<string> passingLabels) : base(GraderType.LabelModel)
        {
            Argument.AssertNotNull(name, nameof(name));
            Argument.AssertNotNull(model, nameof(model));
            Argument.AssertNotNull(input, nameof(input));
            Argument.AssertNotNull(labels, nameof(labels));
            Argument.AssertNotNull(passingLabels, nameof(passingLabels));

            Name = name;
            Model = model;
            Input = input.ToList();
            Labels = labels.ToList();
            PassingLabels = passingLabels.ToList();
        }

        internal GraderLabelModel(GraderType kind, IDictionary<string, BinaryData> additionalBinaryDataProperties, string name, string model, IList<InternalEvalItem> input, IList<string> labels, IList<string> passingLabels) : base(kind, additionalBinaryDataProperties)
        {
            // Plugin customization: ensure initialization of collections
            Name = name;
            Model = model;
            Input = input ?? new ChangeTrackingList<InternalEvalItem>();
            Labels = labels ?? new ChangeTrackingList<string>();
            PassingLabels = passingLabels ?? new ChangeTrackingList<string>();
        }

        public string Name { get; set; }

        public string Model { get; set; }

        internal IList<InternalEvalItem> Input { get; }

        public IList<string> Labels { get; }

        public IList<string> PassingLabels { get; }
    }
}
