| # ResiNet-LLM-topology | |
| This repository contains the implementation for the submission: | |
| > **An LLM-Based Framework for Intent-Driven Network Topology Design** | |
| > *(CNSM submission)* | |
| ## Purpose | |
| `ResiNet-LLM-topology` provides the evaluation pipeline used in our work for comparing generated network topologies against reference designs. | |
| It includes: | |
| - node-level F1 evaluation | |
| - edge-level F1 evaluation | |
| - scenario data and reference topologies used for evaluation | |
| ## Folder layout | |
| ``` | |
| requirements.txt | |
| README.md | |
| data/ | |
| ββ results/ | |
| ββ scenarios/ | |
| ββ topology_scenario_1.json | |
| ββ topology_scenario_2.json | |
| ββ topology_scenario_3.json | |
| ββ topology_scenario_4.json | |
| f1_nodes_functions.py | |
| f1_nodes_main.py | |
| f1_edges_functions.py | |
| f1_edges_main.py | |
| resinet_llm_prompt.py | |
| evaluate_connectivity.py | |
| draw_topology.py | |
| ``` | |
| ## Installation | |
| Install the dependencies with: | |
| ```bash | |
| pip install -r requirements.txt | |
| ``` | |
| ## Quick start | |
| ### Node F1 evaluation | |
| ```bash | |
| python f1_nodes_main.py --gen <generated-json-or-folder> --ref <reference.json> | |
| ``` | |
| ### Edge F1 evaluation | |
| ```bash | |
| python f1_edges_main.py --gen <generated-json-or-folder> --ref <reference.json> | |
| ``` | |
| The scripts produce detailed evaluation logs and summary `.txt` outputs in the local `results/` path next to the evaluated files. | |
| ## File descriptions | |
| - `f1_nodes_functions.py` β helper functions for node normalization, mapping, and F1 calculation. | |
| - `f1_nodes_main.py` β driver script for node-based evaluation and overall summary generation. | |
| - `f1_edges_functions.py` β helper functions for edge cleanup, structural remapping, and edge F1 scoring. | |
| - `f1_edges_main.py` β driver script for edge-based evaluation and final metrics. | |
| - `resinet_llm_prompt.py` β prompt utilities for intent-driven topology generation. | |
| - `evaluate_connectivity.py` β connectivity and resilience measurement helpers. | |
| - `draw_topology.py` β graph drawing utilities. | |
| - `requirements.txt` β Python package dependencies. | |
| ## Repository usage | |
| This package is designed to let users: | |
| 1. inspect the evaluation logic used in the paper, | |
| 2. reproduce node and edge F1 scoring on generated topologies with LLMs using the previous prompts, | |
| 3. compare generated outputs with reference topologies, | |
| ## Notes for publication | |
| - This repository is intended as a reproducibility artifact | |