diff --git a/Model_Library b/Model_Library
index eedf77f1e62b29c8ffbf012f6d9b634d155efdaf..1d0e19b23f9d69ae0bef98e48522d01cfbf7e797 160000
--- a/Model_Library
+++ b/Model_Library
@@ -1 +1 @@
-Subproject commit eedf77f1e62b29c8ffbf012f6d9b634d155efdaf
+Subproject commit 1d0e19b23f9d69ae0bef98e48522d01cfbf7e797
diff --git a/README.md b/README.md
index a0d07a9dfdb56d09cb50ecb26ebfba45a22cc46d..c80186675aa656fc9151086b4448ffc01d1af2b9 100644
--- a/README.md
+++ b/README.md
@@ -161,7 +161,7 @@ The ineed-dc-framework repository is the framework's main repository. It contain
 The sub-repository Model_Libary contains the mathematical models of component, prosumer, quarter, and city levels. 
 
   - `Components/` : Contains all component models and initialized pre-configured components
-  - `Prosumer/` : Includes BaseProsumer model whhich allows to flexibily model any Prosumer application
+  - `Prosumer/` : Includes Prosumer model whhich allows to flexibily model any Prosumer application
   - `District/` : Will contain district level model (implementation in progress).
   - `City/` : Will contain city level model (implementation in progress).
 
diff --git a/Tooling b/Tooling
index 0c0e53de7c208ec319d660072c45e3e206f801b5..70c50a8cd16381928ed5e162b03f214750889a13 160000
--- a/Tooling
+++ b/Tooling
@@ -1 +1 @@
-Subproject commit 0c0e53de7c208ec319d660072c45e3e206f801b5
+Subproject commit 70c50a8cd16381928ed5e162b03f214750889a13
diff --git a/input_files/convert_input_files_released_focused_refactoring.py b/input_files/convert_input_files_released_focused_refactoring.py
new file mode 100644
index 0000000000000000000000000000000000000000..6664da3b65cb4cec2e0c09ebcb87f398fea52220
--- /dev/null
+++ b/input_files/convert_input_files_released_focused_refactoring.py
@@ -0,0 +1,125 @@
+"""
+This script inspects the input files and modifies them such that they adhere to the new input file specification used by the framework after merge of merge request !13 Release focused refactoring.
+"""
+
+import os.path
+import pandas as pd
+
+def component_to_commodities(type):
+    if type == "AbsorptionChiller":
+        return "heat", "cold", None
+    if type == "CompressorChiller":
+        return "electricity", "cold", None
+    if type == "CoolConsumption":
+        return "cold", None, None
+    if type == "CoolGrid":
+        return "cold", "cold", None
+    if type == "ChargingInfrastructure":
+        return "electricity", None, None
+    if type == "ElectricalBusBar":
+        return "electricity", "electricity", None
+    if type == "ElectricalConsumption":
+        return "electricity", None, None
+    if type == "ElectricalGrid":
+        return "electricity", "electricity", None
+    if type == "PVGenerator":
+        return None, "electricity", None
+    if type == "DynamicInverter":
+        return "electricity", "electricity", None
+    if type == "StaticInverter":
+        return "electricity", "electricity", None
+    if type == "LiionBattery":
+        return "electricity", "electricity", None
+    if type == "BHKW":
+        return "gas", "heat", "electricity"
+    if type == "CHP":
+        return "gas", "heat", "electricity"
+    if type == "GasGrid":
+        return "gas", "gas", None
+    if type == "ElectricBoiler":
+        return "electricity", "heat", None
+    if type == "GasBoiler":
+        return "gas", "heat", None
+    if type == "HeatGrid":
+        return "heat", "heat", None
+    if type == "ElectricRadiator":
+        return "electricity", "heat", None
+    if type == "HeatConsumption":
+        return "heat", None, None
+    if type == "Radiator":
+        return "heat", None, None
+    if type == "UnderfloorHeat":
+        return "heat", "heat", None
+    if type == "HeatExchanger":
+        return "heat", "heat", None
+    if type == "GasHeatPump":
+        return "gas", "heat", None
+    if type == "HeatPump":
+        return "electricity", "heat", None
+    if type == "HotWaterConsumption":
+        return "heat", None, None
+    if type == "SolarThermalCollector":
+        return None, "heat", None
+    if type == "HotWaterStorage":
+        return "heat", "heat", None
+    if type == "PEMElectrolyzer":
+        return "electricity", "hydrogen", None
+    if type == "PEMFuelCell":
+        return "hydrogen", "electricity", "heat"
+    if type == "PEMElectrolyzer":
+        return "electricity", "hydrogen", None
+    if type == "PressureStorage":
+        return "hydrogen", "hydrogen", None
+    raise KeyError
+
+changed_topologies = []
+invalid_topologies = []
+for dirpath, dirnames, filenames in os.walk(".\\input_files"):
+    components_here = False
+    connections_here = False
+    for filename in filenames:
+        if filename == "components.csv":
+            components_file = filename
+            components_here = True
+        elif filename == "connections.csv":
+            connections_file = filename
+            connections_here = True
+    
+    if components_here and connections_here:
+        try:
+            print(f"Inspecting topology {dirpath}")
+            components_df = pd.read_csv(os.path.join(dirpath, components_file))
+            components = {}
+            for i in components_df.index:
+                components[components_df["name"][i]] = components_df.loc[i]
+            connections = pd.read_csv(os.path.join(dirpath, connections_file))
+            connections['output'] = pd.Series("", index = connections.index)
+            connections['input'] = pd.Series("", index = connections.index)
+            for i in connections.index:
+                commodity = connections['sector'][i]
+                connection_from = connections['from'][i]
+                connection_to = connections['to'][i]
+                from_type = components[connection_from]['type']
+                input_commodity, output_commodity_1, output_commodity_2 = component_to_commodities(from_type)
+                if commodity == output_commodity_1:
+                    connections['output'][i] = "1"
+                elif commodity == output_commodity_2:
+                    connections['output'][i] = "2"
+                else:
+                    raise KeyError
+                to_type = components[connection_to]['type']
+                input_commodity, output_commodity_1, output_commodity_2 = component_to_commodities(to_type)
+                if commodity == input_commodity:
+                    connections['input'][i] = ""
+                else:
+                    raise KeyError
+            connections.drop("sector", axis = 1)
+            connections = connections[["from", "output", "to", "input"]]
+            changed_topologies.append(dirpath)
+            connections.to_csv(os.path.join(dirpath, "connections.csv"), index = False)
+        except:
+            invalid_topologies.append(dirpath)
+for directory in changed_topologies:
+    print(f"Modified topology {directory}!")
+for file in invalid_topologies:
+    print(f"Topology {file} breaks some part of the input file specification!")
diff --git a/input_files/models/district_models/example_CA/connections.csv b/input_files/models/district_models/example_CA/connections.csv
index 792c8b1f4fc0c752ba922b7fa195867470bc8ccc..2221e07d38148b66823fc50c9e34dfe3d8f2c10d 100644
--- a/input_files/models/district_models/example_CA/connections.csv
+++ b/input_files/models/district_models/example_CA/connections.csv
@@ -1,7 +1,7 @@
-sector,from,to
-electricity,inv_pv_bat,battery
-electricity,inv_pv_bat,grd
-electricity,inv_pv_bat,elec_cns
-electricity,battery,inv_pv_bat
-electricity,grd,inv_pv_bat
-electricity,grd,elec_cns
+from,output,to,input
+inv_pv_bat,1,battery,
+inv_pv_bat,1,grd,
+inv_pv_bat,1,elec_cns,
+battery,1,inv_pv_bat,
+grd,1,inv_pv_bat,
+grd,1,elec_cns,
diff --git a/input_files/models/district_models/example_community/connections.csv b/input_files/models/district_models/example_community/connections.csv
index d63037e151876506cae26e672ae1687d659d48d7..92ceec7f3297921688d1f3cc7e3a20492f1fb6ab 100644
--- a/input_files/models/district_models/example_community/connections.csv
+++ b/input_files/models/district_models/example_community/connections.csv
@@ -1,8 +1,8 @@
-sector,from,to
-electricity,pv_roof,inv_pv_bat
-electricity,inv_pv_bat,battery
-electricity,inv_pv_bat,grd
-electricity,inv_pv_bat,elec_cns
-electricity,battery,inv_pv_bat
-electricity,grd,inv_pv_bat
-electricity,grd,elec_cns
+from,output,to,input
+pv_roof,1,inv_pv_bat,
+inv_pv_bat,1,battery,
+inv_pv_bat,1,grd,
+inv_pv_bat,1,elec_cns,
+battery,1,inv_pv_bat,
+grd,1,inv_pv_bat,
+grd,1,elec_cns,
diff --git a/input_files/models/district_models/jbr_test_ca/connections.csv b/input_files/models/district_models/jbr_test_ca/connections.csv
index d63037e151876506cae26e672ae1687d659d48d7..92ceec7f3297921688d1f3cc7e3a20492f1fb6ab 100644
--- a/input_files/models/district_models/jbr_test_ca/connections.csv
+++ b/input_files/models/district_models/jbr_test_ca/connections.csv
@@ -1,8 +1,8 @@
-sector,from,to
-electricity,pv_roof,inv_pv_bat
-electricity,inv_pv_bat,battery
-electricity,inv_pv_bat,grd
-electricity,inv_pv_bat,elec_cns
-electricity,battery,inv_pv_bat
-electricity,grd,inv_pv_bat
-electricity,grd,elec_cns
+from,output,to,input
+pv_roof,1,inv_pv_bat,
+inv_pv_bat,1,battery,
+inv_pv_bat,1,grd,
+inv_pv_bat,1,elec_cns,
+battery,1,inv_pv_bat,
+grd,1,inv_pv_bat,
+grd,1,elec_cns,
diff --git a/input_files/models/district_models/jbr_test_comm/connections.csv b/input_files/models/district_models/jbr_test_comm/connections.csv
index d63037e151876506cae26e672ae1687d659d48d7..92ceec7f3297921688d1f3cc7e3a20492f1fb6ab 100644
--- a/input_files/models/district_models/jbr_test_comm/connections.csv
+++ b/input_files/models/district_models/jbr_test_comm/connections.csv
@@ -1,8 +1,8 @@
-sector,from,to
-electricity,pv_roof,inv_pv_bat
-electricity,inv_pv_bat,battery
-electricity,inv_pv_bat,grd
-electricity,inv_pv_bat,elec_cns
-electricity,battery,inv_pv_bat
-electricity,grd,inv_pv_bat
-electricity,grd,elec_cns
+from,output,to,input
+pv_roof,1,inv_pv_bat,
+inv_pv_bat,1,battery,
+inv_pv_bat,1,grd,
+inv_pv_bat,1,elec_cns,
+battery,1,inv_pv_bat,
+grd,1,inv_pv_bat,
+grd,1,elec_cns,
diff --git a/input_files/models/prosumer_models/SCN0_CAT1/connections.csv b/input_files/models/prosumer_models/SCN0_CAT1/connections.csv
index f911b10874d9f6ebe55ee5525ffe45638bdc258a..793bf1329f99e5e4a4aac1fa3ffa87caa752b7cb 100644
--- a/input_files/models/prosumer_models/SCN0_CAT1/connections.csv
+++ b/input_files/models/prosumer_models/SCN0_CAT1/connections.csv
@@ -1,8 +1,8 @@
-sector,from,to
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV11/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV11/connections.csv
index 07be821df10b12425e1874ef03d8cd624fd2f00a..29bf9c9ef842275d59ed73c3d89b5b67d5cd30b2 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV11/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV11/connections.csv
@@ -1,11 +1,11 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV12_BA/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV12_BA/connections.csv
index 907c9e7e18816817dd11611659105994e0026cc7..80ceeebd58806ee3304437a3efb0562e7bffe15e 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV12_BA/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV12_BA/connections.csv
@@ -1,17 +1,17 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,elec_cns
-electricity,grd,inv_bat
-electricity,inv_bat,battery
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,elec_cns,
+grd,1,inv_bat,
+inv_bat,1,battery,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV13_BA_HP/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV13_BA_HP/connections.csv
index c82fe1d4ec799d877bb423124caebc1e8dd84053..41209ff3aa614f9fef6b9bc7f9901a71efb8987c 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV13_BA_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV13_BA_HP/connections.csv
@@ -1,22 +1,22 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-electricity,inv_bat,battery
-electricity,inv_bat,heat_pump
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,heat_pump,
+grd,1,elec_cns,
+inv_bat,1,battery,
+inv_bat,1,heat_pump,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV14_HP/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV14_HP/connections.csv
index 4048376f0e1f750128105af3c99da1f68d5c6591..b419198fc173c911a242c5f9aa51e67e323e9045 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV14_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV14_HP/connections.csv
@@ -1,16 +1,16 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,heat_pump,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV31/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV31/connections.csv
index 07be821df10b12425e1874ef03d8cd624fd2f00a..29bf9c9ef842275d59ed73c3d89b5b67d5cd30b2 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV31/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV31/connections.csv
@@ -1,11 +1,11 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV32_BA/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV32_BA/connections.csv
index aedf9635c2d6cb19efa6ffae675a58c55a5a7c48..f28a5c34352235965a2fcd6d92c07dd35a0cbd36 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV32_BA/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV32_BA/connections.csv
@@ -1,16 +1,16 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,elec_cns
-electricity,inv_bat,battery
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,elec_cns,
+inv_bat,1,battery,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV33_BA_HP/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV33_BA_HP/connections.csv
index c82fe1d4ec799d877bb423124caebc1e8dd84053..41209ff3aa614f9fef6b9bc7f9901a71efb8987c 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV33_BA_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV33_BA_HP/connections.csv
@@ -1,22 +1,22 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-electricity,inv_bat,battery
-electricity,inv_bat,heat_pump
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,heat_pump,
+grd,1,elec_cns,
+inv_bat,1,battery,
+inv_bat,1,heat_pump,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN2_CAT1_PV34_HP/connections.csv b/input_files/models/prosumer_models/SCN2_CAT1_PV34_HP/connections.csv
index 4048376f0e1f750128105af3c99da1f68d5c6591..b419198fc173c911a242c5f9aa51e67e323e9045 100644
--- a/input_files/models/prosumer_models/SCN2_CAT1_PV34_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN2_CAT1_PV34_HP/connections.csv
@@ -1,16 +1,16 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,heat_pump,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1/connections.csv
index f911b10874d9f6ebe55ee5525ffe45638bdc258a..793bf1329f99e5e4a4aac1fa3ffa87caa752b7cb 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1/connections.csv
@@ -1,8 +1,8 @@
-sector,from,to
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV11/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV11/connections.csv
index 07be821df10b12425e1874ef03d8cd624fd2f00a..29bf9c9ef842275d59ed73c3d89b5b67d5cd30b2 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV11/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV11/connections.csv
@@ -1,11 +1,11 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV12_BA/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV12_BA/connections.csv
index 907c9e7e18816817dd11611659105994e0026cc7..80ceeebd58806ee3304437a3efb0562e7bffe15e 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV12_BA/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV12_BA/connections.csv
@@ -1,17 +1,17 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,elec_cns
-electricity,grd,inv_bat
-electricity,inv_bat,battery
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,elec_cns,
+grd,1,inv_bat,
+inv_bat,1,battery,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV13_BA_HP/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV13_BA_HP/connections.csv
index 14d304ec74d8ef0f33505e4fef9eafbc0d93b405..c3805591c367d90750a3906a366599c7d248862c 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV13_BA_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV13_BA_HP/connections.csv
@@ -1,23 +1,23 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-electricity,grd,inv_bat
-electricity,inv_bat,battery
-electricity,inv_bat,heat_pump
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,heat_pump,
+grd,1,elec_cns,
+grd,1,inv_bat,
+inv_bat,1,battery,
+inv_bat,1,heat_pump,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV14_HP/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV14_HP/connections.csv
index 4048376f0e1f750128105af3c99da1f68d5c6591..b419198fc173c911a242c5f9aa51e67e323e9045 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV14_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV14_HP/connections.csv
@@ -1,16 +1,16 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,heat_pump,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV31/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV31/connections.csv
index 07be821df10b12425e1874ef03d8cd624fd2f00a..29bf9c9ef842275d59ed73c3d89b5b67d5cd30b2 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV31/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV31/connections.csv
@@ -1,11 +1,11 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV32_BA/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV32_BA/connections.csv
index 907c9e7e18816817dd11611659105994e0026cc7..80ceeebd58806ee3304437a3efb0562e7bffe15e 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV32_BA/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV32_BA/connections.csv
@@ -1,17 +1,17 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,elec_cns
-electricity,grd,inv_bat
-electricity,inv_bat,battery
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,elec_cns,
+grd,1,inv_bat,
+inv_bat,1,battery,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV33_BA_HP/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV33_BA_HP/connections.csv
index 14d304ec74d8ef0f33505e4fef9eafbc0d93b405..c3805591c367d90750a3906a366599c7d248862c 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV33_BA_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV33_BA_HP/connections.csv
@@ -1,23 +1,23 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,inv_pv,inv_bat
-electricity,battery,inv_bat
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-electricity,grd,inv_bat
-electricity,inv_bat,battery
-electricity,inv_bat,heat_pump
-electricity,inv_bat,grd
-electricity,inv_bat,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+inv_pv,1,inv_bat,
+battery,1,inv_bat,
+grd,1,heat_pump,
+grd,1,elec_cns,
+grd,1,inv_bat,
+inv_bat,1,battery,
+inv_bat,1,heat_pump,
+inv_bat,1,grd,
+inv_bat,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/SCN3_CAT1_PV34_HP/connections.csv b/input_files/models/prosumer_models/SCN3_CAT1_PV34_HP/connections.csv
index 4048376f0e1f750128105af3c99da1f68d5c6591..b419198fc173c911a242c5f9aa51e67e323e9045 100644
--- a/input_files/models/prosumer_models/SCN3_CAT1_PV34_HP/connections.csv
+++ b/input_files/models/prosumer_models/SCN3_CAT1_PV34_HP/connections.csv
@@ -1,16 +1,16 @@
-sector,from,to
-electricity,pv_roof,inv_pv
-electricity,inv_pv,heat_pump
-electricity,inv_pv,grd
-electricity,inv_pv,elec_cns
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-gas,gas_grd,gas_boi
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,gas_boi,water_tes
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
-heat,gas_boi,therm_cns
-heat,gas_boi,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv,
+inv_pv,1,heat_pump,
+inv_pv,1,grd,
+inv_pv,1,elec_cns,
+grd,1,heat_pump,
+grd,1,elec_cns,
+gas_grd,1,gas_boi,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+gas_boi,1,water_tes,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
+gas_boi,1,therm_cns,
+gas_boi,1,dhw_dmd,
diff --git a/input_files/models/prosumer_models/jbr_test/connections.csv b/input_files/models/prosumer_models/jbr_test/connections.csv
index d63037e151876506cae26e672ae1687d659d48d7..92ceec7f3297921688d1f3cc7e3a20492f1fb6ab 100644
--- a/input_files/models/prosumer_models/jbr_test/connections.csv
+++ b/input_files/models/prosumer_models/jbr_test/connections.csv
@@ -1,8 +1,8 @@
-sector,from,to
-electricity,pv_roof,inv_pv_bat
-electricity,inv_pv_bat,battery
-electricity,inv_pv_bat,grd
-electricity,inv_pv_bat,elec_cns
-electricity,battery,inv_pv_bat
-electricity,grd,inv_pv_bat
-electricity,grd,elec_cns
+from,output,to,input
+pv_roof,1,inv_pv_bat,
+inv_pv_bat,1,battery,
+inv_pv_bat,1,grd,
+inv_pv_bat,1,elec_cns,
+battery,1,inv_pv_bat,
+grd,1,inv_pv_bat,
+grd,1,elec_cns,
diff --git a/input_files/models/prosumer_models/mfh_quartal/connections.csv b/input_files/models/prosumer_models/mfh_quartal/connections.csv
index 24fbbcbe2b387b1c2e48527a1eed199904fcc49b..6bbcae822124c310fc58d2d9d02cea28525afed1 100644
--- a/input_files/models/prosumer_models/mfh_quartal/connections.csv
+++ b/input_files/models/prosumer_models/mfh_quartal/connections.csv
@@ -1,35 +1,35 @@
-sector,from,to
-electricity,grd,ecns1
-electricity,grd,ecns2
-electricity,grd,ecns3
-electricity,grd,ecns4
-electricity,grd,ecns5
-electricity,grd,ecns6
-electricity,pv,grd
-electricity,pv,bat
-electricity,pv,ecns1
-electricity,pv,ecns2
-electricity,pv,ecns3
-electricity,pv,ecns4
-electricity,pv,ecns5
-electricity,pv,ecns6
-electricity,bat,ecns1
-electricity,bat,ecns2
-electricity,bat,ecns3
-electricity,bat,ecns4
-electricity,bat,ecns5
-electricity,bat,ecns6
-electricity,chp,grd
-electricity,chp,ecns1
-electricity,chp,ecns2
-electricity,chp,ecns3
-electricity,chp,ecns4
-electricity,chp,ecns5
-electricity,chp,ecns6
-gas,gas_grd,chp
-heat,chp,tcns1
-heat,chp,tcns2
-heat,chp,tcns3
-heat,chp,tcns4
-heat,chp,tcns5
-heat,chp,tcns6
+from,output,to,input
+grd,1,ecns1,
+grd,1,ecns2,
+grd,1,ecns3,
+grd,1,ecns4,
+grd,1,ecns5,
+grd,1,ecns6,
+pv,1,grd,
+pv,1,bat,
+pv,1,ecns1,
+pv,1,ecns2,
+pv,1,ecns3,
+pv,1,ecns4,
+pv,1,ecns5,
+pv,1,ecns6,
+bat,1,ecns1,
+bat,1,ecns2,
+bat,1,ecns3,
+bat,1,ecns4,
+bat,1,ecns5,
+bat,1,ecns6,
+chp,2,grd,
+chp,2,ecns1,
+chp,2,ecns2,
+chp,2,ecns3,
+chp,2,ecns4,
+chp,2,ecns5,
+chp,2,ecns6,
+gas_grd,1,chp,
+chp,1,tcns1,
+chp,1,tcns2,
+chp,1,tcns3,
+chp,1,tcns4,
+chp,1,tcns5,
+chp,1,tcns6,
diff --git a/input_files/models/prosumer_models/office_pv_heatpump/connections.csv b/input_files/models/prosumer_models/office_pv_heatpump/connections.csv
index 2648881f72c712482bc13125ef1170dbd0a38ee6..1e8111f230f2e7f2da8cf79657b1da83f0b547be 100644
--- a/input_files/models/prosumer_models/office_pv_heatpump/connections.csv
+++ b/input_files/models/prosumer_models/office_pv_heatpump/connections.csv
@@ -1,15 +1,15 @@
-sector,from,to
-electricity,pv_roof,inv_pv_bat
-electricity,inv_pv_bat,battery
-electricity,inv_pv_bat,heat_pump
-electricity,inv_pv_bat,grd
-electricity,inv_pv_bat,elec_cns
-electricity,battery,inv_pv_bat
-electricity,grd,inv_pv_bat
-electricity,grd,heat_pump
-electricity,grd,elec_cns
-heat,heat_pump,water_tes
-heat,water_tes,therm_cns
-heat,water_tes,dhw_dmd
-heat,heat_pump,therm_cns
-heat,heat_pump,dhw_dmd
+from,output,to,input
+pv_roof,1,inv_pv_bat,
+inv_pv_bat,1,battery,
+inv_pv_bat,1,heat_pump,
+inv_pv_bat,1,grd,
+inv_pv_bat,1,elec_cns,
+battery,1,inv_pv_bat,
+grd,1,inv_pv_bat,
+grd,1,heat_pump,
+grd,1,elec_cns,
+heat_pump,1,water_tes,
+water_tes,1,therm_cns,
+water_tes,1,dhw_dmd,
+heat_pump,1,therm_cns,
+heat_pump,1,dhw_dmd,
diff --git a/runme.py b/runme.py
index 29ac2e8040ccc4fbdaf8af134c4585f1116b55ce..7f76e0a2ed8ae837b273b5eb9a7c77e19873a2ac 100644
--- a/runme.py
+++ b/runme.py
@@ -1,7 +1,7 @@
 import pandas as pd
 import Tooling.input_profile_processor.input_profile_processor
-import Model_Library.Prosumer.main as main
-import Model_Library.District.main_district as main_district
+import Model_Library.Prosumer.main as main_prosumer
+import Model_Library.District.main as main_district
 from enum import Enum
 
 class SimulationScope(Enum):
@@ -46,7 +46,7 @@ prosumer_dict = {'SCN2_CAT1_PV11_3000_6000':{'config_path': 'input_files/models/
                                                       'therm_cns': 'demand_heat_2',
                                                       'dhw_dmd': 'demand_hot_water_2'}}}
 
-prosumer_main = main.Main(prosumer_dict, input_profiles, t_horizon, t_step)
+prosumer_main = main_prosumer.ProsumerMain(prosumer_dict, input_profiles, t_horizon, t_step)
 
 prosumer_sizing_strategy = 'annuity'
 prosumer_main.optimize_sizing(prosumer_sizing_strategy)
@@ -62,12 +62,12 @@ community_assets_dict = {'ca_bat': {'config_path': 'input_files/models/district_
                                     'topology_path': 'input_files/models/district_models/example_CA',
                                     'profiles': {'elec_cns': 'demand_electric_3'}}}
 
-community_assets = main.Main_CA(community_assets_dict, input_profiles, t_horizon, t_step).community_assets
+community_assets = main_prosumer.CommunityAssetMain(community_assets_dict, input_profiles, t_horizon, t_step).community_assets
 
 community_dict = {'community': {'config_path': 'input_files/models/district_models/example_community/config.csv',
                                 'profiles': {'elec_price': 'elec_price_1'}}}
 
-community_main = main_district.MainDistrict(community_dict, prosumers, community_assets, input_profiles, t_horizon, t_step)
+community_main = main_district.CommunityMain(community_dict, prosumers, community_assets, input_profiles, t_horizon, t_step)
 
 community_sizing_strategy = 'max_operational_profit'
 community_main.optimize_sizing(community_sizing_strategy)