ICCMA25 Benchmark Submission: Argumentation Framework Subsampling Generator (AFSG)

This repository contains a benchmark generator submitted for the International Competition on Computational Models of Argumentation (ICCMA) 2025 (https://iccma2025.kr.tuwien.ac.at/). The generator consists of Python scripts designed to create derivative argumentation frameworks (AFs) by subsampling larger source AFs using various techniques.


Overview:

The primary script, af_subsample.py, processes a directory of source AFs provided in the .af format. For each source AF, it generates multiple smaller AFs using four distinct subsampling methods. This allows for the creation of diverse benchmark sets derived from existing, potentially complex, argumentation graphs.

The goal is to provide a tool for generating new benchmark instances, potentially with varying characteristics and difficulty levels, suitable for evaluating argumentation solvers.


Features:

Input Format: Parses argumentation frameworks in the standard AF .

Subsampling Methods: Implements four different strategies for selecting a subset of arguments (nodes) and their induced attacks (edges):

- Random Subsampling (random): Uniformly selects a random subset of the desired proportion of arguments.

- Degree-Based Subsampling (degree): Selects arguments based on their relevance score, calculated primarily as the sum of their in-degree and out-degree. Arguments with higher degrees are prioritized. (Note: The underlying library function degree_extension_subsample can optionally incorporate argument frequency in preferred extensions if a solution file is provided, but the main batch script af_subsample.py currently uses only the degree information.)

- BFS Subsampling (bfs): Performs a Breadth-First Search (also known as "snowball sampling") starting from a random argument. It explores neighbors (attackers and attacked arguments) until the desired proportion of arguments is collected.

- Community-Based Subsampling (community): Detects communities within the (undirected version of the) AF using the greedy modularity maximization algorithm. It then samples arguments proportionally from each detected community to achieve the target overall proportion.


Requirements:

Python 3.x
networkx library (pip install networkx)


Files:

af_subsample.py: The main batch processing script for generating subsampled AFs.
subsampling_lib.py: A library containing the core functions for parsing graphs, implementing the four subsampling methods, and writing output files.
README: This file 


Usage:

The main script af_subsample.py is run from the command line.

python af_subsample.py --source <SOURCE_DIR> --dest <DEST_DIR> [--proportion <P>] [--num <N>] 

Arguments:

--source <SOURCE_DIR>: (Required) Path to the directory containing the source .af files.
--dest <DEST_DIR>: (Required) Path to the directory where the generated subsampled AFs will be saved. Subdirectories for each method (random, degree, bfs, community) will be created here.
--proportion <P>: (Optional) The fraction of nodes to keep in the subsampled graphs (a float between 0 and 1). Default is 0.5.
--num <N>: (Optional) The number of derivative graphs to generate for each method from each source file. Default is 10.
--methods <M>: One or more methods from random, bfs, degree, community

Example:

To process all .af files in the ../source_afs/ directory, generate 5 subsamples for each method, keeping 70% of the nodes, and save them to ../generated_benchmarks/:

python af_subsample.py --source ../source_afs/ --dest ../generated_benchmarks/ --proportion 0.7 --num 5


Output Structure:

The script will create the destination directory (<DEST_DIR>) if it doesn't exist. Inside it, subdirectories for each method will be created. The output files will be named according to the pattern:

<DEST_DIR>/<method>/<original_basename>_<method>_<i>.af

Where:

<method> is one of random, degree, bfs, community.
<original_basename> is the name of the source .af file without the extension.
<i> is the sample index (from 1 to --num).
The generated .af files follow the same input format.


Benchmark Characteristics and Observations:

Based on initial empirical testing (e.g., using solvers like Pyglaf or ConArg), the different subsampling methods tend to produce instances with varying characteristics:

- Degree-Based Subsampling (degree): Especially at higher proportions (e.g., --proportion > 0.7), this method seems to generate instances that are relatively more challenging for standard argumentation solvers. This might be due to the preservation of highly connected arguments, potentially leading to more complex argumentation structures.

- Random Subsampling (random): This method often produces the comparatively easiest instances, likely due to the random disconnection of attack paths.

- BFS and Community Subsampling: These methods often produce instances with intermediate difficulty, preserving local structures (BFS) or community structures (Community) to different extents.

These observations suggest that the generator, particularly using the degree method with appropriate parameters, can be useful for creating challenging benchmark instances for ICCMA. We recommend experimenting with different proportions and source AFs to generate a diverse set of benchmarks.


License:

This software is provided under the MIT License. (You may want to add a LICENSE file or specify license details here).


