// <auto-generated/>

#nullable disable

using System;
using System.Collections.Generic;
using System.Linq;
using OpenAI;

namespace OpenAI.Responses
{
    internal partial class InternalItemContentOutputText : ResponseContentPart
    {
        public InternalItemContentOutputText(IEnumerable<ResponseMessageAnnotation> annotations, string internalText) : base(InternalItemContentType.OutputText)
        {
            Argument.AssertNotNull(annotations, nameof(annotations));
            Argument.AssertNotNull(internalText, nameof(internalText));

            Annotations = annotations.ToList();
            Logprobs = new ChangeTrackingList<InternalLogProb>();
            InternalText = internalText;
        }

        internal InternalItemContentOutputText(InternalItemContentType internalType, IDictionary<string, BinaryData> additionalBinaryDataProperties, IList<ResponseMessageAnnotation> annotations, IList<InternalLogProb> logprobs, string internalText) : base(internalType, additionalBinaryDataProperties)
        {
            // Plugin customization: ensure initialization of collections
            Annotations = annotations ?? new ChangeTrackingList<ResponseMessageAnnotation>();
            Logprobs = logprobs ?? new ChangeTrackingList<InternalLogProb>();
            InternalText = internalText;
        }

        public IList<ResponseMessageAnnotation> Annotations { get; }

        internal IList<InternalLogProb> Logprobs { get; }
    }
}
