We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[FEATURE] Abstract builder class for Jax-based systems
### Feature
Abstract class for system building for Jax-based Mava systems.

### Proposal
The builder should take care of building essentially elements of a MARL system that run in different processes. These include the data server, variable server, executor (and evaluator) and trainer. 

### Testing
Tests will only consider the proper inheritance of the abstract builder class.

### Definition of done
All abstract methods are defined and have input and return types specified. 

### Mandatory checklist before making a PR
* [x] The success criteria laid down in “Definition of done” are met.
* [x] Code is documented - docstrings for methods and classes, static types for arguments.
* [x] Code is tested - unit, integration and/or functional tests are added.
* [x] Documentation is updated - README, CONTRIBUTING, or other documentation.
* [x] All functional tests are green.


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `mava/core_jax.py`
Content:
```
1 # python3
2 # Copyright 2021 InstaDeep Ltd. All rights reserved.
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 #     http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 
16 
17 """Core Mava interfaces for Jax systems."""
18 
19 import abc
20 from types import SimpleNamespace
21 from typing import Any, List
22 
23 
24 class BaseSystem(abc.ABC):
25     """Abstract system object."""
26 
27     @abc.abstractmethod
28     def design(self) -> SimpleNamespace:
29         """System design specifying the list of components to use.
30 
31         Returns:
32             system callback components
33         """
34 
35     @abc.abstractmethod
36     def update(self, component: Any) -> None:
37         """Update a component that has already been added to the system.
38 
39         Args:
40             component : system callback component
41         """
42 
43     @abc.abstractmethod
44     def add(self, component: Any) -> None:
45         """Add a new component to the system.
46 
47         Args:
48             component : system callback component
49         """
50 
51     @abc.abstractmethod
52     def configure(self, **kwargs: Any) -> None:
53         """Configure system hyperparameters."""
54 
55     @abc.abstractmethod
56     def launch(
57         self,
58         num_executors: int,
59         nodes_on_gpu: List[str],
60         multi_process: bool = True,
61         name: str = "system",
62     ) -> None:
63         """Run the system.
64 
65         Args:
66             num_executors : number of executor processes to run in parallel
67             nodes_on_gpu : which processes to run on gpu
68             multi_process : whether to run single or multi process, single process runs
69                 are primarily for debugging
70             name : name of the system
71         """
72
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/mava/core_jax.py b/mava/core_jax.py
--- a/mava/core_jax.py
+++ b/mava/core_jax.py
@@ -69,3 +69,59 @@
                 are primarily for debugging
             name : name of the system
         """
+
+
+class SystemBuilder(abc.ABC):
+    """Abstract system builder."""
+
+    @abc.abstractmethod
+    def data_server(self) -> List[Any]:
+        """Data server to store and serve transition data from and to system.
+
+        Returns:
+            System data server
+        """
+
+    @abc.abstractmethod
+    def parameter_server(self) -> Any:
+        """Parameter server to store and serve system network parameters.
+
+        Returns:
+            System parameter server
+        """
+
+    @abc.abstractmethod
+    def executor(
+        self, executor_id: str, data_server_client: Any, parameter_server_client: Any
+    ) -> Any:
+        """Executor, a collection of agents in an environment to gather experience.
+
+        Args:
+            executor_id : id to identify the executor process for logging purposes
+            data_server_client : data server client for pushing transition data
+            parameter_server_client : parameter server client for pulling parameters
+        Returns:
+            System executor
+        """
+
+    @abc.abstractmethod
+    def trainer(
+        self, trainer_id: str, data_server_client: Any, parameter_server_client: Any
+    ) -> Any:
+        """Trainer, a system process for updating agent specific network parameters.
+
+        Args:
+            trainer_id : id to identify the trainer process for logging purposes
+            data_server_client : data server client for pulling transition data
+            parameter_server_client : parameter server client for pushing parameters
+        Returns:
+            System trainer
+        """
+
+    @abc.abstractmethod
+    def build(self) -> None:
+        """Construct program nodes."""
+
+    @abc.abstractmethod
+    def launch(self) -> None:
+        """Run the graph program."""

{"golden_diff": "diff --git a/mava/core_jax.py b/mava/core_jax.py\n--- a/mava/core_jax.py\n+++ b/mava/core_jax.py\n@@ -69,3 +69,59 @@\n                 are primarily for debugging\n             name : name of the system\n         \"\"\"\n+\n+\n+class SystemBuilder(abc.ABC):\n+    \"\"\"Abstract system builder.\"\"\"\n+\n+    @abc.abstractmethod\n+    def data_server(self) -> List[Any]:\n+        \"\"\"Data server to store and serve transition data from and to system.\n+\n+        Returns:\n+            System data server\n+        \"\"\"\n+\n+    @abc.abstractmethod\n+    def parameter_server(self) -> Any:\n+        \"\"\"Parameter server to store and serve system network parameters.\n+\n+        Returns:\n+            System parameter server\n+        \"\"\"\n+\n+    @abc.abstractmethod\n+    def executor(\n+        self, executor_id: str, data_server_client: Any, parameter_server_client: Any\n+    ) -> Any:\n+        \"\"\"Executor, a collection of agents in an environment to gather experience.\n+\n+        Args:\n+            executor_id : id to identify the executor process for logging purposes\n+            data_server_client : data server client for pushing transition data\n+            parameter_server_client : parameter server client for pulling parameters\n+        Returns:\n+            System executor\n+        \"\"\"\n+\n+    @abc.abstractmethod\n+    def trainer(\n+        self, trainer_id: str, data_server_client: Any, parameter_server_client: Any\n+    ) -> Any:\n+        \"\"\"Trainer, a system process for updating agent specific network parameters.\n+\n+        Args:\n+            trainer_id : id to identify the trainer process for logging purposes\n+            data_server_client : data server client for pulling transition data\n+            parameter_server_client : parameter server client for pushing parameters\n+        Returns:\n+            System trainer\n+        \"\"\"\n+\n+    @abc.abstractmethod\n+    def build(self) -> None:\n+        \"\"\"Construct program nodes.\"\"\"\n+\n+    @abc.abstractmethod\n+    def launch(self) -> None:\n+        \"\"\"Run the graph program.\"\"\"\n", "issue": "[FEATURE] Abstract builder class for Jax-based systems\n### Feature\r\nAbstract class for system building for Jax-based Mava systems.\r\n\r\n### Proposal\r\nThe builder should take care of building essentially elements of a MARL system that run in different processes. These include the data server, variable server, executor (and evaluator) and trainer. \r\n\r\n### Testing\r\nTests will only consider the proper inheritance of the abstract builder class.\r\n\r\n### Definition of done\r\nAll abstract methods are defined and have input and return types specified. \r\n\r\n### Mandatory checklist before making a PR\r\n* [x] The success criteria laid down in \u201cDefinition of done\u201d are met.\r\n* [x] Code is documented - docstrings for methods and classes, static types for arguments.\r\n* [x] Code is tested - unit, integration and/or functional tests are added.\r\n* [x] Documentation is updated - README, CONTRIBUTING, or other documentation.\r\n* [x] All functional tests are green.\r\n\n", "before_files": [{"content": "# python3\n# Copyright 2021 InstaDeep Ltd. All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\n\n\"\"\"Core Mava interfaces for Jax systems.\"\"\"\n\nimport abc\nfrom types import SimpleNamespace\nfrom typing import Any, List\n\n\nclass BaseSystem(abc.ABC):\n    \"\"\"Abstract system object.\"\"\"\n\n    @abc.abstractmethod\n    def design(self) -> SimpleNamespace:\n        \"\"\"System design specifying the list of components to use.\n\n        Returns:\n            system callback components\n        \"\"\"\n\n    @abc.abstractmethod\n    def update(self, component: Any) -> None:\n        \"\"\"Update a component that has already been added to the system.\n\n        Args:\n            component : system callback component\n        \"\"\"\n\n    @abc.abstractmethod\n    def add(self, component: Any) -> None:\n        \"\"\"Add a new component to the system.\n\n        Args:\n            component : system callback component\n        \"\"\"\n\n    @abc.abstractmethod\n    def configure(self, **kwargs: Any) -> None:\n        \"\"\"Configure system hyperparameters.\"\"\"\n\n    @abc.abstractmethod\n    def launch(\n        self,\n        num_executors: int,\n        nodes_on_gpu: List[str],\n        multi_process: bool = True,\n        name: str = \"system\",\n    ) -> None:\n        \"\"\"Run the system.\n\n        Args:\n            num_executors : number of executor processes to run in parallel\n            nodes_on_gpu : which processes to run on gpu\n            multi_process : whether to run single or multi process, single process runs\n                are primarily for debugging\n            name : name of the system\n        \"\"\"\n", "path": "mava/core_jax.py"}], "after_files": [{"content": "# python3\n# Copyright 2021 InstaDeep Ltd. All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\n\n\"\"\"Core Mava interfaces for Jax systems.\"\"\"\n\nimport abc\nfrom types import SimpleNamespace\nfrom typing import Any, List\n\n\nclass BaseSystem(abc.ABC):\n    \"\"\"Abstract system object.\"\"\"\n\n    @abc.abstractmethod\n    def design(self) -> SimpleNamespace:\n        \"\"\"System design specifying the list of components to use.\n\n        Returns:\n            system callback components\n        \"\"\"\n\n    @abc.abstractmethod\n    def update(self, component: Any) -> None:\n        \"\"\"Update a component that has already been added to the system.\n\n        Args:\n            component : system callback component\n        \"\"\"\n\n    @abc.abstractmethod\n    def add(self, component: Any) -> None:\n        \"\"\"Add a new component to the system.\n\n        Args:\n            component : system callback component\n        \"\"\"\n\n    @abc.abstractmethod\n    def configure(self, **kwargs: Any) -> None:\n        \"\"\"Configure system hyperparameters.\"\"\"\n\n    @abc.abstractmethod\n    def launch(\n        self,\n        num_executors: int,\n        nodes_on_gpu: List[str],\n        multi_process: bool = True,\n        name: str = \"system\",\n    ) -> None:\n        \"\"\"Run the system.\n\n        Args:\n            num_executors : number of executor processes to run in parallel\n            nodes_on_gpu : which processes to run on gpu\n            multi_process : whether to run single or multi process, single process runs\n                are primarily for debugging\n            name : name of the system\n        \"\"\"\n\n\nclass SystemBuilder(abc.ABC):\n    \"\"\"Abstract system builder.\"\"\"\n\n    @abc.abstractmethod\n    def data_server(self) -> List[Any]:\n        \"\"\"Data server to store and serve transition data from and to system.\n\n        Returns:\n            System data server\n        \"\"\"\n\n    @abc.abstractmethod\n    def parameter_server(self) -> Any:\n        \"\"\"Parameter server to store and serve system network parameters.\n\n        Returns:\n            System parameter server\n        \"\"\"\n\n    @abc.abstractmethod\n    def executor(\n        self, executor_id: str, data_server_client: Any, parameter_server_client: Any\n    ) -> Any:\n        \"\"\"Executor, a collection of agents in an environment to gather experience.\n\n        Args:\n            executor_id : id to identify the executor process for logging purposes\n            data_server_client : data server client for pushing transition data\n            parameter_server_client : parameter server client for pulling parameters\n        Returns:\n            System executor\n        \"\"\"\n\n    @abc.abstractmethod\n    def trainer(\n        self, trainer_id: str, data_server_client: Any, parameter_server_client: Any\n    ) -> Any:\n        \"\"\"Trainer, a system process for updating agent specific network parameters.\n\n        Args:\n            trainer_id : id to identify the trainer process for logging purposes\n            data_server_client : data server client for pulling transition data\n            parameter_server_client : parameter server client for pushing parameters\n        Returns:\n            System trainer\n        \"\"\"\n\n    @abc.abstractmethod\n    def build(self) -> None:\n        \"\"\"Construct program nodes.\"\"\"\n\n    @abc.abstractmethod\n    def launch(self) -> None:\n        \"\"\"Run the graph program.\"\"\"\n", "path": "mava/core_jax.py"}]}