We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG]: typing miss of kwargs
### 🐛 Describe the bug

When I tried to train prompts with opt model, the following error was occurred.

```
Traceback (most recent call last):
  File "/home/xxx/workspace/ColossalAI/applications/ChatGPT/examples/train_prompts.py", line 127, in <module>
    main(args)
  File "/home/xxx/workspace/ColossalAI/applications/ChatGPT/examples/train_prompts.py", line 42, in main
    critic = OPTCritic(lora_rank=args.lora_rank).cuda()
  File "/home/xxx/.pyenv/versions/3.9.9/lib/python3.9/site-packages/chatgpt/models/opt/opt_critic.py", line 38, in __init__
    super().__init__(model, value_head, lora_rank, lora_train_bias, **kwargs)
NameError: name 'kwargs' is not defined
```

To Reproduce

```
torchrun --standalone --nproc_per_node=2 train_prompts.py prompts.csv --model opt --strategy colossalai_zero2
```



### Environment

_No response_

--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `applications/ChatGPT/chatgpt/models/opt/opt_critic.py`
Content:
```
1 from typing import Optional
2 
3 import torch.nn as nn
4 from transformers.models.opt.configuration_opt import OPTConfig
5 from transformers.models.opt.modeling_opt import OPTModel
6 
7 from ..base import Critic
8 
9 
10 class OPTCritic(Critic):
11     """
12     OPT Critic model.
13 
14     Args:
15         pretrained (str): Pretrained model name or path.
16         config (OPTConfig): Model config.
17         checkpoint (bool): Enable gradient checkpointing.
18         lora_rank (int): Rank of the low-rank approximation.
19         lora_train_bias (str): LoRA bias training mode.
20     """
21 
22     def __init__(self,
23                  pretrained: Optional[str] = None,
24                  config: Optional[OPTConfig] = None,
25                  checkpoint: bool = False,
26                  lora_rank: int = 0,
27                  lora_train_bias: str = 'none',
28                  **kargs) -> None:
29         if pretrained is not None:
30             model = OPTModel.from_pretrained(pretrained)
31         elif config is not None:
32             model = OPTModel(config)
33         else:
34             model = OPTModel(OPTConfig())
35         if checkpoint:
36             model.gradient_checkpointing_enable()
37         value_head = nn.Linear(model.config.hidden_size, 1)
38         super().__init__(model, value_head, lora_rank, lora_train_bias, **kwargs)
39
```
--- 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/applications/ChatGPT/chatgpt/models/opt/opt_critic.py b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py
--- a/applications/ChatGPT/chatgpt/models/opt/opt_critic.py
+++ b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py
@@ -25,7 +25,7 @@
                  checkpoint: bool = False,
                  lora_rank: int = 0,
                  lora_train_bias: str = 'none',
-                 **kargs) -> None:
+                 **kwargs) -> None:
         if pretrained is not None:
             model = OPTModel.from_pretrained(pretrained)
         elif config is not None:

{"golden_diff": "diff --git a/applications/ChatGPT/chatgpt/models/opt/opt_critic.py b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py\n--- a/applications/ChatGPT/chatgpt/models/opt/opt_critic.py\n+++ b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py\n@@ -25,7 +25,7 @@\n                  checkpoint: bool = False,\n                  lora_rank: int = 0,\n                  lora_train_bias: str = 'none',\n-                 **kargs) -> None:\n+                 **kwargs) -> None:\n         if pretrained is not None:\n             model = OPTModel.from_pretrained(pretrained)\n         elif config is not None:\n", "issue": "[BUG]: typing miss of kwargs\n### \ud83d\udc1b Describe the bug\n\nWhen I tried to train prompts with opt model, the following error was occurred.\r\n\r\n```\r\nTraceback (most recent call last):\r\n  File \"/home/xxx/workspace/ColossalAI/applications/ChatGPT/examples/train_prompts.py\", line 127, in <module>\r\n    main(args)\r\n  File \"/home/xxx/workspace/ColossalAI/applications/ChatGPT/examples/train_prompts.py\", line 42, in main\r\n    critic = OPTCritic(lora_rank=args.lora_rank).cuda()\r\n  File \"/home/xxx/.pyenv/versions/3.9.9/lib/python3.9/site-packages/chatgpt/models/opt/opt_critic.py\", line 38, in __init__\r\n    super().__init__(model, value_head, lora_rank, lora_train_bias, **kwargs)\r\nNameError: name 'kwargs' is not defined\r\n```\r\n\r\nTo Reproduce\r\n\r\n```\r\ntorchrun --standalone --nproc_per_node=2 train_prompts.py prompts.csv --model opt --strategy colossalai_zero2\r\n```\r\n\r\n\n\n### Environment\n\n_No response_\n", "before_files": [{"content": "from typing import Optional\n\nimport torch.nn as nn\nfrom transformers.models.opt.configuration_opt import OPTConfig\nfrom transformers.models.opt.modeling_opt import OPTModel\n\nfrom ..base import Critic\n\n\nclass OPTCritic(Critic):\n    \"\"\"\n    OPT Critic model.\n\n    Args:\n        pretrained (str): Pretrained model name or path.\n        config (OPTConfig): Model config.\n        checkpoint (bool): Enable gradient checkpointing.\n        lora_rank (int): Rank of the low-rank approximation.\n        lora_train_bias (str): LoRA bias training mode.\n    \"\"\"\n\n    def __init__(self,\n                 pretrained: Optional[str] = None,\n                 config: Optional[OPTConfig] = None,\n                 checkpoint: bool = False,\n                 lora_rank: int = 0,\n                 lora_train_bias: str = 'none',\n                 **kargs) -> None:\n        if pretrained is not None:\n            model = OPTModel.from_pretrained(pretrained)\n        elif config is not None:\n            model = OPTModel(config)\n        else:\n            model = OPTModel(OPTConfig())\n        if checkpoint:\n            model.gradient_checkpointing_enable()\n        value_head = nn.Linear(model.config.hidden_size, 1)\n        super().__init__(model, value_head, lora_rank, lora_train_bias, **kwargs)\n", "path": "applications/ChatGPT/chatgpt/models/opt/opt_critic.py"}], "after_files": [{"content": "from typing import Optional\n\nimport torch.nn as nn\nfrom transformers.models.opt.configuration_opt import OPTConfig\nfrom transformers.models.opt.modeling_opt import OPTModel\n\nfrom ..base import Critic\n\n\nclass OPTCritic(Critic):\n    \"\"\"\n    OPT Critic model.\n\n    Args:\n        pretrained (str): Pretrained model name or path.\n        config (OPTConfig): Model config.\n        checkpoint (bool): Enable gradient checkpointing.\n        lora_rank (int): Rank of the low-rank approximation.\n        lora_train_bias (str): LoRA bias training mode.\n    \"\"\"\n\n    def __init__(self,\n                 pretrained: Optional[str] = None,\n                 config: Optional[OPTConfig] = None,\n                 checkpoint: bool = False,\n                 lora_rank: int = 0,\n                 lora_train_bias: str = 'none',\n                 **kwargs) -> None:\n        if pretrained is not None:\n            model = OPTModel.from_pretrained(pretrained)\n        elif config is not None:\n            model = OPTModel(config)\n        else:\n            model = OPTModel(OPTConfig())\n        if checkpoint:\n            model.gradient_checkpointing_enable()\n        value_head = nn.Linear(model.config.hidden_size, 1)\n        super().__init__(model, value_head, lora_rank, lora_train_bias, **kwargs)\n", "path": "applications/ChatGPT/chatgpt/models/opt/opt_critic.py"}]}