agentsclimarketplace

Opp repl filtering

Skill tabgab/opp_repl-skill/opp-repl-filtering

Composable Anthropic-format Agent Skills for driving OMNeT++ simulations via opp_repl. Works in Claude, Windsurf, and any SKILL.md-aware agent.

Install
npx -y skills add tabgab/opp_repl-skill --skill opp-repl-filtering

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

The shared filter vocabulary used by EVERY opp_repl function that selects simulation configs or tasks — regex include/exclude pairs (filter/exclude_filter, working_directory_filter, ini_file_filter, config_filter, run_number_filter), the simulation_config_filter predicate, and full_match. Load whenever you need to narrow down which simulations run, test, compare, or update.

SKILL.md

5.1 KB, as published. Nobody here has run it

Filtering configs and tasks

Virtually every opp_repl entry point — run_simulations(), get_simulation_tasks(), run_smoke_tests(), run_fingerprint_tests(), update_*_test_results(), compare_simulations(), ... — uses the SAME filter vocabulary. Learn it once; apply it everywhere.

Upstream references:

Regex include/exclude pairs

A config is kept ONLY when every specified include filter matches and no exclude filter matches. Filters are substring regex matches unless full_match=True.

IncludeExcludeMatches against
filterexclude_filterFull config string repr
working_directory_filterexclude_working_directory_filterWorking directory path
ini_file_filterexclude_ini_file_filterINI file name
config_filterexclude_config_filter[Config X] section name
run_number_filterexclude_run_number_filterRun number as string

run_number_filter is only effective on functions that enumerate task-level objects (get_simulation_tasks(), run_simulations(), and the test runners). Pure config-level functions ignore it.

The predicate filter

simulation_config_filter accepts a Python callable (SimulationConfig) -> bool. It runs after the regex filters. The default predicate drops abstract and emulation configs — so if you want to run those, pass simulation_config_filter=lambda c: True.

Example — only fingerprint-tested configs with ≥ 10 runs:

run_simulations(
    simulation_config_filter=lambda c: c.num_runs >= 10,
    config_filter="Fingerprint")

full_match

full_match=True (default False) promotes regex matching from substring to whole-string. Handy when your pattern otherwise catches too much:

run_simulations(config_filter="General", full_match=True)
# matches only `[Config General]`, not e.g. `GeneralSetup`.

Run-number shortcuts

For single-task selection get_simulation_task() accepts the scalar run_number=N in addition to the regex filter. When it is set, opp_repl narrows to exactly that run and errors out if there's still ambiguity.

REPL vs. CLI

The shell wrappers translate each Python keyword to the identical kebab-case flag:

Python keywordShell flag
filter--filter
working_directory_filter--working-directory-filter
config_filter--config-filter
run_number_filter--run-number-filter
exclude_config_filter--exclude-config-filter

full_match is a Python-API-only keyword argument; there is no CLI equivalent. Predicate filters are REPL-only (they require a Python callable).

Recipes

Just the examples/ethernet area of INET:

run_simulations(simulation_project=inet_project,
                working_directory_filter="examples/ethernet")

Everything EXCEPT emulation and PureAloha:

run_simulations(exclude_working_directory_filter="emulation",
                exclude_config_filter="PureAloha")

Only run 0 of every config:

get_simulation_tasks(run_number_filter="^0$", full_match=True)

Abstract configs (normally excluded) — inspect only, don't run:

cfgs = inet_project.get_simulation_configs(
    simulation_config_filter=lambda c: c.abstract)

Pitfalls

  • Regex — not glob. * alone is a regex syntax error; use .*.
  • Because filters are substring by default, config_filter="A" matches A, Aloha, TandemA, ... . Anchor with ^...$ or set full_match=True.
  • run_number_filter is a regex on the string form of the number; "1" matches 1, 10, 11, ... . Use "^1$" or exclude_run_number_filter="[02-9]" for exact matches.
  • simulation_config_filter REPLACES the default predicate; passing one means abstract/emulation configs are no longer auto-excluded unless your predicate does it itself.

See also

  • opp-repl-concepts — how configs relate to projects and tasks.
  • opp-repl-running-simulationsrun_simulations() in context.
  • opp-repl-tasks-and-results — filtering result sets after a run.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.