[Minor] code style improvements
diff --git a/README.md b/README.md
index 6df0457158..0f64eaa743 100644
--- a/README.md
+++ b/README.md
@@ -146,9 +146,10 @@ python3 -m fastchat.serve.cli --model-path lmsys/vicuna-7b-v1.3 --load-8bit
 In addition to that, you can add `--cpu-offloading` to commands above to offload weights that don't fit on your GPU onto the CPU memory.
 This requires 8-bit compression to be enabled and the bitsandbytes package to be installed, which is only available on linux operating systems.
 
-#### More Platforms
+#### More Platforms and Quantization
 - For AMD GPU users, please install ROCm and [the ROCm version of PyTorch](https://pytorch.org/get-started/locally/) before you install FastChat. See also this [post](https://github.com/lm-sys/FastChat/issues/104#issuecomment-1613791563).
 - FastChat supports GPTQ 4bit inference with [GPTQ-for-LLaMa](https://github.com/qwopqwop200/GPTQ-for-LLaMa). See [docs/gptq.md](/docs/gptq.md).
+- FastChat supports AWQ 4bit inference with [mit-han-lab/llm-awq](https://github.com/mit-han-lab/llm-awq). See [docs/awq.md](/docs/awq.md).
 - [MLC LLM](https://mlc.ai/mlc-llm/), backed by [TVM Unity](https://github.com/apache/tvm/tree/unity) compiler, deploys Vicuna natively on phones, consumer-class GPUs and web browsers via Vulkan, Metal, CUDA and WebGPU.
 
 ## Serving with Web GUI
diff --git a/fastchat/model/model_adapter.py b/fastchat/model/model_adapter.py
index c959346f58..8c769b9cc7 100644
--- a/fastchat/model/model_adapter.py
+++ b/fastchat/model/model_adapter.py
@@ -148,8 +148,8 @@ def raise_warning_for_incompatible_cpu_offloading_configuration(
 
 def load_model(
     model_path: str,
-    device: str,
-    num_gpus: int,
+    device: str = "cuda",
+    num_gpus: int = 1,
     max_gpu_memory: Optional[str] = None,
     load_8bit: bool = False,
     cpu_offloading: bool = False,
@@ -377,44 +377,44 @@ def add_model_args(parser):
         "--gptq-ckpt",
         type=str,
         default=None,
-        help="Load quantized model. The path to the local GPTQ checkpoint.",
+        help="Used for GPTQ. The path to the local GPTQ checkpoint.",
     )
     parser.add_argument(
         "--gptq-wbits",
         type=int,
         default=16,
         choices=[2, 3, 4, 8, 16],
-        help="#bits to use for quantization",
+        help="Used for GPTQ. #bits to use for quantization",
     )
     parser.add_argument(
         "--gptq-groupsize",
         type=int,
         default=-1,
-        help="Groupsize to use for quantization; default uses full row.",
+        help="Used for GPTQ. Groupsize to use for quantization; default uses full row.",
     )
     parser.add_argument(
         "--gptq-act-order",
         action="store_true",
-        help="Whether to apply the activation order GPTQ heuristic",
+        help="Used for GPTQ. Whether to apply the activation order GPTQ heuristic",
     )
     parser.add_argument(
         "--awq-ckpt",
         type=str,
         default=None,
-        help="Load quantized model. The path to the local AWQ checkpoint.",
+        help="Used for AWQ. Load quantized model. The path to the local AWQ checkpoint.",
     )
     parser.add_argument(
         "--awq-wbits",
         type=int,
         default=16,
         choices=[4, 16],
-        help="#bits to use for AWQ quantization",
+        help="Used for AWQ. #bits to use for AWQ quantization",
     )
     parser.add_argument(
         "--awq-groupsize",
         type=int,
         default=-1,
-        help="Groupsize to use for AWQ quantization; default uses full row.",
+        help="Used for AWQ. Groupsize to use for AWQ quantization; default uses full row.",
     )
 
 
diff --git a/fastchat/serve/cli.py b/fastchat/serve/cli.py
index 12b6146a40..5f7cc9db5d 100644
--- a/fastchat/serve/cli.py
+++ b/fastchat/serve/cli.py
@@ -201,20 +201,20 @@ def main(args):
             args.repetition_penalty,
             args.max_new_tokens,
             chatio,
-            GptqConfig(
+            gptq_config=GptqConfig(
                 ckpt=args.gptq_ckpt or args.model_path,
                 wbits=args.gptq_wbits,
                 groupsize=args.gptq_groupsize,
                 act_order=args.gptq_act_order,
             ),
-            AWQConfig(
+            awq_config=AWQConfig(
                 ckpt=args.awq_ckpt or args.model_path,
                 wbits=args.awq_wbits,
                 groupsize=args.awq_groupsize,
             ),
-            args.revision,
-            args.judge_sent_end,
-            args.debug,
+            revision=args.revision,
+            judge_sent_end=args.judge_sent_end,
+            debug=args.debug,
             history=not args.no_history,
         )
     except KeyboardInterrupt:
diff --git a/fastchat/serve/huggingface_api.py b/fastchat/serve/huggingface_api.py
index 4577e3918d..47dcb87b1c 100644
--- a/fastchat/serve/huggingface_api.py
+++ b/fastchat/serve/huggingface_api.py
@@ -18,11 +18,11 @@
 def main(args):
     model, tokenizer = load_model(
         args.model_path,
-        args.device,
-        args.num_gpus,
-        args.max_gpu_memory,
-        args.load_8bit,
-        args.cpu_offloading,
+        device=args.device,
+        num_gpus=args.num_gpus,
+        max_gpu_memory=args.max_gpu_memory,
+        load_8bit=args.load_8bit,
+        cpu_offloading=args.cpu_offloading,
         revision=args.revision,
         debug=args.debug,
     )
@@ -38,7 +38,7 @@ def main(args):
     inputs = {k: torch.tensor(v).to(args.device) for k, v in inputs.items()}
     output_ids = model.generate(
         **inputs,
-        do_sample=True,
+        do_sample=True if args.temperature > 1e-5 else False,
         temperature=args.temperature,
         repetition_penalty=args.repetition_penalty,
         max_new_tokens=args.max_new_tokens,
diff --git a/fastchat/serve/inference.py b/fastchat/serve/inference.py
index 26feff2235..f994c98821 100644
--- a/fastchat/serve/inference.py
+++ b/fastchat/serve/inference.py
@@ -284,25 +284,25 @@ def chat_loop(
     repetition_penalty: float,
     max_new_tokens: int,
     chatio: ChatIO,
-    gptq_config: GptqConfig,
-    awq_config: AWQConfig,
-    revision: str,
-    judge_sent_end: bool,
-    debug: bool,
+    gptq_config: Optional[GptqConfig] = None,
+    awq_config: Optional[AWQConfig] = None,
+    revision: str = "main",
+    judge_sent_end: bool = True,
+    debug: bool = True,
     history: bool = True,
 ):
     # Model
     model, tokenizer = load_model(
         model_path,
-        device,
-        num_gpus,
-        max_gpu_memory,
-        load_8bit,
-        cpu_offloading,
-        gptq_config,
-        awq_config,
-        revision,
-        debug,
+        device=device,
+        num_gpus=num_gpus,
+        max_gpu_memory=max_gpu_memory,
+        load_8bit=load_8bit,
+        cpu_offloading=cpu_offloading,
+        gptq_config=gptq_config,
+        awq_config=awq_config,
+        revision=revision,
+        debug=debug,
     )
     generate_stream_func = get_generate_stream_function(model, model_path)
 
diff --git a/fastchat/serve/model_worker.py b/fastchat/serve/model_worker.py
index 3c62c85f14..311aa81891 100644
--- a/fastchat/serve/model_worker.py
+++ b/fastchat/serve/model_worker.py
@@ -8,7 +8,7 @@
 import json
 import os
 import time
-from typing import List
+from typing import List, Optional
 import threading
 import uuid
 
@@ -43,6 +43,7 @@
     get_generate_stream_function,
 )
 from fastchat.modules.gptq import GptqConfig
+from fastchat.modules.awq import AWQConfig
 from fastchat.utils import build_logger, pretty_print_semaphore, get_context_length
 
 
@@ -187,7 +188,8 @@ def __init__(
         max_gpu_memory: str,
         load_8bit: bool = False,
         cpu_offloading: bool = False,
-        gptq_config: bool = None,
+        gptq_config: Optional[GptqConfig] = None,
+        awq_config: Optional[AWQConfig] = None,
         stream_interval: int = 2,
         conv_template: str = None,
     ):
@@ -204,12 +206,13 @@ def __init__(
         logger.info(f"Loading the model {self.model_names} on worker {worker_id} ...")
         self.model, self.tokenizer = load_model(
             model_path,
-            device,
-            num_gpus,
-            max_gpu_memory,
-            load_8bit,
-            cpu_offloading,
-            gptq_config,
+            device=device,
+            num_gpus=num_gpus,
+            max_gpu_memory=max_gpu_memory,
+            load_8bit=load_8bit,
+            cpu_offloading=cpu_offloading,
+            gptq_config=gptq_config,
+            awq_config=awq_config,
         )
         self.device = device
         if self.tokenizer.pad_token == None:
@@ -437,6 +440,11 @@ async def api_model_details(request: Request):
         groupsize=args.gptq_groupsize,
         act_order=args.gptq_act_order,
     )
+    awq_config = AWQConfig(
+        ckpt=args.awq_ckpt or args.model_path,
+        wbits=args.awq_wbits,
+        groupsize=args.awq_groupsize,
+    )
 
     worker = ModelWorker(
         args.controller_address,
@@ -452,6 +460,7 @@ async def api_model_details(request: Request):
         load_8bit=args.load_8bit,
         cpu_offloading=args.cpu_offloading,
         gptq_config=gptq_config,
+        awq_config=awq_config,
         stream_interval=args.stream_interval,
         conv_template=args.conv_template,
     )

Add some default parameters 