Skip to content

Commit

Permalink
add experimental features flag to be only accessible in core config
Browse files Browse the repository at this point in the history
  • Loading branch information
leondz committed Nov 15, 2024
1 parent c775303 commit a11d6c4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/source/configurable.rst
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ such as ``show_100_pass_modules``.
* ``verbose`` - Degree of verbosity (values above 0 are experimental, the report & log are authoritative)
* ``narrow_output`` - Support output on narrower CLIs
* ``show_z`` - Display Z-scores and visual indicators on CLI. It's good, but may be too much info until one has seen garak run a couple of times
* ``enable_experimental`` - Enable experimental function CLI flags. Disabled by default. Experimental functions may disrupt your installation and provide unusual/unstable results. Can only be set by editing core config, so a git checkout of garak is recommended for this.

``run`` config items
""""""""""""""""""""
Expand Down
5 changes: 5 additions & 0 deletions garak/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,11 @@ def main(arguments=None) -> None:
help="Launch garak in interactive.py mode",
)

## EXPERIMENTAL FEATURES
if _config.system.enable_experimental:
# place parser argument defs for experimental features here
pass

logging.debug("args - raw argument string received: %s", arguments)

args = parser.parse_args(arguments)
Expand Down
1 change: 1 addition & 0 deletions garak/resources/garak.core.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ system:
parallel_attempts: false
lite: true
show_z: false
enable_experimental: false

run:
seed:
Expand Down

0 comments on commit a11d6c4

Please sign in to comment.