whitehalo 1.3.0rc2__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.
- whitehalo-1.3.0rc2/.gitignore +113 -0
- whitehalo-1.3.0rc2/APACHE-2.0.txt +201 -0
- whitehalo-1.3.0rc2/LICENSE +35 -0
- whitehalo-1.3.0rc2/PKG-INFO +133 -0
- whitehalo-1.3.0rc2/README.md +105 -0
- whitehalo-1.3.0rc2/pyproject.toml +103 -0
- whitehalo-1.3.0rc2/src/whitehalo/__init__.py +300 -0
- whitehalo-1.3.0rc2/src/whitehalo/_catalog.py +34 -0
- whitehalo-1.3.0rc2/src/whitehalo/api.py +1573 -0
- whitehalo-1.3.0rc2/src/whitehalo/cli.py +788 -0
- whitehalo-1.3.0rc2/src/whitehalo/codec.py +89 -0
- whitehalo-1.3.0rc2/src/whitehalo/config_stage.py +166 -0
- whitehalo-1.3.0rc2/src/whitehalo/docker_api.py +781 -0
- whitehalo-1.3.0rc2/src/whitehalo/errors.py +296 -0
- whitehalo-1.3.0rc2/src/whitehalo/executor.py +259 -0
- whitehalo-1.3.0rc2/src/whitehalo/images.py +228 -0
- whitehalo-1.3.0rc2/src/whitehalo/planner.py +714 -0
- whitehalo-1.3.0rc2/src/whitehalo/probe.py +408 -0
- whitehalo-1.3.0rc2/src/whitehalo/py.typed +0 -0
- whitehalo-1.3.0rc2/src/whitehalo/transport.py +374 -0
- whitehalo-1.3.0rc2/src/whitehalo/types.py +899 -0
- whitehalo-1.3.0rc2/tests/test_cli_and_schemas.py +183 -0
- whitehalo-1.3.0rc2/tests/test_conventions.py +124 -0
- whitehalo-1.3.0rc2/tests/test_planner_and_api.py +556 -0
- whitehalo-1.3.0rc2/tests/test_probe_and_images.py +226 -0
- whitehalo-1.3.0rc2/tests/test_transport_and_docker_api.py +334 -0
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
wandb/
|
|
10
|
+
/data/
|
|
11
|
+
# Skills live at skills/ (repo root); .claude/skills and .agents/skills are tracked symlinks to it
|
|
12
|
+
# (Claude Code and Codex discovery). Ignore all other personal/local agent state (settings, locks).
|
|
13
|
+
.claude/*
|
|
14
|
+
!.claude/skills
|
|
15
|
+
.agents/*
|
|
16
|
+
!.agents/skills
|
|
17
|
+
.cursor/
|
|
18
|
+
# Local editor and OS state.
|
|
19
|
+
.vscode/
|
|
20
|
+
.DS_Store
|
|
21
|
+
|
|
22
|
+
# checkpoints
|
|
23
|
+
checkpoints/*
|
|
24
|
+
|
|
25
|
+
# Distribution / packaging
|
|
26
|
+
.Python
|
|
27
|
+
/build/
|
|
28
|
+
develop-eggs/
|
|
29
|
+
dist/
|
|
30
|
+
downloads/
|
|
31
|
+
eggs/
|
|
32
|
+
.eggs/
|
|
33
|
+
/lib/
|
|
34
|
+
lib64/
|
|
35
|
+
/parts/
|
|
36
|
+
sdist/
|
|
37
|
+
var/
|
|
38
|
+
wheels/
|
|
39
|
+
share/python-wheels/
|
|
40
|
+
*.egg-info/
|
|
41
|
+
.installed.cfg
|
|
42
|
+
*.egg
|
|
43
|
+
MANIFEST
|
|
44
|
+
|
|
45
|
+
# Installer logs
|
|
46
|
+
pip-log.txt
|
|
47
|
+
pip-delete-this-directory.txt
|
|
48
|
+
|
|
49
|
+
# Unit test / coverage reports
|
|
50
|
+
htmlcov/
|
|
51
|
+
.tox/
|
|
52
|
+
.nox/
|
|
53
|
+
.coverage
|
|
54
|
+
.coverage.*
|
|
55
|
+
.cache
|
|
56
|
+
nosetests.xml
|
|
57
|
+
coverage.xml
|
|
58
|
+
*.cover
|
|
59
|
+
*.py,cover
|
|
60
|
+
.hypothesis/
|
|
61
|
+
.pytest_cache/
|
|
62
|
+
cover/
|
|
63
|
+
.gradio/
|
|
64
|
+
|
|
65
|
+
# Logs
|
|
66
|
+
*.log
|
|
67
|
+
|
|
68
|
+
# Jupyter Notebook
|
|
69
|
+
.ipynb_checkpoints
|
|
70
|
+
|
|
71
|
+
# IPython
|
|
72
|
+
profile_default/
|
|
73
|
+
ipython_config.py
|
|
74
|
+
|
|
75
|
+
# Environments
|
|
76
|
+
.env
|
|
77
|
+
.env.*
|
|
78
|
+
!.env.example
|
|
79
|
+
.venv
|
|
80
|
+
/env/
|
|
81
|
+
venv/
|
|
82
|
+
ENV/
|
|
83
|
+
env.bak/
|
|
84
|
+
venv.bak/
|
|
85
|
+
|
|
86
|
+
# mypy
|
|
87
|
+
.mypy_cache/
|
|
88
|
+
.dmypy.json
|
|
89
|
+
dmypy.json
|
|
90
|
+
|
|
91
|
+
# Pyre type checker
|
|
92
|
+
.pyre/
|
|
93
|
+
|
|
94
|
+
# pytype static type analyzer
|
|
95
|
+
.pytype/
|
|
96
|
+
|
|
97
|
+
# Cython debug symbols
|
|
98
|
+
cython_debug/
|
|
99
|
+
|
|
100
|
+
# PyCharm
|
|
101
|
+
.idea/
|
|
102
|
+
|
|
103
|
+
/models/
|
|
104
|
+
|
|
105
|
+
# Run output (training scripts and profiling write these at the repo root)
|
|
106
|
+
/out/
|
|
107
|
+
trainer_output/
|
|
108
|
+
# Equivalence harness records (make verify-move / verify-artifacts), one per head commit
|
|
109
|
+
/evidence/
|
|
110
|
+
|
|
111
|
+
# Local-only signing keys / credentials (never commit)
|
|
112
|
+
keys/
|
|
113
|
+
*.pem
|
|
@@ -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 WhiteCircle AI
|
|
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,35 @@
|
|
|
1
|
+
# Halo License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 White Circle, PBC
|
|
4
|
+
|
|
5
|
+
The Work is licensed under the Apache License, Version 2.0 ("Apache License"; available at http://www.apache.org/licenses/LICENSE-2.0), as modified by, and subject to, the Supplemental Terms set out below. A copy of the Apache License is provided in the file APACHE-2.0.txt for reference. In the event of any conflict, the Supplemental Terms prevail. Capitalized terms used but not defined in the Supplemental Terms — including "Work," "Derivative Works," "Legal Entity" and "You" — have the meanings given in the Apache License.
|
|
6
|
+
|
|
7
|
+
## Supplemental Terms
|
|
8
|
+
|
|
9
|
+
**1. Definitions.**
|
|
10
|
+
|
|
11
|
+
"**Affiliate**" means, with respect to You, any Legal Entity that controls, is controlled by, or is under common control with You, applying the definition of "control" in the Apache License.
|
|
12
|
+
|
|
13
|
+
"**Annual Revenue**" means the total gross revenue of You and Your Affiliates for Your most recently completed fiscal year.
|
|
14
|
+
|
|
15
|
+
"**Training as a Service**" means providing third parties with the ability to initiate, configure, or direct the training, fine-tuning, or post-training functionality of the Work or Derivative Works, including through any interface, API, hosted platform, or managed service You make available such that the third party selects or supplies the training data, sets or configures the training objectives or parameters, or otherwise directs the training runs. Training as a Service does not include: (a) use of the Work by or for You to train, fine-tune, or evaluate models, including models You subsequently distribute or deploy in Your own products and services; or (b) professional or consulting services in which Your personnel retain operational control of the training pipeline and perform training on a customer's behalf, even where the customer supplies data or specifies requirements.
|
|
16
|
+
|
|
17
|
+
"**TaaS Revenue**" means the aggregate gross revenue of You and Your Affiliates that is directly attributable to a Training as a Service offering, measured over any twelve (12) consecutive months.
|
|
18
|
+
|
|
19
|
+
"**Threshold Amount**" means US $20,000,000.
|
|
20
|
+
|
|
21
|
+
**2. Training as a Service.**
|
|
22
|
+
|
|
23
|
+
(a) You may make the Work or Derivative Works available as Training as a Service under the Apache License at no charge until TaaS Revenue first exceeds the Threshold Amount.
|
|
24
|
+
|
|
25
|
+
(b) If TaaS Revenue exceeds the Threshold Amount, You must, within thirty (30) days after the end of the twelve-month period in which the threshold was exceeded, enter into a separate commercial agreement with White Circle (hello@whitecircle.com) governing continued provision of the Training as a Service offering. White Circle agrees to offer such an agreement on fair, reasonable, and non-discriminatory terms.
|
|
26
|
+
|
|
27
|
+
(c) If You do not enter into such an agreement within the period in subsection (b) as it may be extended while the parties negotiate in good faith, Your license to provide new Training as a Service under this License terminates, and You must cease onboarding new Training as a Service customers. You must cease providing Training as a Service to Your existing Training as a Service customers no later than ninety (90) days after termination. For the avoidance of doubt, termination under this Section 2 does not affect: (i) Your rights under Section 4; (ii) any models already trained, or any Derivative Works already distributed or deployed, before termination; or (iii) the rights of Your existing end customers in respect of models already trained for them, which does not permit You to continue providing Training as a Service beyond the period stated in this subsection (c).
|
|
28
|
+
|
|
29
|
+
(d) Revenue is measured across You and Your Affiliates on a combined basis; restructuring an offering among Affiliates does not reset or avoid the Threshold Amount.
|
|
30
|
+
|
|
31
|
+
**3. Attribution.** If Your Annual Revenue exceeds the Threshold Amount and You publicly release or commercially deploy any model trained using the Work or Derivative Works, You must include the following attribution in the model card or accompanying documentation: "Trained with Halo (https://github.com/whitecircle/halo)." White Circle grants You a limited, non-exclusive, royalty-free license to use the "Halo" name and mark solely to provide the attribution required by this Section 3. Section 6 of the Apache License otherwise applies. If You fail to provide the attribution required by this Section 3 and do not cure that failure within thirty (30) days after written notice from White Circle, Your rights under this License to publicly release or commercially deploy models trained using the Work or Derivative Works terminate. Those rights are reinstated upon cure.
|
|
32
|
+
|
|
33
|
+
**4. Reservation.** Except as expressly provided in Sections 2, 3 and 5, all rights granted under the Apache License — including use, reproduction, preparation of Derivative Works, distribution, and internal use at any scale — remain unrestricted.
|
|
34
|
+
|
|
35
|
+
**5. Redistribution Subject to These Terms.** If You distribute the Work or any Derivative Works, You must include a complete copy of this Halo License, including these Supplemental Terms, with the distribution, and You may not license or purport to license the Work or Derivative Works to any recipient on terms that omit, or conflict with, these Supplemental Terms. Each recipient receives the Work and Derivative Works subject to these Supplemental Terms.
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: whitehalo
|
|
3
|
+
Version: 1.3.0rc2
|
|
4
|
+
Summary: Lightweight, zero-torch launcher and agent-native Python SDK for Halo Docker runtimes.
|
|
5
|
+
Project-URL: Homepage, https://whitecircle.com/halo/docs
|
|
6
|
+
Project-URL: Documentation, https://whitecircle.com/halo/docs
|
|
7
|
+
Project-URL: Repository, https://github.com/whitecircle/halo
|
|
8
|
+
Project-URL: Issues, https://github.com/whitecircle/halo/issues
|
|
9
|
+
Author-email: White Circle <hello@whitecircle.com>
|
|
10
|
+
License-Expression: LicenseRef-Halo
|
|
11
|
+
License-File: APACHE-2.0.txt
|
|
12
|
+
License-File: LICENSE
|
|
13
|
+
Keywords: docker,grpo,halo,launcher,llm,sft,training,whitecircle
|
|
14
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
15
|
+
Classifier: Intended Audience :: Developers
|
|
16
|
+
Classifier: Intended Audience :: Science/Research
|
|
17
|
+
Classifier: Operating System :: OS Independent
|
|
18
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
22
|
+
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
|
|
23
|
+
Classifier: Typing :: Typed
|
|
24
|
+
Requires-Python: >=3.12
|
|
25
|
+
Requires-Dist: msgspec[yaml]<1.0.0,>=0.20.0
|
|
26
|
+
Requires-Dist: niquests<4.0.0,>=3.15.0
|
|
27
|
+
Description-Content-Type: text/markdown
|
|
28
|
+
|
|
29
|
+
# whitehalo
|
|
30
|
+
|
|
31
|
+
Lightweight, zero-torch launcher and agent-native Python SDK for [Halo](https://github.com/whitecircle/halo).
|
|
32
|
+
|
|
33
|
+
`whitehalo` does **not** install or compile PyTorch, Flash Attention, DeepEP, DeepGEMM, or CUDA kernels on your host. Instead, it manages and launches prebuilt Halo Docker images (`public.ecr.aws/whitecircle/halo`) from the host—and automatically dispatches directly to the local Halo runtime when executed inside a Halo container.
|
|
34
|
+
|
|
35
|
+
## Install
|
|
36
|
+
|
|
37
|
+
Requires Python 3.12+ (runs cleanly on your host and natively inside Halo Docker containers).
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
pip install whitehalo
|
|
41
|
+
# or
|
|
42
|
+
uvx whitehalo doctor
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
## Quickstart (CLI)
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
# 1. Check Docker daemon, NVIDIA runtime, GPU architecture, local images, and scratch disk
|
|
49
|
+
whitehalo doctor
|
|
50
|
+
|
|
51
|
+
# 2. Pull the matching prebuilt Blackwell or Hopper Docker image (no AWS login required)
|
|
52
|
+
whitehalo setup
|
|
53
|
+
# Include vLLM or SGLang rollout server images for online / environmental GRPO:
|
|
54
|
+
whitehalo setup --with-vllm
|
|
55
|
+
|
|
56
|
+
# 3. Preview the exact launch command without side effects
|
|
57
|
+
whitehalo launch sft examples/sft/qwen3/qwen3-4b-ultrachat-lora.yaml --dry-run
|
|
58
|
+
|
|
59
|
+
# 4. Launch training (works with zero repo clone, or bind-mounts your local Halo checkout)
|
|
60
|
+
whitehalo launch sft examples/sft/qwen3/qwen3-4b-ultrachat-lora.yaml -n 1 -- --report_to=none
|
|
61
|
+
|
|
62
|
+
# 5. Run a Halo post-training / data / White Circle tool
|
|
63
|
+
whitehalo run create-whitecircle-policies -- --environment-id <env_id> --policies policies.json
|
|
64
|
+
|
|
65
|
+
# 6. Drop into an interactive Halo shell with all mounts, ulimits, and GPU flags configured
|
|
66
|
+
whitehalo shell
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
## Quickstart (Python SDK)
|
|
70
|
+
|
|
71
|
+
Every request and response type is a strictly typed frozen `msgspec.Struct` or `StrEnum`.
|
|
72
|
+
|
|
73
|
+
```python
|
|
74
|
+
from pathlib import Path
|
|
75
|
+
from whitehalo import (
|
|
76
|
+
BuiltinExample,
|
|
77
|
+
ConfigEntry,
|
|
78
|
+
ConfigOverride,
|
|
79
|
+
ContainerOptions,
|
|
80
|
+
GpuArch,
|
|
81
|
+
HaloClient,
|
|
82
|
+
ImageRole,
|
|
83
|
+
InlineConfig,
|
|
84
|
+
LaunchRequest,
|
|
85
|
+
SetupRequest,
|
|
86
|
+
TrainingMethod,
|
|
87
|
+
)
|
|
88
|
+
|
|
89
|
+
with HaloClient() as client:
|
|
90
|
+
# Pull the GPU-matched Halo image
|
|
91
|
+
client.setup(SetupRequest(arch=GpuArch.AUTO, roles=(ImageRole.TRAINER,)))
|
|
92
|
+
|
|
93
|
+
# Verify Docker/Podman, GPU runtime, image, and scratch space
|
|
94
|
+
report = client.doctor()
|
|
95
|
+
report.raise_for_errors()
|
|
96
|
+
|
|
97
|
+
# Launch a built-in example with typed overrides (zero repo clone required)
|
|
98
|
+
result = client.launch(
|
|
99
|
+
LaunchRequest(
|
|
100
|
+
method=TrainingMethod.SFT,
|
|
101
|
+
config=BuiltinExample(relative_path="examples/sft/qwen3/qwen3-4b-ultrachat-lora.yaml"),
|
|
102
|
+
nproc=1,
|
|
103
|
+
overrides=(ConfigOverride(key="report_to", value="none"),),
|
|
104
|
+
)
|
|
105
|
+
)
|
|
106
|
+
|
|
107
|
+
# Or stage a typed inline YAML config and launch detached
|
|
108
|
+
job = client.sft(
|
|
109
|
+
config=InlineConfig(
|
|
110
|
+
model_name_or_path="Qwen/Qwen3-4B-Instruct-2507",
|
|
111
|
+
output_dir=Path("./checkpoints/my-sft"),
|
|
112
|
+
dataset=("HuggingFaceH4/ultrachat_200k@train_sft",),
|
|
113
|
+
extra=(
|
|
114
|
+
ConfigEntry(key="use_peft", value=True),
|
|
115
|
+
ConfigEntry(key="report_to", value="none"),
|
|
116
|
+
),
|
|
117
|
+
),
|
|
118
|
+
nproc=4,
|
|
119
|
+
detach=True,
|
|
120
|
+
container=ContainerOptions(name="qwen3-sft"),
|
|
121
|
+
)
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
## Agent-Native Interface
|
|
125
|
+
|
|
126
|
+
- **Structured JSON responses (`msgspec.json`):** Pass `--format json` (or pipe stdout—JSON mode activates automatically on non-TTY stdout). All human progress goes to `stderr`; machine output goes strictly to `stdout`.
|
|
127
|
+
- **Self-describing schemas:** `whitehalo schema all` emits JSON Schema for every request, response, and error struct.
|
|
128
|
+
- **Structured request input:** Every command accepts `--request-json <json-or-@file>` validated strictly by `msgspec`.
|
|
129
|
+
- **Deterministic exit codes:** `0` OK, `1` runtime failure, `2` usage/validation error, `10` Docker missing, `11` Docker daemon stopped, `12` Docker permission denied, `13` GPU unavailable, `14` ambiguous GPU architecture, `15` image not pulled, `16` scratch volume missing, `17` rollout server unreachable.
|
|
130
|
+
|
|
131
|
+
## License
|
|
132
|
+
|
|
133
|
+
Released under the **Halo License** (`LicenseRef-Halo`: Apache 2.0 + Supplemental Terms in `LICENSE`).
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
# whitehalo
|
|
2
|
+
|
|
3
|
+
Lightweight, zero-torch launcher and agent-native Python SDK for [Halo](https://github.com/whitecircle/halo).
|
|
4
|
+
|
|
5
|
+
`whitehalo` does **not** install or compile PyTorch, Flash Attention, DeepEP, DeepGEMM, or CUDA kernels on your host. Instead, it manages and launches prebuilt Halo Docker images (`public.ecr.aws/whitecircle/halo`) from the host—and automatically dispatches directly to the local Halo runtime when executed inside a Halo container.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
Requires Python 3.12+ (runs cleanly on your host and natively inside Halo Docker containers).
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
pip install whitehalo
|
|
13
|
+
# or
|
|
14
|
+
uvx whitehalo doctor
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Quickstart (CLI)
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
# 1. Check Docker daemon, NVIDIA runtime, GPU architecture, local images, and scratch disk
|
|
21
|
+
whitehalo doctor
|
|
22
|
+
|
|
23
|
+
# 2. Pull the matching prebuilt Blackwell or Hopper Docker image (no AWS login required)
|
|
24
|
+
whitehalo setup
|
|
25
|
+
# Include vLLM or SGLang rollout server images for online / environmental GRPO:
|
|
26
|
+
whitehalo setup --with-vllm
|
|
27
|
+
|
|
28
|
+
# 3. Preview the exact launch command without side effects
|
|
29
|
+
whitehalo launch sft examples/sft/qwen3/qwen3-4b-ultrachat-lora.yaml --dry-run
|
|
30
|
+
|
|
31
|
+
# 4. Launch training (works with zero repo clone, or bind-mounts your local Halo checkout)
|
|
32
|
+
whitehalo launch sft examples/sft/qwen3/qwen3-4b-ultrachat-lora.yaml -n 1 -- --report_to=none
|
|
33
|
+
|
|
34
|
+
# 5. Run a Halo post-training / data / White Circle tool
|
|
35
|
+
whitehalo run create-whitecircle-policies -- --environment-id <env_id> --policies policies.json
|
|
36
|
+
|
|
37
|
+
# 6. Drop into an interactive Halo shell with all mounts, ulimits, and GPU flags configured
|
|
38
|
+
whitehalo shell
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Quickstart (Python SDK)
|
|
42
|
+
|
|
43
|
+
Every request and response type is a strictly typed frozen `msgspec.Struct` or `StrEnum`.
|
|
44
|
+
|
|
45
|
+
```python
|
|
46
|
+
from pathlib import Path
|
|
47
|
+
from whitehalo import (
|
|
48
|
+
BuiltinExample,
|
|
49
|
+
ConfigEntry,
|
|
50
|
+
ConfigOverride,
|
|
51
|
+
ContainerOptions,
|
|
52
|
+
GpuArch,
|
|
53
|
+
HaloClient,
|
|
54
|
+
ImageRole,
|
|
55
|
+
InlineConfig,
|
|
56
|
+
LaunchRequest,
|
|
57
|
+
SetupRequest,
|
|
58
|
+
TrainingMethod,
|
|
59
|
+
)
|
|
60
|
+
|
|
61
|
+
with HaloClient() as client:
|
|
62
|
+
# Pull the GPU-matched Halo image
|
|
63
|
+
client.setup(SetupRequest(arch=GpuArch.AUTO, roles=(ImageRole.TRAINER,)))
|
|
64
|
+
|
|
65
|
+
# Verify Docker/Podman, GPU runtime, image, and scratch space
|
|
66
|
+
report = client.doctor()
|
|
67
|
+
report.raise_for_errors()
|
|
68
|
+
|
|
69
|
+
# Launch a built-in example with typed overrides (zero repo clone required)
|
|
70
|
+
result = client.launch(
|
|
71
|
+
LaunchRequest(
|
|
72
|
+
method=TrainingMethod.SFT,
|
|
73
|
+
config=BuiltinExample(relative_path="examples/sft/qwen3/qwen3-4b-ultrachat-lora.yaml"),
|
|
74
|
+
nproc=1,
|
|
75
|
+
overrides=(ConfigOverride(key="report_to", value="none"),),
|
|
76
|
+
)
|
|
77
|
+
)
|
|
78
|
+
|
|
79
|
+
# Or stage a typed inline YAML config and launch detached
|
|
80
|
+
job = client.sft(
|
|
81
|
+
config=InlineConfig(
|
|
82
|
+
model_name_or_path="Qwen/Qwen3-4B-Instruct-2507",
|
|
83
|
+
output_dir=Path("./checkpoints/my-sft"),
|
|
84
|
+
dataset=("HuggingFaceH4/ultrachat_200k@train_sft",),
|
|
85
|
+
extra=(
|
|
86
|
+
ConfigEntry(key="use_peft", value=True),
|
|
87
|
+
ConfigEntry(key="report_to", value="none"),
|
|
88
|
+
),
|
|
89
|
+
),
|
|
90
|
+
nproc=4,
|
|
91
|
+
detach=True,
|
|
92
|
+
container=ContainerOptions(name="qwen3-sft"),
|
|
93
|
+
)
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
## Agent-Native Interface
|
|
97
|
+
|
|
98
|
+
- **Structured JSON responses (`msgspec.json`):** Pass `--format json` (or pipe stdout—JSON mode activates automatically on non-TTY stdout). All human progress goes to `stderr`; machine output goes strictly to `stdout`.
|
|
99
|
+
- **Self-describing schemas:** `whitehalo schema all` emits JSON Schema for every request, response, and error struct.
|
|
100
|
+
- **Structured request input:** Every command accepts `--request-json <json-or-@file>` validated strictly by `msgspec`.
|
|
101
|
+
- **Deterministic exit codes:** `0` OK, `1` runtime failure, `2` usage/validation error, `10` Docker missing, `11` Docker daemon stopped, `12` Docker permission denied, `13` GPU unavailable, `14` ambiguous GPU architecture, `15` image not pulled, `16` scratch volume missing, `17` rollout server unreachable.
|
|
102
|
+
|
|
103
|
+
## License
|
|
104
|
+
|
|
105
|
+
Released under the **Halo License** (`LicenseRef-Halo`: Apache 2.0 + Supplemental Terms in `LICENSE`).
|