simplebench.reporters.rich_table.reporter.config module🔗

Configuration for a RichTableReporter.

class simplebench.reporters.rich_table.reporter.config.RichTableConfig(
*,
name: str | None = None,
description: str | None = None,
sections: set[Section] | None = None,
targets: set[Target] | None = None,
default_targets: set[Target] | None = None,
formats: set[Format] | None = None,
choices: ChoicesConf | None = None,
file_suffix: str | None = None,
file_unique: bool | None = None,
file_append: bool | None = None,
subdir: str | None = None,
)[source]🔗

Bases: ReporterConfig

Configuration for a RichTableReporter.

This class inherits from ReporterConfig and provides a type-safe, discoverable interface for overriding the default settings of a RichTableReporter.

Initialize the RichTableReporter configuration.

Accepts keyword arguments to override any of the default configurations. All arguments are optional. If not provided, the default value for RichTableReporter will be used.

Note

The parameters of this constructor correspond directly to the parameters of the base ReporterConfig class. This design allows users to easily discover and override any configuration option available for the RichTableReporter while maintaining type safety and discoverability through IDEs and documentation tools.

To prevent future breakage, avoid using the ‘rc_’, or ‘rich_table_’ prefixes for any new parameters in subclasses as these are reserved for use by SimpleBench.

Default Values:

  • name: 'rich-table'

  • description: 'Displays benchmark results as a rich text table on the console.'

  • sections: {Section.OPS, Section.TIMING, Section.MEMORY, Section.PEAK_MEMORY}

  • targets: {Target.CONSOLE, Target.FILESYSTEM, Target.CALLBACK}

  • default_targets: {Target.CONSOLE}

  • formats: {Format.RICH_TEXT}

  • choices: A ChoicesConf with predefined ChoiceConf objects for rich table reporting.

  • file_suffix: 'txt'

  • file_unique: False

  • file_append: True

  • subdir: 'rich'

Parameters:
  • name – The name of the reporter.

  • description – A brief description of the reporter.

  • sections – The sections to include in the report.

  • targets – The output targets for the report.

  • default_targets – The default output targets if none are specified.

  • formats – The output formats for the report.

  • choices – The choice configurations for the reporter.

  • file_suffix – The file suffix to use for filesystem outputs.

  • file_unique – Whether to use unique filenames for outputs.

  • file_append – Whether to append to existing files.

  • subdir – The subdirectory to use for filesystem outputs.

Raises: