Why a garak scan takes as long as it does, and how to plan around it
A garak run takes as long as it does because of four multipliers: how many probes run, how many generations garak makes per prompt, how many prompts each probe sends, and how quickly the target endpoint answers. Every attempt is a separate request, so the total is spread across however many concurrent requests the endpoint tolerates. By default garak makes 5 generations per prompt, which is the first lever most teams notice. Planning matters most when the target is a hosted endpoint, when it shares a rate limit with production traffic, or when the scan must finish inside a CI or release window.
The first two levers are the built-in fast config and parallelism. Running garak --config fast sets parallel_attempts to 20 and generations to 3, and it includes probe families such as dan, encoding.InjectBase64, leakreplay, lmrc, malwaregen, packagehallucination, snowball and web_injection. The garak FAQ recommends this config, along with --parallel_attempts set to 20 or 40, for non-local models instead of running every probe. Treat fast as a triage pass that shows whether anything obvious fails, not as full coverage. Confirm the included families against the config file in your installed version, because probe contents change between releases.
Before you schedule a run, write down the request budget. Count the probes selected, multiply by the prompts each probe sends and by the generations per prompt, then compare that total with the rate and concurrency limits the endpoint owner will accept. Ask the owner whether they can sustain 20 or 40 concurrent requests from your scan host, what the endpoint returns when limits are hit, and whether your run window overlaps peak production load. If the total does not fit the window, reduce probe selection or generations first, and record the change alongside the report because each lever alters what the result covers.
Which levers cut scan time most and when each fits
This table compares the main levers that shorten a garak run: probe selection, generations per prompt, prompt caps and parallelism. Read each row for what the lever cuts, what coverage it gives up and the situations where it fits. The main takeaway is that probe selection and generations cut request counts, while parallelism shortens wall-clock time without reducing coverage.
| Lever | What it cuts and what it trades away | When it fits |
|---|---|---|
| Fast config (--config fast) | Runs a reduced probe set instead of every probe. The fast config includes families such as dan, encoding.InjectBase64, leakreplay, lmrc, malwaregen, packagehallucination, snowball and web_injection. Coverage of other families is lost. Check configs/fast.json in your garak version because contents change between releases. | First scans of a new endpoint, CI checks and any run where the goal is a broad signal rather than full coverage. |
| Explicit probe family selection | Cuts requests to the families you name. Anything not selected is untested, so gaps must be recorded in your scan scope. | When you know the application's real exposure, such as a RAG app that needs leakage and injection probes only. |
| Generations per prompt (default 5, fast config 3) | Lowering generations reduces attempts per prompt, so each probe runs fewer times. A single unlucky or lucky sample is more likely to shift the FAIL result, so repeat runs are less comparable. | Regression runs against the same configuration, where you compare trends rather than absolute failure rates. |
| Prompt cap | Limits the number of prompts each probe sends. It cuts requests in every selected probe, but a small cap can miss weaknesses that appear only in later prompts. | Quick smoke tests after a prompt or guardrail change, or when a probe set is very large and time is short. |
| parallel_attempts (fast config 20, FAQ suggests 20 or 40 for non-local models) | Runs more attempts at once against the target. Total requests stay the same, so coverage is unchanged, but the endpoint receives more concurrent load and may return rate-limit errors. | Hosted endpoints with agreed capacity. Confirm the request rate with the endpoint owner before raising it. |
| max_workers | Sets how many worker threads run concurrently inside garak. Higher values use more local resources and file descriptors, and can overwhelm a shared target if not matched to parallel_attempts. | Scan hosts with spare CPU and memory where the bottleneck is waiting on responses. Tune it together with parallel_attempts. |
What the built-in fast config includes and leaves out
For non-local hosted endpoints, the garak FAQ recommends the built-in fast config instead of running every probe, paired with --parallel_attempts set to 20 or 40. The fast config sets parallel_attempts to 20 and generations to 3, so the run sends fewer attempts per prompt than the default of 5 generations while still covering a useful spread of attack types. The probe families it includes are dan, encoding.InjectBase64, leakreplay, lmrc, malwaregen, packagehallucination, snowball and web_injection. Before you start, agree the request rate with the owner of the endpoint, because a parallel setting that suits your account may still overload a shared service.
- Parallelism is set by the config: the fast config starts at 20 parallel attempts, and the FAQ suggests 20 or 40 for non-local models.
- Generations are reduced: 3 generations per prompt instead of the default 5 lowers the number of attempts per probe.
- Families are fixed: the included families are listed in the source file, so confirm them there before you quote coverage.
- Rate limits still apply: a fast run can still trigger throttling on hosted services, so watch the endpoint owner's dashboards.
- Coverage is partial: families outside the list are not exercised by this config.
Check configs/fast.json in the garak repository for the exact probe list of your installed version before you describe the scan to anyone.
For a model loaded on your own GPU, the same fast config still reduces the number of attempts, but the limiting factor is usually the hardware rather than a provider's rate limit. Running 20 parallel attempts against a single local model may queue requests and extend total time, so measure throughput on your host before you raise parallelism. Generation time depends on the model size, context length and the accelerator, none of which the fast config accounts for. Treat the fast config as a way to reduce request count, and use your own timing runs to estimate duration.
- Parallelism needs measurement: a higher parallel setting helps only if the serving stack can process requests concurrently.
- Hardware sets the pace: memory and accelerator capacity determine how many attempts run at once.
- Request count still drops: 3 generations per prompt reduces the total number of model calls compared with the default.
- Family coverage is unchanged: the included families are the same list as for hosted endpoints.
- Timing is yours to record: keep the run logs so later scans on the same host have a baseline.
Confirm the parallel setting with a short timing run on the host where the model is served before scheduling a full job.
When a fast config run is used as a gate, for example on a merge request or before a model or prompt change is promoted, it answers a narrower question than a full assessment. It shows whether the included families still fail on the change, and it gives a quick signal before a longer run. Families not in the fast config are not tested by that gate, so a passing result does not cover them. Plan a scheduled or full run that includes the remaining families before you sign off a release or describe the system as assessed.
- Gate scope is explicit: state in the pipeline definition which families the gate covers.
- Full coverage comes later: schedule a broader run for the families the fast config leaves out.
- Results are compared, not just passed: use the JSONL report from each run to track change between releases.
- Sign-off needs the full set: do not present a fast run as the evidence for a complete review.
- Version pinning matters: record the garak version, because the fast config contents can change between releases.
Before you rely on a gate, read the fast config for your pinned garak version and write down the families that are excluded.
How to run a timed baseline and then tune the scan
This sequence gives you a measured starting point for one garak scan, so each later change to probes, generations or parallelism can be judged against real request counts and error rates instead of estimates.
Prepare a dedicated scan host
Install garak from PyPI on a host you control, using Python 3.11 or newer in an isolated virtual environment. The package is developed on Linux and macOS, so confirm the host meets those platforms before you start. Run the version command and record the version in your scan notes, since reports from different releases can score differently. Done when garak starts without import errors and the version matches the release you plan to use for the whole comparison.
Confirm the target generator configuration
Check the generator settings for the model or application under test, including the endpoint URL, credentials supplied through environment variables rather than files in the repository, and any request timeouts. Make a single small test call so you know the target responds and that the response format matches what the generator expects. Ask the endpoint owner for the request rate they will accept and write it down. Done when one test prompt returns a parseable response and the agreed rate is recorded.
Run the fast config as a timed baseline
Start the built-in fast config with parallel attempts set to 20, as the garak FAQ recommends for non-local models, and time the whole run from start to finish. Keep the same generator, target and garak version for every later run so the timing is comparable. Use a fixed report prefix so the output files are easy to find. Done when the run completes or stops with a recorded reason, and you have the elapsed time and the report location.
Read the JSONL report for request counts
Open the JSONL report written by the run and count the attempts per probe, since each attempt represents one generation request to the target. Compare the total with the number of prompts and generations you expected from the probe selection. Note which probe families produced the most attempts, because those are the first candidates for reduction. Done when you have a table of attempts per probe family and a total that you can reconcile with the configuration.
Check garak.log for errors and retries
Search the garak.log file for timeouts, HTTP error codes, skipped requests and retry messages, since these show where time was lost and whether the endpoint dropped requests. Count how many errors appeared and at which probes, and check whether any failures came from the endpoint owner's rate limits rather than from your configuration. Done when you can state the error count and the probes involved, and any rate-related errors are shared with the endpoint owner.
Change one lever and rerun
Pick one change only, such as removing a probe family, lowering generations or raising parallel attempts, and rerun the same configuration with the same target. Changing several levers at once makes it impossible to tell which one saved time or altered coverage. Before raising parallelism, confirm again with the endpoint owner that the higher request rate is acceptable. Done when the rerun has its own elapsed time and attempt count, and you can state the difference from the baseline.
Record the tuned configuration and its coverage
Save the final configuration file, the garak version, the parallelism setting and the timing results together with the report paths. Note which probe families were removed or reduced, and state the coverage trade-off in plain terms so reviewers understand what the scan no longer tests. Done when another engineer can rerun the scan from the saved configuration and reproduce the same attempt counts.
How a garak run turns probe selection into requests and a report
A run starts when probe selection chooses which probes and detectors to load, then the probewise harness sends each prompt through the generator. The generator fans out attempts in parallel to the target endpoint, which sits behind a trust boundary and is where the request count is actually paid. Responses flow back to detectors and evaluators, which write each attempt to the JSONL report and the garak.log file. Check the report's attempt count against your expected requests to confirm where the time went.
Probe selection drives the request count; the JSONL report shows where it went.
Security and operational risks when you speed up a scan
Shortening a garak run lowers wait time but concentrates load, output and configuration risk into a shorter window. The cards below cover the risks that tend to appear when parallelism, generations and probe selection are turned up, and the checks to put in place before the faster run starts.
Overloading the target endpoint
Raising parallelism sends more concurrent requests to the model or application under test. On a shared or production endpoint, that can trigger rate limits, degrade service for real users or cause an outage. Agree the request rate with the team that runs the endpoint, and start with the fast config's parallel_attempts of 20 before going higher. Ask the endpoint owner whether a test tenant or staging copy exists.
garak FAQHarmful output in logs and reports
A faster scan finishes more attempts in less time, and every attempt is written to the JSONL report and, through garak.log, to the debugging file. Those files can hold prompts and outputs that are harmful, sensitive or policy-violating. Decide before the run who can read them, how long they are kept and where they are deleted, and treat the report directory as restricted data.
API keys in generator configs
Generator configuration files for hosted endpoints often hold API keys or tokens. Those values can leak when a config is pasted into a ticket, committed to a repository, or echoed in a shared CI job log. Load secrets from environment variables or your secrets manager, keep the generator file free of literal keys, and confirm that log output does not print the configuration.
File descriptor exhaustion on the scan host
High parallelism opens many simultaneous connections, and each one consumes a file descriptor on the scan host. When the operating system limit is reached, requests fail in ways that look like target errors rather than host limits, which can skew results. Check the host's open-file limit before raising parallelism, and watch for connection errors in garak.log during a test run.
Unannounced scan traffic
A scan that runs faster also looks different to monitoring. A burst of similar prompts from one source can trip abuse detection, alert the security operations team or count against an API quota. Tell the endpoint owner when scans run, which source addresses they use, and roughly how long the burst lasts, so alerts are not mistaken for an attack.
Coverage gaps hidden by shorter runs
A shortened run can pass while testing less. The fast config and any probe filter reduce the number of probes and generations, and a report that does not record which probes ran makes it hard to tell a clean result from a narrow one. Save the exact configuration and probe list with every run, and compare each shortened run against a documented baseline before reporting results.
Fast config sourceQuestions teams ask about garak scan time and effort
How long does a full garak run take?
It depends mainly on the endpoint's response speed and on how many probes and generations you select, so no single duration applies. A full run sends tens of thousands of requests, and each request waits on the model under test, so a slow or rate-limited endpoint stretches the run far beyond a fast local model. Before committing to a window, time a small probe subset against your real endpoint, count the requests it produced, and extrapolate to the full selection. Ask your engineers to record the endpoint's median latency and any rate limits, since those two numbers set most of the duration.
Is the fast config enough for release gating?
The built-in fast config is a reasonable first gate, but it is a sample of coverage, not a substitute for a full run. The garak FAQ recommends --config fast with --parallel_attempts of 20 or 40 for non-local models instead of running every probe. The fast config sets parallel attempts to 20 and generations to 3, and it includes probe families such as dan, encoding.InjectBase64, leakreplay, lmrc, malwaregen, packagehallucination, snowball and web_injection. Decide with your risk owner which probe families a release must clear, then pair the fast run with a scheduled full scan.
What does raising parallel_attempts to 40 cost in endpoint load?
Raising parallel_attempts to 40 shortens wall-clock time, but it multiplies the number of simultaneous requests your endpoint receives, which can trigger rate limits, timeouts, throttling or cost spikes on a hosted API. The cost lands on the endpoint owner as well as on you, so agree the request rate with whoever runs the target before you change the value. Start at the FAQ's recommended 20, watch error rates and latency in the endpoint's logs, and move to 40 only if the endpoint absorbs the load. Dropped or failed requests can also distort results, so check the report for errors after each change.
What does the work need from our side?
A consultant needs a few things from your team before the scan can be planned well, and most of them are access and agreements rather than code. Typical inputs include:
- Authenticated access to the target endpoint in a test or staging environment, with a clear description of its inputs and outputs
- A written agreement on request rates, timeouts and a contact for the endpoint owner during the run
- A scan host with network reach to the endpoint, enough disk for reports and logs, and a supported Python version
- Named owners for reviewing findings and approving any production-adjacent testing
Can our in-house team run garak timing work alone?
Yes, a capable in-house team can install garak, run the fast config, time a sample and tune parallelism without outside help. The harder part is judgment: choosing probe families that match your application, agreeing rates with endpoint owners, deciding what a shortened run leaves uncovered, and keeping reports comparable across releases. Teams that lack a spare engineer for that work, or that need evidence an assessor will accept, often bring in a partner for the planning and the first tuned configuration, then run the routine scans themselves.
What drives consultant effort, and how does a quote follow from scope?
Effort depends on the number of endpoints, how many application shapes are in scope (for example a bare model versus a RAG pipeline or tool-using agent), how many probe families you need, the amount of endpoint coordination, and how many reruns the agreed fixes require. DeployOpen does not publish a price list. Most engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts, and a quote follows from that written scope. Ask for the list of endpoints, the probe families, the report format, the retest terms and whether the work is one-time or continues as a retainer.
How do we check coverage after shortening a scan?
Compare the shortened run with a full run on the same endpoint at least once, and check that the probe families you care about still produce results. Use the JSONL report to confirm which probes ran, how many generations each used and whether any attempts failed or were skipped. Record which families were removed or reduced and why, so the gap is a known decision rather than a surprise. Shortening should lower request counts without silently dropping the categories your risk owner requires.
How do repeat scans keep timing comparable?
Keep the configuration, parallelism, endpoint version and probe selection fixed across runs, and save each run's config file alongside its report. Without those controls, a change in duration or result may come from a different rate limit or probe set rather than from the model. Store the timing and request count for each run, and rerun the same baseline after any garak upgrade or endpoint change, so the comparison reflects the target rather than the tooling.
What to measure so the next scan is faster and still comparable
Record the settings that shape a scan alongside every run, so that the next timing measurement means something. At minimum, capture the probe list (or the config file that produced it), the number of generations, the system.parallel_attempts value, the endpoint and model identifier under test, and the garak version. Store these next to the JSONL report and the garak.log file from the same run. Without them, a faster scan and a smaller scan look identical in a dashboard, and a later team cannot tell whether a change in results came from the model or from the settings. The garak release history on GitHub is the place to confirm which version you ran, and the version should be written down before you compare any two runs.
Changing these settings changes coverage, not just speed. Dropping generations from the default of 5 to the fast config's 3 means each prompt gets fewer attempts, so a probe that fails only occasionally may pass in a faster run. Narrowing the probe list removes whole categories of weakness from the result. A shorter run is therefore a different test, and its failure rates should not be read against a full run as if both measured the same thing. Decide which profile is your baseline, state it in the report summary, and compare only runs made with the same profile. If you need a quick check on every change and a deeper scan on a schedule, label them as two separate profiles and keep a trend line for each.
Before you rely on a timing figure, run the same profile twice against the same endpoint and confirm that the duration and the failure counts are close. If the endpoint is rate-limited or shared with other users, record the load conditions as well, because a slow run may reflect the target rather than your configuration. Ask the owner of the endpoint to confirm the request rate they accept, and record it with the run. Repeat the baseline after each garak upgrade, since probe updates can change both the request count and the scores. Keeping this small record turns a one-off timing into a comparable measurement that supports planning decisions.
How DeployOpen scopes and runs garak scan planning
This sequence turns an open-ended request for a garak scan into a written plan with agreed probe coverage, request rates and a measured baseline, so the client knows how long a run will take and what it will cost in requests before work starts. Most engagements are fixed-scope, and a quote follows from the written scope.
Confirm the target and its rate limits
DeployOpen first establishes what garak will test: a bare model, a hosted endpoint, a REST application or a guarded pipeline in front of a model. We ask for the provider or hosting arrangement, any published rate limits or quotas, whether the endpoint is shared with production traffic, and who owns it. The step closes with a written description of the target and the limits that bound the scan.
Agree the probe profile with the endpoint owner
We compare the built-in fast config with a full or custom probe selection and map each option to the request volume it implies. The client's security lead and the owner of the endpoint agree which probe families matter for the application's real exposure, how many generations per prompt to run, and whether a prompt cap applies. The output is a written probe profile with the request count it produces and the coverage it gives up, if any.
Set parallelism within the agreed request rate
Using the endpoint's limits and the owner's tolerance for load, we choose a starting value for the system parallel_attempts setting and, where relevant, max_workers. For non-local models, the garak FAQ recommends starting from 20 or 40 parallel attempts. We record the value, the reason for it, and the limit it must not exceed, so the setting can be reviewed if the endpoint changes.
Run and time a baseline scan
DeployOpen runs the agreed profile against a small, bounded slice of the target and records wall-clock time, request count, error and skip rates, and any rate-limit responses. The baseline shows whether the planned settings hold up in practice and gives a measured duration for the full run. We check the garak.log file and the JSONL report to confirm every attempt completed or failed for a known reason.
Adjust settings from the baseline
If the baseline shows throttling, timeouts or dropped requests, we lower parallelism or narrow the probe set and run the baseline again. If it finishes well inside the agreed window, we keep the settings. The step closes when a baseline run completes without unexplained failures and the settings are fixed in a config file that the client can reuse.
Deliver run settings, report and retest guidance
The client receives the final config file, the parallelism and generation values with their reasons, the expected request count, the baseline timings, and instructions for where reports are written. We also explain how to read the JSONL report and what to do if the scan is repeated after a model, prompt or guardrail change. The step is complete when the client's team can run the scan without DeployOpen present.
Confirm scope in writing and agree the quote
Most engagements are fixed-scope. The target, probe profile, parallelism limit, deliverables and timelines are written down and signed off before any full run starts. DeployOpen does not publish a price list, so the quote follows from that written scope and the work it describes. Clients should ask for the scope, the assumptions about endpoint access and rate limits, and what is included after the first delivery.

