MCPcopy Create free account
hub / github.com/FreedomIntelligence/LLMZoo / main

Function main

llmzoo/deploy/cli.py:93–116  ·  view source on GitHub ↗
(args)

Source from the content-addressed store, hash-verified

91
92
93def main(args):
94 if args.style == "simple":
95 chatio = SimpleChatIO()
96 elif args.style == "rich":
97 chatio = RichChatIO()
98 else:
99 raise ValueError(f"Invalid style for console: {args.style}")
100 try:
101 assert not (args.load_8bit and args.load_4bit), "Int8 is not compatible with Int4."
102 chat_loop(
103 args.model_path,
104 args.device,
105 args.num_gpus,
106 args.max_gpu_memory,
107 args.load_8bit,
108 args.load_4bit,
109 args.conv_template,
110 args.temperature,
111 args.max_new_tokens,
112 chatio,
113 args.debug,
114 )
115 except KeyboardInterrupt:
116 print("exit...")
117
118
119if __name__ == "__main__":

Callers 1

cli.pyFile · 0.85

Calls 3

chat_loopFunction · 0.90
SimpleChatIOClass · 0.85
RichChatIOClass · 0.85

Tested by

no test coverage detected