// </snippet_analyze_response>

    // <snippet_manage>
    private static async Task ManageModels(
        FormRecognizerClient trainingClient, string trainingFileUrl)
    {
        // </snippet_manage>
        // <snippet_manage_model_count>
        // Check number of models in the FormRecognizer account, 
        // and the maximum number of models that can be stored.
        AccountProperties accountProperties = trainingClient.GetAccountProperties();
        Console.WriteLine($"Account has {accountProperties.CustomModelCount} models.");
        Console.WriteLine($"It can have at most {accountProperties.CustomModelLimit}" +
            $" models.");
        // </snippet_manage_model_count>

        // <snippet_manage_model_list>
        // List the first ten or fewer models currently stored in the account.
        Pageable<CustomFormModelInfo> models = trainingClient.GetModelInfos();
        
        foreach (CustomFormModelInfo modelInfo in models.Take(10))
        {
            Console.WriteLine($"Custom Model Info:");
            Console.WriteLine($"    Model Id: {modelInfo.ModelId}");
            Console.WriteLine($"    Model Status: {modelInfo.Status}");
            Console.WriteLine($"    Created On: {modelInfo.CreatedOn}");
            Console.WriteLine($"    Last Modified: {modelInfo.LastModified}");
        }
        // </snippet_manage_model_list>

        // <snippet_manage_model_get>
        // Create a new model to store in the account
        CustomFormModel model = await trainingClient.StartTrainingAsync(
            new Uri(trainingFileUrl)).WaitForCompletionAsync();
        
        // Get the model that was just created
        CustomFormModel modelCopy = trainingClient.GetCustomModel(model.ModelId);
        
        Console.WriteLine($"Custom Model {modelCopy.ModelId} recognizes the following" +
            " form types:");
        
        foreach (CustomFormSubModel subModel in modelCopy.Models)
        {
            Console.WriteLine($"SubModel Form Type: {subModel.FormType}");
            foreach (CustomFormModelField field in subModel.Fields.Values)
            {
                Console.Write($"    FieldName: {field.Name}");
                if (field.Label != null)
                {
                    Console.Write($", FieldLabel: {field.Label}");
                }
                Console.WriteLine("");
            }
        }
        // </snippet_manage_model_get>

        // <snippet_manage_model_delete>
        // Delete the model from the account.
        trainingClient.DeleteModel(model.ModelId);
    }