Docs / Reference / Configuration

Configuration

Every setting is a key in swarmlabre.toml, and every key has a default. This page lists each section and key of swarmlabre.example.toml with its default and its comment.

The file and where it is read#

SwarmLabRE reads one TOML file, swarmlabre.toml, and never writes it. Every key has a default, so a missing file works. Copy swarmlabre.example.toml, which holds every key, and change what you need:

$ cp swarmlabre.example.toml swarmlabre.toml

The first of these that exists is the file: --config, $SWARMLABRE_CONFIG, swarmlabre.toml in the current folder, and ~/.config/swarmlabre/swarmlabre.toml. A --config that names a file which does not exist is an error. swarmlabre.toml is in .gitignore, so it is not committed.

The sections below are the sections of the file, in its order. A key in the file replaces its default; a section that is missing keeps all its defaults. The command line wins over the file where both name the same setting: serve --host and serve --port over [serve], run --tlp over [swarm] tlp, and run --mock and run --replay over [model].

[paths]#

KeyDefaultComment
state"~/.local/state/swarmlabre"runs live in <state>/runs/<run id>; a folder this tool creates is mode 0700

[model]#

The model: any OpenAI-compatible endpoint. The key is read from the environment variable named here, never from this file.

KeyDefaultComment
base_url""for example http://127.0.0.1:8080/v1
api_key_env"SWARMLABRE_API_KEY"the environment variable that holds the key
model""empty = the first model the endpoint lists
temperature0.0pinned on every request the agents make (the gate overwrites what the agent's client asked for)
seed1sent with every request; the manifest of a run says whether the backend honoured it
What the agent program (pi) is told about the model. All optional; 0 / false = say nothing.
context_window0tokens; above 0 pi gets it (and a default output cap of min(32768, context_window / 4) unless max_tokens is set)
max_tokens0output tokens per request; also the cap the request gate puts on every agent request (never below 32768 there); 0 = the default above
reasoningfalsetrue: the model thinks before it answers; pi sends its thinking level
thinking_togglefalsewith reasoning: the endpoint's chat template has an enable_thinking switch pi may turn off
thinking_level"medium"with reasoning: the thinking level pi starts with (a level name pi knows)
extra_body{}Fields added to the planning request that SwarmLabRE itself makes between rounds (the agents' requests are not changed), for example extra_body = { chat_template_kwargs = { enable_thinking = false } }
mock""mock and replay are set by run --mock FILE and run --replay RUN; you rarely write them here. A path to a scripted mock model, or to a recorded run's folder.
replay""

[serve]#

The web UI (swarmlabre serve). It listens on this machine only unless you say otherwise; a non-loopback host prints a warning, because the token is the only protection and the traffic is not encrypted. --host and --port on the command line win over these.

KeyDefaultComment
host"127.0.0.1"address to listen on
port88100 = any free port

[swarm]#

KeyDefaultComment
enabledtruefalse: staging a sample and starting a run are refused
tlp"AMBER"report marking: CLEAR, GREEN, AMBER, AMBER+STRICT, RED (the launch sheet can change it per run)
report_org"""Prepared by" on the cover of a report; empty = no brand bar
report_contact""contact line on the cover; empty = none
report_logofalsedraw swarmlabre/data/logo.png on the cover of report.html (needs report_org; the file is not shipped)
detection_rulestruewrite YARA rules from byte-checked strings; each rule is matched against the sample before it is shown
keep_runs20newest finished runs kept
keep_sampletruefalse: delete the run's copy of the sample once its report is written
max_rounds21 = round 1 only; 2 = the model may plan one more round and settle disputes
max_parallel4model requests in flight (1 to 6)
task_minutes20one agent task
run_minutes0whole run after preparing; 0 = derived from task_minutes
prep_minutes25the preparing phase in the tools container
prewarm_functions40functions decompiled before the agents start
sample_mb256upload limit
max_sample_native_mb4ELF and PE above this are refused: Ghidra's memory grows with the binary
max_sample_apk_mb16APK files above this are refused
tools_memory_gb0tools container cap; 0 = by sample (APK 4, small native 6, larger native 12)
tools_cpus4processors the tools container may use
agent_memory_gb00 = 0.5 + 0.15 per agent (at least 1)
wait_minutes30how long a run waits for memory to be free before it fails
memory_reserve_gb4memory kept free for the host when checking that a run fits
notify_cmd""run when a run ends or waits, with the title and a fixed-template text as two extra arguments, e.g. "notify-send"
SwarmLabRE alpha 0.1.0Edit this page on GitHub