| 36 | return builder.build_from_file_paths(prompt, attachment_paths) |
| 37 | |
| 38 | def parse_arguments(): |
| 39 | parser = argparse.ArgumentParser(description="Run ChatDev_new workflow") |
| 40 | parser.add_argument( |
| 41 | "--path", |
| 42 | type=Path, |
| 43 | default=Path("yaml_instance/net_loop_test_included.yaml"), |
| 44 | help="Path to the design_0.4.0 workflow file", |
| 45 | ) |
| 46 | parser.add_argument( |
| 47 | "--name", |
| 48 | type=str, |
| 49 | default="test_project", |
| 50 | help="Name of the project", |
| 51 | ) |
| 52 | parser.add_argument( |
| 53 | "--fn-module", |
| 54 | dest="fn_module", |
| 55 | default=None, |
| 56 | help="Optional module providing edge helper functions referenced by the design", |
| 57 | ) |
| 58 | parser.add_argument( |
| 59 | "--inspect-schema", |
| 60 | action="store_true", |
| 61 | help="Output configuration schema (optionally scoped by breadcrumbs) and exit", |
| 62 | ) |
| 63 | parser.add_argument( |
| 64 | "--schema-breadcrumbs", |
| 65 | type=str, |
| 66 | default=None, |
| 67 | help="JSON array describing schema breadcrumbs (e.g. '[{\"node\":\"DesignConfig\",\"field\":\"graph\"}]')", |
| 68 | ) |
| 69 | parser.add_argument( |
| 70 | "--attachment", |
| 71 | action="append", |
| 72 | default=[], |
| 73 | help="Path to a file to attach to the initial user message (repeatable)", |
| 74 | ) |
| 75 | return parser.parse_args() |
| 76 | |
| 77 | def main() -> None: |
| 78 | args = parse_arguments() |