meridian-cli 0.0.25__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (145) hide show
  1. meridian_cli-0.0.25/.gitignore +20 -0
  2. meridian_cli-0.0.25/LICENSE +201 -0
  3. meridian_cli-0.0.25/PKG-INFO +367 -0
  4. meridian_cli-0.0.25/README.md +324 -0
  5. meridian_cli-0.0.25/pyproject.toml +107 -0
  6. meridian_cli-0.0.25/src/ag_ui/__init__.pyi +37 -0
  7. meridian_cli-0.0.25/src/ag_ui/core.pyi +33 -0
  8. meridian_cli-0.0.25/src/meridian/__init__.py +5 -0
  9. meridian_cli-0.0.25/src/meridian/__main__.py +6 -0
  10. meridian_cli-0.0.25/src/meridian/cli/__init__.py +5 -0
  11. meridian_cli-0.0.25/src/meridian/cli/app_cmd.py +48 -0
  12. meridian_cli-0.0.25/src/meridian/cli/config_cmd.py +41 -0
  13. meridian_cli-0.0.25/src/meridian/cli/doctor_cmd.py +34 -0
  14. meridian_cli-0.0.25/src/meridian/cli/format_helpers.py +35 -0
  15. meridian_cli-0.0.25/src/meridian/cli/main.py +1323 -0
  16. meridian_cli-0.0.25/src/meridian/cli/models_cmd.py +31 -0
  17. meridian_cli-0.0.25/src/meridian/cli/output.py +227 -0
  18. meridian_cli-0.0.25/src/meridian/cli/registration.py +115 -0
  19. meridian_cli-0.0.25/src/meridian/cli/report_cmd.py +117 -0
  20. meridian_cli-0.0.25/src/meridian/cli/session_cmd.py +133 -0
  21. meridian_cli-0.0.25/src/meridian/cli/spawn.py +747 -0
  22. meridian_cli-0.0.25/src/meridian/cli/spawn_inject.py +112 -0
  23. meridian_cli-0.0.25/src/meridian/cli/streaming_serve.py +175 -0
  24. meridian_cli-0.0.25/src/meridian/cli/utils.py +52 -0
  25. meridian_cli-0.0.25/src/meridian/cli/work_cmd.py +228 -0
  26. meridian_cli-0.0.25/src/meridian/dev/__init__.py +1 -0
  27. meridian_cli-0.0.25/src/meridian/dev/pytests.py +50 -0
  28. meridian_cli-0.0.25/src/meridian/lib/__init__.py +6 -0
  29. meridian_cli-0.0.25/src/meridian/lib/adapters/__init__.py +15 -0
  30. meridian_cli-0.0.25/src/meridian/lib/app/__init__.py +3 -0
  31. meridian_cli-0.0.25/src/meridian/lib/app/agui_mapping/__init__.py +26 -0
  32. meridian_cli-0.0.25/src/meridian/lib/app/agui_mapping/base.py +25 -0
  33. meridian_cli-0.0.25/src/meridian/lib/app/agui_mapping/claude.py +380 -0
  34. meridian_cli-0.0.25/src/meridian/lib/app/agui_mapping/codex.py +257 -0
  35. meridian_cli-0.0.25/src/meridian/lib/app/agui_mapping/extensions.py +37 -0
  36. meridian_cli-0.0.25/src/meridian/lib/app/agui_mapping/opencode.py +247 -0
  37. meridian_cli-0.0.25/src/meridian/lib/app/agui_types.py +80 -0
  38. meridian_cli-0.0.25/src/meridian/lib/app/server.py +271 -0
  39. meridian_cli-0.0.25/src/meridian/lib/app/ws_endpoint.py +243 -0
  40. meridian_cli-0.0.25/src/meridian/lib/catalog/__init__.py +1 -0
  41. meridian_cli-0.0.25/src/meridian/lib/catalog/agent.py +227 -0
  42. meridian_cli-0.0.25/src/meridian/lib/catalog/model_aliases.py +368 -0
  43. meridian_cli-0.0.25/src/meridian/lib/catalog/model_policy.py +196 -0
  44. meridian_cli-0.0.25/src/meridian/lib/catalog/models.py +556 -0
  45. meridian_cli-0.0.25/src/meridian/lib/catalog/skill.py +233 -0
  46. meridian_cli-0.0.25/src/meridian/lib/config/__init__.py +3 -0
  47. meridian_cli-0.0.25/src/meridian/lib/config/settings.py +863 -0
  48. meridian_cli-0.0.25/src/meridian/lib/core/__init__.py +1 -0
  49. meridian_cli-0.0.25/src/meridian/lib/core/codec.py +91 -0
  50. meridian_cli-0.0.25/src/meridian/lib/core/context.py +86 -0
  51. meridian_cli-0.0.25/src/meridian/lib/core/conversation.py +36 -0
  52. meridian_cli-0.0.25/src/meridian/lib/core/domain.py +128 -0
  53. meridian_cli-0.0.25/src/meridian/lib/core/logging.py +41 -0
  54. meridian_cli-0.0.25/src/meridian/lib/core/overrides.py +240 -0
  55. meridian_cli-0.0.25/src/meridian/lib/core/sink.py +90 -0
  56. meridian_cli-0.0.25/src/meridian/lib/core/spawn_lifecycle.py +60 -0
  57. meridian_cli-0.0.25/src/meridian/lib/core/types.py +19 -0
  58. meridian_cli-0.0.25/src/meridian/lib/core/util.py +42 -0
  59. meridian_cli-0.0.25/src/meridian/lib/harness/__init__.py +0 -0
  60. meridian_cli-0.0.25/src/meridian/lib/harness/adapter.py +274 -0
  61. meridian_cli-0.0.25/src/meridian/lib/harness/claude.py +424 -0
  62. meridian_cli-0.0.25/src/meridian/lib/harness/codex.py +512 -0
  63. meridian_cli-0.0.25/src/meridian/lib/harness/common.py +610 -0
  64. meridian_cli-0.0.25/src/meridian/lib/harness/connections/__init__.py +37 -0
  65. meridian_cli-0.0.25/src/meridian/lib/harness/connections/base.py +117 -0
  66. meridian_cli-0.0.25/src/meridian/lib/harness/connections/claude_ws.py +403 -0
  67. meridian_cli-0.0.25/src/meridian/lib/harness/connections/codex_ws.py +535 -0
  68. meridian_cli-0.0.25/src/meridian/lib/harness/connections/opencode_http.py +621 -0
  69. meridian_cli-0.0.25/src/meridian/lib/harness/direct.py +226 -0
  70. meridian_cli-0.0.25/src/meridian/lib/harness/launch_types.py +26 -0
  71. meridian_cli-0.0.25/src/meridian/lib/harness/opencode.py +271 -0
  72. meridian_cli-0.0.25/src/meridian/lib/harness/registry.py +86 -0
  73. meridian_cli-0.0.25/src/meridian/lib/harness/session_detection.py +29 -0
  74. meridian_cli-0.0.25/src/meridian/lib/harness/transcript.py +48 -0
  75. meridian_cli-0.0.25/src/meridian/lib/launch/__init__.py +105 -0
  76. meridian_cli-0.0.25/src/meridian/lib/launch/artifact_io.py +11 -0
  77. meridian_cli-0.0.25/src/meridian/lib/launch/command.py +77 -0
  78. meridian_cli-0.0.25/src/meridian/lib/launch/cwd.py +26 -0
  79. meridian_cli-0.0.25/src/meridian/lib/launch/default_agent_policy.py +103 -0
  80. meridian_cli-0.0.25/src/meridian/lib/launch/env.py +143 -0
  81. meridian_cli-0.0.25/src/meridian/lib/launch/errors.py +110 -0
  82. meridian_cli-0.0.25/src/meridian/lib/launch/extract.py +123 -0
  83. meridian_cli-0.0.25/src/meridian/lib/launch/heartbeat.py +59 -0
  84. meridian_cli-0.0.25/src/meridian/lib/launch/plan.py +378 -0
  85. meridian_cli-0.0.25/src/meridian/lib/launch/process.py +482 -0
  86. meridian_cli-0.0.25/src/meridian/lib/launch/prompt.py +310 -0
  87. meridian_cli-0.0.25/src/meridian/lib/launch/reference.py +175 -0
  88. meridian_cli-0.0.25/src/meridian/lib/launch/report.py +142 -0
  89. meridian_cli-0.0.25/src/meridian/lib/launch/resolve.py +336 -0
  90. meridian_cli-0.0.25/src/meridian/lib/launch/runner.py +1100 -0
  91. meridian_cli-0.0.25/src/meridian/lib/launch/session_ids.py +53 -0
  92. meridian_cli-0.0.25/src/meridian/lib/launch/session_scope.py +69 -0
  93. meridian_cli-0.0.25/src/meridian/lib/launch/signals.py +237 -0
  94. meridian_cli-0.0.25/src/meridian/lib/launch/stream_capture.py +144 -0
  95. meridian_cli-0.0.25/src/meridian/lib/launch/terminal.py +150 -0
  96. meridian_cli-0.0.25/src/meridian/lib/launch/timeout.py +85 -0
  97. meridian_cli-0.0.25/src/meridian/lib/launch/types.py +142 -0
  98. meridian_cli-0.0.25/src/meridian/lib/launch/written_files.py +137 -0
  99. meridian_cli-0.0.25/src/meridian/lib/ops/__init__.py +0 -0
  100. meridian_cli-0.0.25/src/meridian/lib/ops/catalog.py +348 -0
  101. meridian_cli-0.0.25/src/meridian/lib/ops/config.py +888 -0
  102. meridian_cli-0.0.25/src/meridian/lib/ops/diag.py +239 -0
  103. meridian_cli-0.0.25/src/meridian/lib/ops/manifest.py +702 -0
  104. meridian_cli-0.0.25/src/meridian/lib/ops/mars.py +180 -0
  105. meridian_cli-0.0.25/src/meridian/lib/ops/reference.py +205 -0
  106. meridian_cli-0.0.25/src/meridian/lib/ops/report.py +227 -0
  107. meridian_cli-0.0.25/src/meridian/lib/ops/runtime.py +126 -0
  108. meridian_cli-0.0.25/src/meridian/lib/ops/session_log.py +605 -0
  109. meridian_cli-0.0.25/src/meridian/lib/ops/session_search.py +188 -0
  110. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/__init__.py +61 -0
  111. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/api.py +777 -0
  112. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/context_ref.py +140 -0
  113. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/execute.py +887 -0
  114. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/log.py +281 -0
  115. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/models.py +526 -0
  116. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/plan.py +67 -0
  117. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/prepare.py +400 -0
  118. meridian_cli-0.0.25/src/meridian/lib/ops/spawn/query.py +250 -0
  119. meridian_cli-0.0.25/src/meridian/lib/ops/work_attachment.py +33 -0
  120. meridian_cli-0.0.25/src/meridian/lib/ops/work_dashboard.py +543 -0
  121. meridian_cli-0.0.25/src/meridian/lib/ops/work_lifecycle.py +458 -0
  122. meridian_cli-0.0.25/src/meridian/lib/safety/__init__.py +0 -0
  123. meridian_cli-0.0.25/src/meridian/lib/safety/budget.py +121 -0
  124. meridian_cli-0.0.25/src/meridian/lib/safety/guardrails.py +127 -0
  125. meridian_cli-0.0.25/src/meridian/lib/safety/permissions.py +303 -0
  126. meridian_cli-0.0.25/src/meridian/lib/safety/redaction.py +65 -0
  127. meridian_cli-0.0.25/src/meridian/lib/state/__init__.py +57 -0
  128. meridian_cli-0.0.25/src/meridian/lib/state/artifact_store.py +109 -0
  129. meridian_cli-0.0.25/src/meridian/lib/state/atomic.py +73 -0
  130. meridian_cli-0.0.25/src/meridian/lib/state/event_store.py +105 -0
  131. meridian_cli-0.0.25/src/meridian/lib/state/paths.py +228 -0
  132. meridian_cli-0.0.25/src/meridian/lib/state/reaper.py +492 -0
  133. meridian_cli-0.0.25/src/meridian/lib/state/reaper_config.py +16 -0
  134. meridian_cli-0.0.25/src/meridian/lib/state/session_store.py +671 -0
  135. meridian_cli-0.0.25/src/meridian/lib/state/spawn_store.py +605 -0
  136. meridian_cli-0.0.25/src/meridian/lib/state/work_store.py +420 -0
  137. meridian_cli-0.0.25/src/meridian/lib/streaming/__init__.py +13 -0
  138. meridian_cli-0.0.25/src/meridian/lib/streaming/control_socket.py +107 -0
  139. meridian_cli-0.0.25/src/meridian/lib/streaming/spawn_manager.py +420 -0
  140. meridian_cli-0.0.25/src/meridian/lib/streaming/types.py +45 -0
  141. meridian_cli-0.0.25/src/meridian/lib/utils/__init__.py +1 -0
  142. meridian_cli-0.0.25/src/meridian/lib/utils/time.py +11 -0
  143. meridian_cli-0.0.25/src/meridian/py.typed +0 -0
  144. meridian_cli-0.0.25/src/meridian/server/__init__.py +10 -0
  145. meridian_cli-0.0.25/src/meridian/server/main.py +79 -0
@@ -0,0 +1,20 @@
1
+ __pycache__/
2
+ *.pyc
3
+ *.pyo
4
+ .venv/
5
+ *.egg-info/
6
+ dist/
7
+ build/
8
+ .pytest_cache/
9
+ .ruff_cache/
10
+
11
+ scratch/
12
+ tmp/
13
+
14
+ .orchestrate/
15
+ .scratch/
16
+ .codex/config.toml
17
+
18
+ err
19
+ out
20
+ .mars/
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2026 Jimmy Yao
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
@@ -0,0 +1,367 @@
1
+ Metadata-Version: 2.4
2
+ Name: meridian-cli
3
+ Version: 0.0.25
4
+ Summary: Orchestrate CLI + MCP server for multi-model agent workflows
5
+ Project-URL: Homepage, https://github.com/meridian-flow/meridian-cli
6
+ Project-URL: Repository, https://github.com/meridian-flow/meridian-cli
7
+ Project-URL: Issues, https://github.com/meridian-flow/meridian-cli/issues
8
+ License: MIT
9
+ License-File: LICENSE
10
+ Classifier: Development Status :: 3 - Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: MIT License
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Programming Language :: Python :: 3.13
17
+ Classifier: Programming Language :: Python :: 3.14
18
+ Classifier: Topic :: Software Development :: Libraries
19
+ Classifier: Topic :: Utilities
20
+ Requires-Python: >=3.12
21
+ Requires-Dist: aiohttp>=3.11
22
+ Requires-Dist: coolname>=4.0.0
23
+ Requires-Dist: cyclopts>=3.0
24
+ Requires-Dist: mars-agents==0.0.13
25
+ Requires-Dist: mcp>=1.0
26
+ Requires-Dist: pydantic-settings>=2.13
27
+ Requires-Dist: pydantic>=2.12
28
+ Requires-Dist: python-frontmatter>=1.1
29
+ Requires-Dist: structlog>=25.0
30
+ Provides-Extra: app
31
+ Requires-Dist: ag-ui-protocol>=0.1; extra == 'app'
32
+ Requires-Dist: fastapi>=0.115; extra == 'app'
33
+ Requires-Dist: uvicorn[standard]>=0.34; extra == 'app'
34
+ Requires-Dist: websockets>=14.0; extra == 'app'
35
+ Provides-Extra: dev
36
+ Requires-Dist: pyright>=1.1.400; extra == 'dev'
37
+ Requires-Dist: pytest-asyncio>=0.24.0; extra == 'dev'
38
+ Requires-Dist: pytest>=8.4.0; extra == 'dev'
39
+ Requires-Dist: ruff>=0.12.0; extra == 'dev'
40
+ Provides-Extra: templates
41
+ Requires-Dist: jinja2>=3.1; extra == 'templates'
42
+ Description-Content-Type: text/markdown
43
+
44
+ # meridian
45
+
46
+ [PyPI](https://pypi.org/project/meridian-cli/)
47
+ [Python](https://pypi.org/project/meridian-cli/)
48
+ [License](LICENSE)
49
+ [CI](https://github.com/meridian-flow/meridian-cli/actions)
50
+
51
+ > **Alpha** — API may change between releases.
52
+
53
+ A coordination layer for AI agents. One agent spawns others, routes them to the
54
+ right model, and reads their results — across Claude, Codex, and OpenCode.
55
+
56
+ You talk to one agent. It delegates the rest.
57
+
58
+ ## What This Looks Like
59
+
60
+ You say: *"Refactor the auth module to use JWT tokens."*
61
+
62
+ The orchestrator agent — running inside Claude, Codex, or any supported
63
+ harness — autonomously runs commands like these:
64
+
65
+ ```bash
66
+ # Spawn a researcher on a fast model to explore the codebase
67
+ meridian spawn -a researcher -p "Map the auth module — token handling, session management, middleware"
68
+ # → {"spawn_id": "p1", "status": "running", "model": "gpt-5.3-codex"}
69
+
70
+ # Wait for it, then read what it found
71
+ meridian spawn wait p1
72
+ meridian spawn show p1
73
+
74
+ # Spawn coders in parallel on Codex, passing the researcher's findings
75
+ meridian spawn -a coder --from p1 -p "Phase 1: Replace session tokens with JWT" -f src/auth/tokens.py
76
+ # → {"spawn_id": "p2", "model": "gpt-5.3-codex"}
77
+ meridian spawn -a coder --from p1 -p "Phase 2: Update middleware validation" -f src/auth/middleware.py
78
+ # → {"spawn_id": "p3", "model": "gpt-5.3-codex"}
79
+ meridian spawn wait p2 p3
80
+
81
+ # Fan out reviewers with different focus areas
82
+ meridian spawn -a reviewer --from p2 -p "Review phase 1 — focus on token expiry edge cases"
83
+ # → {"spawn_id": "p4", "model": "gpt-5.4"}
84
+ meridian spawn show p4
85
+
86
+ # Pick up context from a prior session
87
+ meridian session search "auth refactor"
88
+ meridian report search "JWT decision"
89
+ ```
90
+
91
+ Every spawn writes logs, reports, and metadata to shared state under `.meridian/`.
92
+ The orchestrator reads those reports, decides what to do next, and keeps going.
93
+ If the session gets compacted or resumed later, the state is still there.
94
+
95
+ **The human doesn't run these commands.** The agent does — meridian is the CLI
96
+ that agents use to coordinate other agents.
97
+
98
+ ## Agent Packages
99
+
100
+ **[meridian-dev-workflow](https://github.com/meridian-flow/meridian-dev-workflow)** — A full dev team: architects, coders, reviewers, testers, researchers, documenters, and the orchestrators that coordinate them. Includes skills for design methodology, implementation planning, code review, and structural hygiene. This is what most users want.
101
+
102
+ **[meridian-base](https://github.com/meridian-flow/meridian-base)** — Core coordination primitives: the base orchestrator, subagent, and skills for spawning, state tracking, and session context. Included as a dependency of meridian-dev-workflow.
103
+
104
+ Packages are managed by **[mars](https://github.com/meridian-flow/mars-agents)**, an agent package manager that installs agent profiles and skills from git sources into your project's `.agents/` directory.
105
+
106
+ ## Install
107
+
108
+ ```bash
109
+ uv tool install meridian-cli
110
+ ```
111
+
112
+ Verify:
113
+
114
+ ```bash
115
+ meridian --version
116
+ meridian doctor
117
+ ```
118
+
119
+ Alternative install methods
120
+
121
+ ```bash
122
+ pipx install meridian-cli # if you prefer pipx
123
+ pip install meridian-cli # into a Python environment
124
+ ```
125
+
126
+ From source:
127
+
128
+ ```bash
129
+ git clone https://github.com/meridian-flow/meridian-cli.git
130
+ cd meridian-cli
131
+ uv tool install --force . --no-cache --reinstall
132
+ ```
133
+
134
+ Development environment (no tool install):
135
+
136
+ ```bash
137
+ uv sync --extra dev
138
+ uv run meridian --help
139
+ ```
140
+
141
+ If `meridian` is not on your PATH: `uv tool update-shell`
142
+
143
+
144
+
145
+ ## Set Up a Project
146
+
147
+ ```bash
148
+ cd your-project
149
+ meridian init --link .claude
150
+ meridian mars add meridian-flow/meridian-dev-workflow
151
+ ```
152
+
153
+ This initializes `.meridian/`, links `.agents/` into `.claude/` so Claude Code
154
+ discovers your agents and skills, and installs the full dev team (coder,
155
+ reviewers, testers, architect, etc.) plus core coordination primitives.
156
+
157
+ For just the core primitives:
158
+
159
+ ```bash
160
+ meridian mars add meridian-flow/meridian-base
161
+ ```
162
+
163
+ To link into other tool directories (e.g. Cursor):
164
+
165
+ ```bash
166
+ meridian mars link .cursor
167
+ ```
168
+
169
+ ### Prerequisites
170
+
171
+ **Platforms:** macOS and Linux. Windows is supported via
172
+ [WSL](https://learn.microsoft.com/en-us/windows/wsl/) (native Windows is not
173
+ supported).
174
+
175
+ You need at least one harness CLI installed and authenticated:
176
+
177
+
178
+ | Harness | Model prefixes | Install |
179
+ | ----------- | ------------------------------- | -------------------------------------------------------------------- |
180
+ | Claude Code | `claude-`*, `sonnet*`, `opus*` | [docs.anthropic.com](https://docs.anthropic.com/en/docs/claude-code) |
181
+ | Codex CLI | `gpt-*`, `codex*`, `o3*`, `o4*` | [github.com/openai/codex](https://github.com/openai/codex) |
182
+ | OpenCode | anything else | [opencode.ai](https://opencode.ai) |
183
+
184
+
185
+ Claude and Codex are the most exercised paths today. OpenCode has adapter
186
+ support but lighter day-to-day coverage.
187
+
188
+ **Primary session:** Only Claude Code supports system prompt injection
189
+ (`--append-system-prompt`), which is how Meridian loads agent skills into the
190
+ primary session. Codex and OpenCode work well as **spawn targets** but aren't
191
+ as suited as the primary harness.
192
+
193
+ ### Tool integration (Claude Code, Cursor, etc.)
194
+
195
+ If you didn't pass `--link .claude` during `meridian init`, you can link later:
196
+
197
+ ```bash
198
+ meridian mars link .claude
199
+ ```
200
+
201
+ This symlinks `.agents/` into `.claude/` so Claude Code auto-discovers your
202
+ installed agents and skills. Without linking, `meridian spawn` still works
203
+ (it injects context directly), but interactive sessions won't auto-discover
204
+ agents and skills.
205
+
206
+ To unlink: `meridian mars link --unlink .claude`
207
+
208
+ ## Quick Start
209
+
210
+ ```bash
211
+ meridian # Launch a primary agent session
212
+ ```
213
+
214
+ That's it. The agent gets meridian's coordination skills injected automatically
215
+ and can start spawning work. In a separate shell, you can also drive spawns
216
+ directly:
217
+
218
+ ```bash
219
+ meridian spawn -m codex -p "Fix the flaky test in tests/auth/"
220
+ meridian spawn list
221
+ meridian spawn wait p1
222
+ meridian spawn show p1
223
+ ```
224
+
225
+ ## Architecture
226
+
227
+ ```mermaid
228
+ graph TB
229
+ User([You]) --> Primary["meridian<br/>(primary session)"]
230
+
231
+ subgraph Packages
232
+ Sources["git sources"] -->|"meridian mars add/sync"| Mars["mars"]
233
+ Mars --> Agents[".agents/"]
234
+ Agents -->|"meridian mars link"| Tool[".claude/ · .cursor/"]
235
+ end
236
+
237
+ subgraph Runtime
238
+ Primary -->|"meridian spawn"| Router{"Model router"}
239
+ Router --> Claude["Claude Code"]
240
+ Router --> Codex["Codex CLI"]
241
+ Router --> OpenCode["OpenCode"]
242
+ end
243
+
244
+ subgraph State[".meridian/"]
245
+ Spawns["spawns + reports"]
246
+ Sessions["sessions"]
247
+ Work["work items + fs"]
248
+ end
249
+
250
+ Agents --> Primary
251
+ Primary --> State
252
+ Claude & Codex & OpenCode -->|"meridian CLI"| State
253
+ ```
254
+
255
+
256
+
257
+ ## Commands
258
+
259
+ **Spawning & monitoring:**
260
+
261
+
262
+ | Command | Description |
263
+ | ---------------------------------------- | ---------------------------------- |
264
+ | `meridian` | Launch the primary agent session |
265
+ | `meridian spawn -a AGENT -p "task"` | Delegate work to a routed model |
266
+ | `meridian spawn list` | See running and recent spawns |
267
+ | `meridian spawn wait ID` | Block until a spawn completes |
268
+ | `meridian spawn show ID` | Read a spawn's report |
269
+ | `meridian spawn --continue ID -p "more"` | Continue a prior spawn |
270
+ | `meridian spawn --from ID -p "next"` | Start new spawn with prior context |
271
+
272
+
273
+ **Reports & sessions:**
274
+
275
+
276
+ | Command | Description |
277
+ | --------------------------------- | ------------------------------- |
278
+ | `meridian report search "query"` | Search across all spawn reports |
279
+ | `meridian session search "query"` | Search session transcripts |
280
+
281
+
282
+ **Configuration & diagnostics:**
283
+
284
+
285
+ | Command | Description |
286
+ | ------------------------------- | --------------------------------------------------------------------- |
287
+ | `meridian init [--link DIR]` | Initialize project (`.meridian/`, `mars.toml`, optional tool linking) |
288
+ | `meridian config show` | Show resolved config and bootstrap `.meridian/` on first run |
289
+ | `meridian config set KEY VALUE` | Set a config value |
290
+ | `meridian models config show` | Show `.meridian/models.toml` policy overrides |
291
+ | `meridian models list` | Inspect the model catalog |
292
+ | `meridian doctor` | Run diagnostics |
293
+ | `meridian serve` | Start the MCP server |
294
+
295
+
296
+ **Package management (mars):**
297
+
298
+
299
+ | Command | Description |
300
+ | -------------------------- | -------------------------------------------- |
301
+ | `meridian mars add SOURCE` | Add an agent/skill package source |
302
+ | `meridian mars sync` | Resolve and install packages into `.agents/` |
303
+ | `meridian mars link DIR` | Symlink `.agents/` into a tool directory |
304
+ | `meridian mars list` | Show installed agents and skills |
305
+ | `meridian mars upgrade` | Fetch latest versions and sync |
306
+
307
+
308
+ ## State Layout
309
+
310
+ All state is files under `.meridian/` — no databases, no services. If it's not
311
+ on disk, it doesn't exist.
312
+
313
+ ```
314
+ .meridian/
315
+ .gitignore # Tracks shared repo state, ignores machine-local state
316
+ spawns.jsonl # Spawn event log
317
+ sessions.jsonl # Session event log
318
+ spawns/
319
+ p1/
320
+ output.jsonl # Spawn output
321
+ stderr.log # Stderr capture
322
+ report.md # Agent's report
323
+ fs/ # Shared filesystem between spawns
324
+ work-items/ # Work item metadata
325
+ work/ # Work item directories
326
+ work-archive/ # Completed work item scratch/docs
327
+ config.toml # Repo configuration
328
+ models.toml # Model aliases, routing, and visibility overrides
329
+ ```
330
+
331
+ Writes use `fcntl.flock` plus atomic tmp+rename. If meridian is killed
332
+ mid-spawn, the next read detects and reports the orphaned state.
333
+
334
+ ## Troubleshooting
335
+
336
+ `**meridian` not found** — Run `uv tool update-shell` and restart your shell.
337
+
338
+ `**meridian doctor` reports missing harnesses** — Install and authenticate at
339
+ least one harness CLI (see Prerequisites).
340
+
341
+ **Model routes to wrong harness** — Check `meridian models list` and
342
+ `meridian config show`.
343
+
344
+ **Spawn feels disconnected from earlier work** — Use `--continue ID` for
345
+ session continuity, `--from ID` for context injection, or search past work
346
+ with `meridian report search`.
347
+
348
+ ## Documentation
349
+
350
+ - [Configuration](docs/configuration.md) — config keys, overrides, environment variables
351
+ - [MCP Tools](docs/mcp-tools.md) — FastMCP tool surface and payload examples
352
+ - [INSTALL.md](INSTALL.md) — agent-friendly install guide (give this URL to your LLM)
353
+
354
+ ## Development
355
+
356
+ ```bash
357
+ uv sync --extra dev
358
+ uv run ruff check .
359
+ uv run pytest-llm
360
+ uv run pyright
361
+ ```
362
+
363
+ See [DEVELOPMENT.md](DEVELOPMENT.md) for full dev setup.
364
+
365
+ ## License
366
+
367
+ [MIT](LICENSE)