Skip to main content
All docs
V25.1
  • ReportPromptToReportBehaviorProperties.RetryAttemptCount Property

    Specifies the number of attempts to fix report layout errors that may appear in the LLM response.

    Namespace: DevExpress.AIIntegration.WinForms.Reporting

    Assembly: DevExpress.AIIntegration.WinForms.Reporting.v25.1.dll

    NuGet Package: DevExpress.AIIntegration.WinForms.Reporting

    Declaration

    [DefaultValue(3)]
    [DXCategory("Behavior")]
    public int RetryAttemptCount { get; set; }

    Property Value

    Type Default Description
    Int32 3

    The number of attempts.

    Remarks

    Use ReportPromptToReportBehavior.Properties to access the behavior’s settings. The following settings are available:

    ReportPromptToReportBehaviorProperties.FixLayoutErrors
    Specifies whether to automatically resolve report control overlapping.
    ReportPromptToReportBehaviorProperties.PredefinedPrompts
    Specifies predefined prompts that can be used to create a report in the Report Wizard.
    ReportPromptToReportBehaviorProperties.RetryAttemptCount
    Specifies the number of attempts to fix report layout errors that may appear in the LLM response.
    ReportPromptToReportBehaviorProperties.Temperature
    Controls output randomness. Lower temperatures (values between 0f and 0.5f) yield more predictable and focused outputs, while higher temperatures (values between 0.5f and 1f) produce more diverse and creative responses. The default value is 0f.

    The following code registers a ReportPromptToReportBehavior and configures its settings:

    using DevExpress.AIIntegration.WinForms.Reporting;
    // ...
    public partial class Form1 : Form {
        public Form1() {
            InitializeComponent();
            behaviorManager1.Attach<ReportPromptToReportBehavior>(reportDesigner1, behavior => {
              // Set the number of attempts.    
              behavior.Properties.RetryAttemptCount = 5;
              // Specify output randomness.
              behavior.Properties.Temperature = 0.6f;
              // Override the built-in prompts collection and display a custom promt.
              behavior.Properties.PredefinedPrompts = new[] {
                new AIReportPrompt() { Title = "Custom Prompt", Text = "Prompt text" }
              };
            });
        }
    }
    

    Review the following help topic for more information on how to use this functionality in the WinForms Report Designer: Prompt-to-Report Behavior in the WinForms Report Designer (CTP).

    See Also