@tuned-tensor/cli 0.4.24 → 0.5.0
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.
- package/LICENSE +161 -21
- package/README.md +101 -11
- package/dist/index.js +2346 -318
- package/dist/index.js.map +1 -1
- package/package.json +7 -3
package/LICENSE
CHANGED
|
@@ -1,21 +1,161 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
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, and
|
|
10
|
+
distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by the
|
|
13
|
+
copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all other
|
|
16
|
+
entities that control, are controlled by, or are under common control with
|
|
17
|
+
that entity. For the purposes of this definition, "control" means (i) the
|
|
18
|
+
power, direct or indirect, to cause the direction or management of such
|
|
19
|
+
entity, whether by contract or otherwise, or (ii) ownership of fifty percent
|
|
20
|
+
(50%) or more of the outstanding shares, or (iii) beneficial ownership of
|
|
21
|
+
such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity exercising
|
|
24
|
+
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 source, and
|
|
28
|
+
configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical transformation or
|
|
31
|
+
translation of a Source form, including but not limited to compiled object
|
|
32
|
+
code, generated documentation, and conversions to other media types.
|
|
33
|
+
|
|
34
|
+
"Work" shall mean the work of authorship, whether in Source or Object form,
|
|
35
|
+
made available under the License, as indicated by a copyright notice that is
|
|
36
|
+
included in or attached to the work.
|
|
37
|
+
|
|
38
|
+
"Derivative Works" shall mean any work, whether in Source or Object form,
|
|
39
|
+
that is based on (or derived from) the Work and for which the editorial
|
|
40
|
+
revisions, annotations, elaborations, or other modifications represent, as a
|
|
41
|
+
whole, an original work of authorship. For the purposes of this License,
|
|
42
|
+
Derivative Works shall not include works that remain separable from, or
|
|
43
|
+
merely link (or bind by name) to the interfaces of, the Work and Derivative
|
|
44
|
+
Works thereof.
|
|
45
|
+
|
|
46
|
+
"Contribution" shall mean any work of authorship, including the original
|
|
47
|
+
version of the Work and any modifications or additions to that Work or
|
|
48
|
+
Derivative Works thereof, that is intentionally submitted to Licensor for
|
|
49
|
+
inclusion in the Work by the copyright owner or by an individual or Legal
|
|
50
|
+
Entity authorized to submit on behalf of the copyright owner. For the purposes
|
|
51
|
+
of this definition, "submitted" means any form of electronic, verbal, or
|
|
52
|
+
written communication sent to the Licensor or its representatives, including
|
|
53
|
+
but not limited to communication on electronic mailing lists, source code
|
|
54
|
+
control systems, and issue tracking systems that are managed by, or on behalf
|
|
55
|
+
of, the Licensor for the purpose of discussing and improving the Work, but
|
|
56
|
+
excluding communication that is conspicuously marked or otherwise designated
|
|
57
|
+
in writing by the copyright owner as "Not a Contribution."
|
|
58
|
+
|
|
59
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity on
|
|
60
|
+
behalf of whom a Contribution has been received by Licensor and subsequently
|
|
61
|
+
incorporated within the Work.
|
|
62
|
+
|
|
63
|
+
2. Grant of Copyright License. Subject to the terms and conditions of this
|
|
64
|
+
License, each Contributor hereby grants to You a perpetual, worldwide,
|
|
65
|
+
non-exclusive, no-charge, royalty-free, irrevocable copyright license to
|
|
66
|
+
reproduce, prepare Derivative Works of, publicly display, publicly perform,
|
|
67
|
+
sublicense, and distribute the Work and such Derivative Works in Source or
|
|
68
|
+
Object form.
|
|
69
|
+
|
|
70
|
+
3. Grant of Patent License. Subject to the terms and conditions of this
|
|
71
|
+
License, each Contributor hereby grants to You a perpetual, worldwide,
|
|
72
|
+
non-exclusive, no-charge, royalty-free, irrevocable patent license to make,
|
|
73
|
+
have made, use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
74
|
+
where such license applies only to those patent claims licensable by such
|
|
75
|
+
Contributor that are necessarily infringed by their Contribution alone or by
|
|
76
|
+
combination of their Contribution with the Work to which such Contribution
|
|
77
|
+
was submitted. If You institute patent litigation against any entity
|
|
78
|
+
(including a cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
79
|
+
or a Contribution incorporated within the Work constitutes direct or
|
|
80
|
+
contributory patent infringement, then any patent licenses granted to You
|
|
81
|
+
under this License for that Work shall terminate as of the date such
|
|
82
|
+
litigation is filed.
|
|
83
|
+
|
|
84
|
+
4. Redistribution. You may reproduce and distribute copies of the Work or
|
|
85
|
+
Derivative Works thereof in any medium, with or without modifications, and in
|
|
86
|
+
Source or Object form, provided that You meet the following conditions:
|
|
87
|
+
|
|
88
|
+
(a) You must give any other recipients of the Work or Derivative Works a copy
|
|
89
|
+
of this License; and
|
|
90
|
+
|
|
91
|
+
(b) You must cause any modified files to carry prominent notices stating that
|
|
92
|
+
You changed the files; and
|
|
93
|
+
|
|
94
|
+
(c) You must retain, in the Source form of any Derivative Works that You
|
|
95
|
+
distribute, all copyright, patent, trademark, and attribution notices from the
|
|
96
|
+
Source form of the Work, excluding those notices that do not pertain to any
|
|
97
|
+
part of the Derivative Works; and
|
|
98
|
+
|
|
99
|
+
(d) If the Work includes a "NOTICE" text file as part of its distribution,
|
|
100
|
+
then any Derivative Works that You distribute must include a readable copy of
|
|
101
|
+
the attribution notices contained within such NOTICE file, excluding those
|
|
102
|
+
notices that do not pertain to any part of the Derivative Works, in at least
|
|
103
|
+
one of the following places: within a NOTICE text file distributed as part of
|
|
104
|
+
the Derivative Works; within the Source form or documentation, if provided
|
|
105
|
+
along with the Derivative Works; or, within a display generated by the
|
|
106
|
+
Derivative Works, if and wherever such third-party notices normally appear.
|
|
107
|
+
The contents of the NOTICE file are for informational purposes only and do
|
|
108
|
+
not modify the License. You may add Your own attribution notices within
|
|
109
|
+
Derivative Works that You distribute, alongside or as an addendum to the
|
|
110
|
+
NOTICE text from the Work, provided that such additional attribution notices
|
|
111
|
+
cannot be construed as modifying the License.
|
|
112
|
+
|
|
113
|
+
You may add Your own copyright statement to Your modifications and may provide
|
|
114
|
+
additional or different license terms and conditions for use, reproduction, or
|
|
115
|
+
distribution of Your modifications, or for any such Derivative Works as a
|
|
116
|
+
whole, provided Your use, reproduction, and distribution of the Work otherwise
|
|
117
|
+
complies with the conditions stated in this License.
|
|
118
|
+
|
|
119
|
+
5. Submission of Contributions. Unless You explicitly state otherwise, any
|
|
120
|
+
Contribution intentionally submitted for inclusion in the Work by You to the
|
|
121
|
+
Licensor shall be under the terms and conditions of this License, without any
|
|
122
|
+
additional terms or conditions. Notwithstanding the above, nothing herein
|
|
123
|
+
shall supersede or modify the terms of any separate license agreement you may
|
|
124
|
+
have executed with Licensor regarding such Contributions.
|
|
125
|
+
|
|
126
|
+
6. Trademarks. This License does not grant permission to use the trade names,
|
|
127
|
+
trademarks, service marks, or product names of the Licensor, except as
|
|
128
|
+
required for reasonable and customary use in describing the origin of the Work
|
|
129
|
+
and reproducing the content of the NOTICE file.
|
|
130
|
+
|
|
131
|
+
7. Disclaimer of Warranty. Unless required by applicable law or agreed to in
|
|
132
|
+
writing, Licensor provides the Work on an "AS IS" BASIS, WITHOUT WARRANTIES OR
|
|
133
|
+
CONDITIONS OF ANY KIND, either express or implied, including, without
|
|
134
|
+
limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT,
|
|
135
|
+
MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely
|
|
136
|
+
responsible for determining the appropriateness of using or redistributing
|
|
137
|
+
the Work and assume any risks associated with Your exercise of permissions
|
|
138
|
+
under this License.
|
|
139
|
+
|
|
140
|
+
8. Limitation of Liability. In no event and under no legal theory, whether in
|
|
141
|
+
tort (including negligence), contract, or otherwise, unless required by
|
|
142
|
+
applicable law (such as deliberate and grossly negligent acts) or agreed to in
|
|
143
|
+
writing, shall any Contributor be liable to You for damages, including any
|
|
144
|
+
direct, indirect, special, incidental, or consequential damages of any
|
|
145
|
+
character arising as a result of this License or out of the use or inability
|
|
146
|
+
to use the Work, including but not limited to damages for loss of goodwill,
|
|
147
|
+
work stoppage, computer failure or malfunction, or any and all other
|
|
148
|
+
commercial damages or losses, even if such Contributor has been advised of
|
|
149
|
+
the possibility of such damages.
|
|
150
|
+
|
|
151
|
+
9. Accepting Warranty or Additional Liability. While redistributing the Work
|
|
152
|
+
or Derivative Works thereof, You may choose to offer, and charge a fee for,
|
|
153
|
+
acceptance of support, warranty, indemnity, or other liability obligations
|
|
154
|
+
and/or rights consistent with this License. However, in accepting such
|
|
155
|
+
obligations, You may act only on Your own behalf and on Your sole
|
|
156
|
+
responsibility, not on behalf of any other Contributor, and only if You agree
|
|
157
|
+
to indemnify, defend, and hold each Contributor harmless for any liability
|
|
158
|
+
incurred by, or claims asserted against, such Contributor by reason of your
|
|
159
|
+
accepting any such warranty or additional liability.
|
|
160
|
+
|
|
161
|
+
END OF TERMS AND CONDITIONS
|
package/README.md
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
# tt - Tuned Tensor CLI
|
|
2
2
|
|
|
3
|
-
`tt` is
|
|
4
|
-
[Tuned Tensor](https://www.tunedtensor.com) service. Use it to define behaviour
|
|
5
|
-
specs, launch managed fine-tuning runs, inspect paired baseline-vs-tuned
|
|
6
|
-
reports, and download or serve trained models. For local CUDA or DGX Spark
|
|
7
|
-
training without a Tuned Tensor account, use `tt-local` from
|
|
8
|
-
`@tuned-tensor/local`.
|
|
3
|
+
`tt` is one terminal for the complete Tuned Tensor workflow:
|
|
9
4
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
5
|
+
- hosted specs, datasets, labeling, training, reports, and model downloads;
|
|
6
|
+
- local CUDA fine-tuning, held-out evaluation, artifact verification, model
|
|
7
|
+
activation, and OpenAI-compatible serving.
|
|
8
|
+
|
|
9
|
+
Existing commands such as `tt runs`, `tt models`, and `tt push` remain hosted
|
|
10
|
+
commands. The local workflow lives under `tt local`, so scripts keep their
|
|
11
|
+
current meaning while people can switch between both targets in one
|
|
12
|
+
interactive shell.
|
|
13
13
|
|
|
14
14
|
## Install
|
|
15
15
|
|
|
@@ -18,6 +18,11 @@ npm install -g @tuned-tensor/cli
|
|
|
18
18
|
tt --version
|
|
19
19
|
```
|
|
20
20
|
|
|
21
|
+
Node.js 22 or newer is required. Hosted commands need no local ML runtime.
|
|
22
|
+
Local training additionally needs
|
|
23
|
+
[`uv`](https://docs.astral.sh/uv/) and a supported NVIDIA CUDA host; the locked
|
|
24
|
+
Python runner ships with the npm dependency and is prepared on first use.
|
|
25
|
+
|
|
21
26
|
Run from source:
|
|
22
27
|
|
|
23
28
|
```bash
|
|
@@ -28,7 +33,28 @@ npm run build
|
|
|
28
33
|
npm link
|
|
29
34
|
```
|
|
30
35
|
|
|
31
|
-
##
|
|
36
|
+
## Terminal shell
|
|
37
|
+
|
|
38
|
+
Run `tt` in an interactive terminal to open the Tuned Tensor shell:
|
|
39
|
+
|
|
40
|
+
```text
|
|
41
|
+
tt cloud support-agent › auth status
|
|
42
|
+
tt cloud support-agent › /mode local
|
|
43
|
+
tt local support-agent › doctor
|
|
44
|
+
tt local support-agent › run --dry-run
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Commands are routed to the mode shown in the prompt. Prefix a single command
|
|
48
|
+
with `cloud` or `local` to override the mode without switching it. Useful
|
|
49
|
+
session commands include `/help`, `/status`, `/context`, `/mode`, `/cd`,
|
|
50
|
+
`/clear`, and `/exit`. The shell keeps normal terminal scrollback and command
|
|
51
|
+
history only for the current process.
|
|
52
|
+
|
|
53
|
+
Explicit commands remain non-interactive, including in CI. `tt --help` shows
|
|
54
|
+
the complete command surface, `tt status` inspects both targets without a
|
|
55
|
+
network or GPU probe, and `tt shell` opens the shell explicitly.
|
|
56
|
+
|
|
57
|
+
## Hosted quick start
|
|
32
58
|
|
|
33
59
|
```bash
|
|
34
60
|
tt auth login
|
|
@@ -43,6 +69,70 @@ tt runs watch <run-id>
|
|
|
43
69
|
tt runs report <run-id>
|
|
44
70
|
```
|
|
45
71
|
|
|
72
|
+
The hosted service remains optional. Before a paid run, inspect the estimate:
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
tt balance
|
|
76
|
+
tt runs estimate <spec-id>
|
|
77
|
+
tt runs start <spec-id>
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
## Local quick start
|
|
81
|
+
|
|
82
|
+
Create a local project on an NVIDIA host:
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
mkdir support-adapter && cd support-adapter
|
|
86
|
+
tt local init \
|
|
87
|
+
--name "Support Adapter" \
|
|
88
|
+
--model Qwen/Qwen3.5-2B \
|
|
89
|
+
--profile spark
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Edit the generated `tunedtensor.json`, replacing both placeholder examples,
|
|
93
|
+
then preflight and run:
|
|
94
|
+
|
|
95
|
+
```bash
|
|
96
|
+
tt local doctor tunedtensor.json
|
|
97
|
+
tt local validate tunedtensor.json
|
|
98
|
+
tt local models prefetch tunedtensor.json
|
|
99
|
+
tt local run tunedtensor.json
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
Inspect, verify, and serve a completed adapter:
|
|
103
|
+
|
|
104
|
+
```bash
|
|
105
|
+
tt local runs report <run-id>
|
|
106
|
+
tt local models verify local-<run-id>
|
|
107
|
+
tt local models serve local-<run-id> --config local-runner.json
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
Local currently certifies text SFT with `Qwen/Qwen3.5-2B`, LoRA/PEFT, and CUDA.
|
|
111
|
+
Evaluation and serving may use CPU. Training artifacts, datasets, and model
|
|
112
|
+
weights remain on the execution host.
|
|
113
|
+
|
|
114
|
+
Activation is optional and requires the run to pass a configured
|
|
115
|
+
`generalRegression` gate. Once activated, use
|
|
116
|
+
`tt local serve active --config local-runner.json`.
|
|
117
|
+
|
|
118
|
+
### One project file, target-specific payloads
|
|
119
|
+
|
|
120
|
+
Both workflows use `tunedtensor.json`, but their supported fields are not
|
|
121
|
+
identical. `tt` keeps the source file intact and projects only fields accepted
|
|
122
|
+
by the selected target:
|
|
123
|
+
|
|
124
|
+
- hosted pushes omit local-only `hyperparameters` and `dataset_prebuilt`;
|
|
125
|
+
- local run, validation, prefetch, and explicit `--spec` serving commands omit
|
|
126
|
+
cloud-only executable `eval_cases`;
|
|
127
|
+
- the default hosted scaffold contains two distinct examples and is valid as
|
|
128
|
+
a starting point for local held-out evaluation.
|
|
129
|
+
|
|
130
|
+
Target validation is still authoritative. In particular, choosing a hosted
|
|
131
|
+
base model does not make that model supported by the local CUDA runner.
|
|
132
|
+
`tt local serve base` does not automatically inject the adjacent project spec.
|
|
133
|
+
Pass `--spec tunedtensor.json` when the server should enforce its instructions;
|
|
134
|
+
that explicit spec is projected for the local runtime.
|
|
135
|
+
|
|
46
136
|
To continue training from a completed fine-tuned model artifact:
|
|
47
137
|
|
|
48
138
|
```bash
|
|
@@ -112,4 +202,4 @@ npm test
|
|
|
112
202
|
|
|
113
203
|
## License
|
|
114
204
|
|
|
115
|
-
|
|
205
|
+
Apache-2.0
|