{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.Comprehend.Types.EntityRecognizerMetadataEntityTypesListItem where
import Amazonka.Comprehend.Types.EntityTypesEvaluationMetrics
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data EntityRecognizerMetadataEntityTypesListItem = EntityRecognizerMetadataEntityTypesListItem'
{
EntityRecognizerMetadataEntityTypesListItem
-> Maybe EntityTypesEvaluationMetrics
evaluationMetrics :: Prelude.Maybe EntityTypesEvaluationMetrics,
EntityRecognizerMetadataEntityTypesListItem -> Maybe Text
type' :: Prelude.Maybe Prelude.Text,
EntityRecognizerMetadataEntityTypesListItem -> Maybe Int
numberOfTrainMentions :: Prelude.Maybe Prelude.Int
}
deriving (EntityRecognizerMetadataEntityTypesListItem
-> EntityRecognizerMetadataEntityTypesListItem -> Bool
(EntityRecognizerMetadataEntityTypesListItem
-> EntityRecognizerMetadataEntityTypesListItem -> Bool)
-> (EntityRecognizerMetadataEntityTypesListItem
-> EntityRecognizerMetadataEntityTypesListItem -> Bool)
-> Eq EntityRecognizerMetadataEntityTypesListItem
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: EntityRecognizerMetadataEntityTypesListItem
-> EntityRecognizerMetadataEntityTypesListItem -> Bool
$c/= :: EntityRecognizerMetadataEntityTypesListItem
-> EntityRecognizerMetadataEntityTypesListItem -> Bool
== :: EntityRecognizerMetadataEntityTypesListItem
-> EntityRecognizerMetadataEntityTypesListItem -> Bool
$c== :: EntityRecognizerMetadataEntityTypesListItem
-> EntityRecognizerMetadataEntityTypesListItem -> Bool
Prelude.Eq, ReadPrec [EntityRecognizerMetadataEntityTypesListItem]
ReadPrec EntityRecognizerMetadataEntityTypesListItem
Int -> ReadS EntityRecognizerMetadataEntityTypesListItem
ReadS [EntityRecognizerMetadataEntityTypesListItem]
(Int -> ReadS EntityRecognizerMetadataEntityTypesListItem)
-> ReadS [EntityRecognizerMetadataEntityTypesListItem]
-> ReadPrec EntityRecognizerMetadataEntityTypesListItem
-> ReadPrec [EntityRecognizerMetadataEntityTypesListItem]
-> Read EntityRecognizerMetadataEntityTypesListItem
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [EntityRecognizerMetadataEntityTypesListItem]
$creadListPrec :: ReadPrec [EntityRecognizerMetadataEntityTypesListItem]
readPrec :: ReadPrec EntityRecognizerMetadataEntityTypesListItem
$creadPrec :: ReadPrec EntityRecognizerMetadataEntityTypesListItem
readList :: ReadS [EntityRecognizerMetadataEntityTypesListItem]
$creadList :: ReadS [EntityRecognizerMetadataEntityTypesListItem]
readsPrec :: Int -> ReadS EntityRecognizerMetadataEntityTypesListItem
$creadsPrec :: Int -> ReadS EntityRecognizerMetadataEntityTypesListItem
Prelude.Read, Int -> EntityRecognizerMetadataEntityTypesListItem -> ShowS
[EntityRecognizerMetadataEntityTypesListItem] -> ShowS
EntityRecognizerMetadataEntityTypesListItem -> String
(Int -> EntityRecognizerMetadataEntityTypesListItem -> ShowS)
-> (EntityRecognizerMetadataEntityTypesListItem -> String)
-> ([EntityRecognizerMetadataEntityTypesListItem] -> ShowS)
-> Show EntityRecognizerMetadataEntityTypesListItem
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [EntityRecognizerMetadataEntityTypesListItem] -> ShowS
$cshowList :: [EntityRecognizerMetadataEntityTypesListItem] -> ShowS
show :: EntityRecognizerMetadataEntityTypesListItem -> String
$cshow :: EntityRecognizerMetadataEntityTypesListItem -> String
showsPrec :: Int -> EntityRecognizerMetadataEntityTypesListItem -> ShowS
$cshowsPrec :: Int -> EntityRecognizerMetadataEntityTypesListItem -> ShowS
Prelude.Show, (forall x.
EntityRecognizerMetadataEntityTypesListItem
-> Rep EntityRecognizerMetadataEntityTypesListItem x)
-> (forall x.
Rep EntityRecognizerMetadataEntityTypesListItem x
-> EntityRecognizerMetadataEntityTypesListItem)
-> Generic EntityRecognizerMetadataEntityTypesListItem
forall x.
Rep EntityRecognizerMetadataEntityTypesListItem x
-> EntityRecognizerMetadataEntityTypesListItem
forall x.
EntityRecognizerMetadataEntityTypesListItem
-> Rep EntityRecognizerMetadataEntityTypesListItem x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep EntityRecognizerMetadataEntityTypesListItem x
-> EntityRecognizerMetadataEntityTypesListItem
$cfrom :: forall x.
EntityRecognizerMetadataEntityTypesListItem
-> Rep EntityRecognizerMetadataEntityTypesListItem x
Prelude.Generic)
newEntityRecognizerMetadataEntityTypesListItem ::
EntityRecognizerMetadataEntityTypesListItem
newEntityRecognizerMetadataEntityTypesListItem :: EntityRecognizerMetadataEntityTypesListItem
newEntityRecognizerMetadataEntityTypesListItem =
EntityRecognizerMetadataEntityTypesListItem' :: Maybe EntityTypesEvaluationMetrics
-> Maybe Text
-> Maybe Int
-> EntityRecognizerMetadataEntityTypesListItem
EntityRecognizerMetadataEntityTypesListItem'
{ $sel:evaluationMetrics:EntityRecognizerMetadataEntityTypesListItem' :: Maybe EntityTypesEvaluationMetrics
evaluationMetrics =
Maybe EntityTypesEvaluationMetrics
forall a. Maybe a
Prelude.Nothing,
$sel:type':EntityRecognizerMetadataEntityTypesListItem' :: Maybe Text
type' = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:numberOfTrainMentions:EntityRecognizerMetadataEntityTypesListItem' :: Maybe Int
numberOfTrainMentions =
Maybe Int
forall a. Maybe a
Prelude.Nothing
}
entityRecognizerMetadataEntityTypesListItem_evaluationMetrics :: Lens.Lens' EntityRecognizerMetadataEntityTypesListItem (Prelude.Maybe EntityTypesEvaluationMetrics)
entityRecognizerMetadataEntityTypesListItem_evaluationMetrics :: (Maybe EntityTypesEvaluationMetrics
-> f (Maybe EntityTypesEvaluationMetrics))
-> EntityRecognizerMetadataEntityTypesListItem
-> f EntityRecognizerMetadataEntityTypesListItem
entityRecognizerMetadataEntityTypesListItem_evaluationMetrics = (EntityRecognizerMetadataEntityTypesListItem
-> Maybe EntityTypesEvaluationMetrics)
-> (EntityRecognizerMetadataEntityTypesListItem
-> Maybe EntityTypesEvaluationMetrics
-> EntityRecognizerMetadataEntityTypesListItem)
-> Lens
EntityRecognizerMetadataEntityTypesListItem
EntityRecognizerMetadataEntityTypesListItem
(Maybe EntityTypesEvaluationMetrics)
(Maybe EntityTypesEvaluationMetrics)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EntityRecognizerMetadataEntityTypesListItem' {Maybe EntityTypesEvaluationMetrics
evaluationMetrics :: Maybe EntityTypesEvaluationMetrics
$sel:evaluationMetrics:EntityRecognizerMetadataEntityTypesListItem' :: EntityRecognizerMetadataEntityTypesListItem
-> Maybe EntityTypesEvaluationMetrics
evaluationMetrics} -> Maybe EntityTypesEvaluationMetrics
evaluationMetrics) (\s :: EntityRecognizerMetadataEntityTypesListItem
s@EntityRecognizerMetadataEntityTypesListItem' {} Maybe EntityTypesEvaluationMetrics
a -> EntityRecognizerMetadataEntityTypesListItem
s {$sel:evaluationMetrics:EntityRecognizerMetadataEntityTypesListItem' :: Maybe EntityTypesEvaluationMetrics
evaluationMetrics = Maybe EntityTypesEvaluationMetrics
a} :: EntityRecognizerMetadataEntityTypesListItem)
entityRecognizerMetadataEntityTypesListItem_type :: Lens.Lens' EntityRecognizerMetadataEntityTypesListItem (Prelude.Maybe Prelude.Text)
entityRecognizerMetadataEntityTypesListItem_type :: (Maybe Text -> f (Maybe Text))
-> EntityRecognizerMetadataEntityTypesListItem
-> f EntityRecognizerMetadataEntityTypesListItem
entityRecognizerMetadataEntityTypesListItem_type = (EntityRecognizerMetadataEntityTypesListItem -> Maybe Text)
-> (EntityRecognizerMetadataEntityTypesListItem
-> Maybe Text -> EntityRecognizerMetadataEntityTypesListItem)
-> Lens
EntityRecognizerMetadataEntityTypesListItem
EntityRecognizerMetadataEntityTypesListItem
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EntityRecognizerMetadataEntityTypesListItem' {Maybe Text
type' :: Maybe Text
$sel:type':EntityRecognizerMetadataEntityTypesListItem' :: EntityRecognizerMetadataEntityTypesListItem -> Maybe Text
type'} -> Maybe Text
type') (\s :: EntityRecognizerMetadataEntityTypesListItem
s@EntityRecognizerMetadataEntityTypesListItem' {} Maybe Text
a -> EntityRecognizerMetadataEntityTypesListItem
s {$sel:type':EntityRecognizerMetadataEntityTypesListItem' :: Maybe Text
type' = Maybe Text
a} :: EntityRecognizerMetadataEntityTypesListItem)
entityRecognizerMetadataEntityTypesListItem_numberOfTrainMentions :: Lens.Lens' EntityRecognizerMetadataEntityTypesListItem (Prelude.Maybe Prelude.Int)
entityRecognizerMetadataEntityTypesListItem_numberOfTrainMentions :: (Maybe Int -> f (Maybe Int))
-> EntityRecognizerMetadataEntityTypesListItem
-> f EntityRecognizerMetadataEntityTypesListItem
entityRecognizerMetadataEntityTypesListItem_numberOfTrainMentions = (EntityRecognizerMetadataEntityTypesListItem -> Maybe Int)
-> (EntityRecognizerMetadataEntityTypesListItem
-> Maybe Int -> EntityRecognizerMetadataEntityTypesListItem)
-> Lens
EntityRecognizerMetadataEntityTypesListItem
EntityRecognizerMetadataEntityTypesListItem
(Maybe Int)
(Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EntityRecognizerMetadataEntityTypesListItem' {Maybe Int
numberOfTrainMentions :: Maybe Int
$sel:numberOfTrainMentions:EntityRecognizerMetadataEntityTypesListItem' :: EntityRecognizerMetadataEntityTypesListItem -> Maybe Int
numberOfTrainMentions} -> Maybe Int
numberOfTrainMentions) (\s :: EntityRecognizerMetadataEntityTypesListItem
s@EntityRecognizerMetadataEntityTypesListItem' {} Maybe Int
a -> EntityRecognizerMetadataEntityTypesListItem
s {$sel:numberOfTrainMentions:EntityRecognizerMetadataEntityTypesListItem' :: Maybe Int
numberOfTrainMentions = Maybe Int
a} :: EntityRecognizerMetadataEntityTypesListItem)
instance
Core.FromJSON
EntityRecognizerMetadataEntityTypesListItem
where
parseJSON :: Value -> Parser EntityRecognizerMetadataEntityTypesListItem
parseJSON =
String
-> (Object -> Parser EntityRecognizerMetadataEntityTypesListItem)
-> Value
-> Parser EntityRecognizerMetadataEntityTypesListItem
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"EntityRecognizerMetadataEntityTypesListItem"
( \Object
x ->
Maybe EntityTypesEvaluationMetrics
-> Maybe Text
-> Maybe Int
-> EntityRecognizerMetadataEntityTypesListItem
EntityRecognizerMetadataEntityTypesListItem'
(Maybe EntityTypesEvaluationMetrics
-> Maybe Text
-> Maybe Int
-> EntityRecognizerMetadataEntityTypesListItem)
-> Parser (Maybe EntityTypesEvaluationMetrics)
-> Parser
(Maybe Text
-> Maybe Int -> EntityRecognizerMetadataEntityTypesListItem)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe EntityTypesEvaluationMetrics)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"EvaluationMetrics")
Parser
(Maybe Text
-> Maybe Int -> EntityRecognizerMetadataEntityTypesListItem)
-> Parser (Maybe Text)
-> Parser
(Maybe Int -> EntityRecognizerMetadataEntityTypesListItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Type")
Parser (Maybe Int -> EntityRecognizerMetadataEntityTypesListItem)
-> Parser (Maybe Int)
-> Parser EntityRecognizerMetadataEntityTypesListItem
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NumberOfTrainMentions")
)
instance
Prelude.Hashable
EntityRecognizerMetadataEntityTypesListItem
instance
Prelude.NFData
EntityRecognizerMetadataEntityTypesListItem