File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ def load_tools(screen_modules: List[str] = []):
1313 module_dir = Path (__file__ ).parent / "modules"
1414
1515 for py_file in sorted (module_dir .glob ("*.py" )):
16- if py_file .name .startswith ("_" ) or py_file .stem in ["utils" , "comm" ] + screen_modules :
16+ if py_file .name .startswith ("_" ) or py_file .stem in ["utils" , "comm" , "tool_wrapper" ] + screen_modules :
1717 continue # skipt __init__.py and utils.py
1818
1919 module_name = f"abacusagent.modules.{ py_file .stem } "
@@ -71,6 +71,11 @@ def parse_args():
7171 default = [],
7272 help = "List of modules to screen for loading. If not specified, all modules will be loaded."
7373 )
74+ parser .add_argument (
75+ "--matmaster" ,
76+ action = "store_true" ,
77+ help = "Start the MCP server for MatMaster"
78+ )
7479
7580 args = parser .parse_args ()
7681
@@ -118,7 +123,11 @@ def main():
118123 create_workpath ()
119124
120125 from abacusagent .init_mcp import mcp
121- load_tools (args .screen_modules )
126+
127+ if args .matmaster :
128+ from abacusagent .modules .tool_wrapper import run_abacus_calculation
129+ else :
130+ load_tools (args .screen_modules )
122131
123132 print_address ()
124133 mcp .run (transport = os .environ ["ABACUSAGENT_TRANSPORT" ])
You can’t perform that action at this time.
0 commit comments