wafer-cli 0.2.14__py3-none-any.whl → 0.2.30__py3-none-any.whl
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.
- wafer/GUIDE.md +1 -1
- wafer/agent_defaults.py +42 -0
- wafer/auth.py +7 -0
- wafer/billing.py +6 -6
- wafer/cli.py +905 -131
- wafer/cli_instructions.py +143 -0
- wafer/corpus.py +313 -15
- wafer/evaluate.py +480 -146
- wafer/global_config.py +13 -0
- wafer/kernel_scope.py +1 -1
- wafer/ncu_analyze.py +1 -1
- wafer/nsys_analyze.py +1 -1
- wafer/skills/wafer-guide/SKILL.md +22 -6
- wafer/specs_cli.py +157 -0
- wafer/ssh_keys.py +6 -6
- wafer/targets_cli.py +472 -0
- wafer/targets_ops.py +29 -2
- wafer/templates/ask_docs.py +1 -1
- wafer/templates/optimize_kernel.py +3 -1
- wafer/templates/optimize_kernelbench.py +17 -62
- wafer/templates/trace_analyze.py +1 -1
- wafer/tests/test_eval_cli_parity.py +199 -0
- wafer/trace_compare.py +274 -0
- wafer/wevin_cli.py +125 -26
- wafer/workspaces.py +163 -16
- wafer_cli-0.2.30.dist-info/METADATA +107 -0
- wafer_cli-0.2.30.dist-info/RECORD +47 -0
- wafer_cli-0.2.14.dist-info/METADATA +0 -16
- wafer_cli-0.2.14.dist-info/RECORD +0 -41
- {wafer_cli-0.2.14.dist-info → wafer_cli-0.2.30.dist-info}/WHEEL +0 -0
- {wafer_cli-0.2.14.dist-info → wafer_cli-0.2.30.dist-info}/entry_points.txt +0 -0
- {wafer_cli-0.2.14.dist-info → wafer_cli-0.2.30.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: wafer-cli
|
|
3
|
+
Version: 0.2.30
|
|
4
|
+
Summary: CLI for running GPU workloads, managing remote workspaces, and evaluating/optimizing kernels
|
|
5
|
+
Requires-Python: >=3.11
|
|
6
|
+
Description-Content-Type: text/markdown
|
|
7
|
+
Requires-Dist: typer>=0.12.0
|
|
8
|
+
Requires-Dist: trio>=0.24.0
|
|
9
|
+
Requires-Dist: trio-asyncio>=0.15.0
|
|
10
|
+
Requires-Dist: wafer-core>=0.1.0
|
|
11
|
+
Requires-Dist: perfetto>=0.16.0
|
|
12
|
+
Requires-Dist: posthog>=3.0.0
|
|
13
|
+
Provides-Extra: dev
|
|
14
|
+
Requires-Dist: pytest>=8.0.0; extra == "dev"
|
|
15
|
+
Requires-Dist: pytest-cov>=4.1.0; extra == "dev"
|
|
16
|
+
Requires-Dist: diff-cover>=8.0.0; extra == "dev"
|
|
17
|
+
Requires-Dist: ruff>=0.4.0; extra == "dev"
|
|
18
|
+
|
|
19
|
+
# Wafer CLI
|
|
20
|
+
|
|
21
|
+
Wafer CLI gives coding agents direct access to GPU docs, trace analysis, and remote kernel evaluation.
|
|
22
|
+
It helps you develop and optimize GPU kernels even when you are not working on a machine with a GPU.
|
|
23
|
+
|
|
24
|
+
## Key features
|
|
25
|
+
|
|
26
|
+
- Query GPU documentation with citations
|
|
27
|
+
- Analyze GPU traces and profiles
|
|
28
|
+
- Evaluate kernels on remote GPUs for correctness and performance
|
|
29
|
+
- Run commands on GPU targets (remote or local)
|
|
30
|
+
- Manage persistent workspaces
|
|
31
|
+
|
|
32
|
+
## Quick start
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
uv tool install wafer-cli
|
|
36
|
+
wafer login
|
|
37
|
+
wafer remote-run -- nvidia-smi
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Common commands
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
wafer workspaces list
|
|
44
|
+
wafer workspaces create my-workspace --wait
|
|
45
|
+
wafer agent -t ask-docs --corpus cuda "What causes shared memory bank conflicts?"
|
|
46
|
+
wafer agent -t trace-analyze --args trace=./profile.ncu-rep "Why is this kernel slow?"
|
|
47
|
+
wafer evaluate --impl kernel.py --reference ref.py --test-cases tests.json --benchmark
|
|
48
|
+
wafer nvidia ncu analyze profile.ncu-rep
|
|
49
|
+
wafer corpus list
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
## Typical workflows
|
|
53
|
+
|
|
54
|
+
### Query GPU documentation
|
|
55
|
+
|
|
56
|
+
Download a documentation corpus and ask questions with citations.
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
wafer corpus download cuda
|
|
60
|
+
wafer agent -t ask-docs --corpus cuda "What causes shared memory bank conflicts?"
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### Analyze performance traces
|
|
64
|
+
|
|
65
|
+
Use the trace analysis template or query trace data directly.
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
wafer agent -t trace-analyze --args trace=./profile.ncu-rep "Why is this kernel slow?"
|
|
69
|
+
wafer nvidia perfetto query trace.json \
|
|
70
|
+
"SELECT name, dur/1e6 as ms FROM slice WHERE cat='kernel' ORDER BY dur DESC LIMIT 10"
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
### Evaluate kernels on remote GPUs
|
|
74
|
+
|
|
75
|
+
Run correctness and performance checks on a remote target.
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
wafer evaluate \
|
|
79
|
+
--impl ./kernel.py \
|
|
80
|
+
--reference ./reference.py \
|
|
81
|
+
--test-cases ./tests.json \
|
|
82
|
+
--benchmark
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
### Run commands on a remote GPU
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
wafer remote-run -- nvidia-smi
|
|
89
|
+
wafer remote-run --upload-dir ./my_code -- python3 train.py
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
### Manage workspaces
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
wafer workspaces list
|
|
96
|
+
wafer workspaces create my-workspace --wait
|
|
97
|
+
wafer workspaces ssh <workspace-id>
|
|
98
|
+
wafer workspaces delete <workspace-id>
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
## Install the CLI skill (optional)
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
wafer skill install
|
|
105
|
+
# or
|
|
106
|
+
wafer skill install -t <claude/codex>
|
|
107
|
+
```
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
wafer/GUIDE.md,sha256=aZMNTNHhSc5dmRskUnpgcGlHYgsbf5S6Q_Thn0xmN1A,3588
|
|
2
|
+
wafer/__init__.py,sha256=kBM_ONCpU6UUMBOH8Tmg4A88sNFnbaD59o61cJs-uYM,90
|
|
3
|
+
wafer/agent_defaults.py,sha256=qpJvVyY7jw2EqQo_IZ4M4aR2-kKNomyTmoOOah1FW6I,1179
|
|
4
|
+
wafer/analytics.py,sha256=qLY6Z16usVHFD8TCv7XBuz7l47vXVdXk-qhOzA-hW_8,8179
|
|
5
|
+
wafer/api_client.py,sha256=i_Az2b2llC3DSW8yOL-BKqa7LSKuxOr8hSN40s-oQXY,6313
|
|
6
|
+
wafer/auth.py,sha256=dwss_se5P-FFc9IN38q4kh_dBrA6k-CguDBkivgcdj0,14003
|
|
7
|
+
wafer/autotuner.py,sha256=41WYP41pTDvMijv2h42vm89bcHtDMJXObDlWmn6xpFU,44416
|
|
8
|
+
wafer/billing.py,sha256=hEEwtrtIsbPQ3lLJNcyTLMsapUbcuvcVW_e9_0SxzVo,7199
|
|
9
|
+
wafer/cli.py,sha256=zuVZhPdML5AOBtLUqLwAwjl8XMNe9EwQkffZxtBGLx4,282748
|
|
10
|
+
wafer/cli_instructions.py,sha256=bziUKDNDAXABVMvKPLEMXm-hFSD2TcFSh-FKRYa949k,4693
|
|
11
|
+
wafer/config.py,sha256=h5Eo9_yfWqWGoPNdVQikI9GoZVUeysunSYiixf1mKcw,3411
|
|
12
|
+
wafer/corpus.py,sha256=CY9T7wXENNDJxnrtI-XsQmXeptrFfKG4x-lngrc9_3s,24748
|
|
13
|
+
wafer/evaluate.py,sha256=QswzCD0CZRT2jpzpeekjNezEPbKHZnvVI7KRQZas8LA,186310
|
|
14
|
+
wafer/global_config.py,sha256=iu1HbTDr1695tSeDG2NfkK7PiY7XD6vjCk37w1wHbgk,11920
|
|
15
|
+
wafer/gpu_run.py,sha256=TwqXy72T7f2I7e6n5WWod3xgxCPnDhU0BgLsB4CUoQY,9716
|
|
16
|
+
wafer/inference.py,sha256=tZCO5i05FKY27ewis3CSBHFBeFbXY3xwj0DSjdoMY9s,4314
|
|
17
|
+
wafer/kernel_scope.py,sha256=hKCwCIVZWl5xFdoA5G9kPucdG9O0jw9Zgyso-mc6aZo,20801
|
|
18
|
+
wafer/ncu_analyze.py,sha256=f7yJayhmEjXn18g6MpxtQoN5_WW_kq4Qyxa1hd0tC74,24638
|
|
19
|
+
wafer/nsys_analyze.py,sha256=4BV6vSTZy7jLzeAxdKJp6QceYy6t9SWGSnjDV8RqkcI,36129
|
|
20
|
+
wafer/nsys_profile.py,sha256=QFBl8pkr8r4uRNdNUO9gY-obj9slqpOgVYFZ_sXu6Nw,15478
|
|
21
|
+
wafer/output.py,sha256=8jw5ifvIMK8ldyBMGW4NhrKvJPl66TV2Y2fJ5Tlhh1I,8293
|
|
22
|
+
wafer/problems.py,sha256=ce2sy10A1nnNUG3VGsseTS8jL7LZsku4dE8zVf9JHQ4,11296
|
|
23
|
+
wafer/rocprof_compute.py,sha256=n_yOGZaFbOXna_ghhmYWXeyUoSabgH4KkjlYq38DlHo,19888
|
|
24
|
+
wafer/rocprof_sdk.py,sha256=0Q7Ye6dUfa1anFZbqKc21rItgqva8V8VIZoSB7wqbmA,10085
|
|
25
|
+
wafer/rocprof_systems.py,sha256=4IWbMcbYk1x_8iS7P3FC_u5sgH6EXADCtR2lV9id80M,18629
|
|
26
|
+
wafer/specs_cli.py,sha256=frMEKwMflxVNpFlAuxprmr33ZZ1Oeh2lB0KWZ4oZWzw,4360
|
|
27
|
+
wafer/ssh_keys.py,sha256=MxiHlSm6wuDUFzkOQtx5K7OIbx_a6bXxE-m8OpwLx98,8130
|
|
28
|
+
wafer/target_lock.py,sha256=SDKhNzv2N7gsphGflcNni9FE5YYuAMuEthngAJEo4Gs,7809
|
|
29
|
+
wafer/targets.py,sha256=9r-iRWoKSH5cQl1LcamaX-T7cNVOg99ngIm_hlRk-qU,26922
|
|
30
|
+
wafer/targets_cli.py,sha256=Oe3e02rSXeNrMbe_Qv9DNfQ8dEOKodtU7BbQQWxlNwA,16348
|
|
31
|
+
wafer/targets_ops.py,sha256=wLPyq55H_wz0wEAEg8KFLYs9LIIyiVIphcsXD2NLa-E,22623
|
|
32
|
+
wafer/trace_compare.py,sha256=COuxxKY874DteOSLUvJuJFREPMBSybq9dtANi3ATsg4,10803
|
|
33
|
+
wafer/tracelens.py,sha256=g9ZIeFyNojZn4uTd3skPqIrRiL7aMJOz_-GOd3aiyy4,7998
|
|
34
|
+
wafer/wevin_cli.py,sha256=eo1ETsXIsCftXSG5AxEYYZipNGcXayKyIevs5F6MjXg,26140
|
|
35
|
+
wafer/workspaces.py,sha256=J-TXGwHXSZlzRWCew63KNvk6HLJ-zTSELRgzjryTkMk,35710
|
|
36
|
+
wafer/skills/wafer-guide/SKILL.md,sha256=UDsXCD5Kb-lDParKCTf2WkE3kodVs-rja8XeumSBO5U,3934
|
|
37
|
+
wafer/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
38
|
+
wafer/templates/ask_docs.py,sha256=15t1Aa4WBMwMox8XmFdzyosOZfBLMdXyaxo3GDb7nTE,2254
|
|
39
|
+
wafer/templates/optimize_kernel.py,sha256=4-MaKm_C9BQHQEllrNLLYkcdhJpcj6D-8zbJ4FdLUEY,2444
|
|
40
|
+
wafer/templates/optimize_kernelbench.py,sha256=T3co9Y9eSLWDrZG66gwQVFMdnGVoyUQos-TxnMMBLL8,3747
|
|
41
|
+
wafer/templates/trace_analyze.py,sha256=B7CiRlsokERzBjLL-k49kGjpU2zlJZqzTE05xbRS1WI,2878
|
|
42
|
+
wafer/tests/test_eval_cli_parity.py,sha256=SGmaj2NGBZ7GdDF53bXsECvQbV21iHZw8YeL_MJOLk0,7206
|
|
43
|
+
wafer_cli-0.2.30.dist-info/METADATA,sha256=4mvnQyUVD_irJIdhwj0ECm5FEDVXlcmFjklLzZqq1V8,2799
|
|
44
|
+
wafer_cli-0.2.30.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
|
|
45
|
+
wafer_cli-0.2.30.dist-info/entry_points.txt,sha256=WqB7hB__WhtPY8y1cO2sZiUz7fCq6Ik-usAigpeFvWE,41
|
|
46
|
+
wafer_cli-0.2.30.dist-info/top_level.txt,sha256=2MK1IVMWfpLL8BZCQ3E9aG6L6L666gSA_teYlwan4fs,6
|
|
47
|
+
wafer_cli-0.2.30.dist-info/RECORD,,
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.4
|
|
2
|
-
Name: wafer-cli
|
|
3
|
-
Version: 0.2.14
|
|
4
|
-
Summary: CLI tool for running commands on remote GPUs and GPU kernel optimization agent
|
|
5
|
-
Requires-Python: >=3.11
|
|
6
|
-
Requires-Dist: typer>=0.12.0
|
|
7
|
-
Requires-Dist: trio>=0.24.0
|
|
8
|
-
Requires-Dist: trio-asyncio>=0.15.0
|
|
9
|
-
Requires-Dist: wafer-core>=0.1.0
|
|
10
|
-
Requires-Dist: perfetto>=0.16.0
|
|
11
|
-
Requires-Dist: posthog>=3.0.0
|
|
12
|
-
Provides-Extra: dev
|
|
13
|
-
Requires-Dist: pytest>=8.0.0; extra == "dev"
|
|
14
|
-
Requires-Dist: pytest-cov>=4.1.0; extra == "dev"
|
|
15
|
-
Requires-Dist: diff-cover>=8.0.0; extra == "dev"
|
|
16
|
-
Requires-Dist: ruff>=0.4.0; extra == "dev"
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
wafer/GUIDE.md,sha256=G6P4aFZslEXiHmVjtTB3_OIpGK5d1tSiqxtawASVUZg,3588
|
|
2
|
-
wafer/__init__.py,sha256=kBM_ONCpU6UUMBOH8Tmg4A88sNFnbaD59o61cJs-uYM,90
|
|
3
|
-
wafer/analytics.py,sha256=qLY6Z16usVHFD8TCv7XBuz7l47vXVdXk-qhOzA-hW_8,8179
|
|
4
|
-
wafer/api_client.py,sha256=i_Az2b2llC3DSW8yOL-BKqa7LSKuxOr8hSN40s-oQXY,6313
|
|
5
|
-
wafer/auth.py,sha256=nneKUjGwb5ggJEHRdF_GlFkT1ZozHP4kGyuXjhZjtgM,13677
|
|
6
|
-
wafer/autotuner.py,sha256=41WYP41pTDvMijv2h42vm89bcHtDMJXObDlWmn6xpFU,44416
|
|
7
|
-
wafer/billing.py,sha256=jbLB2lI4_9f2KD8uEFDi_ixLlowe5hasC0TIZJyIXRg,7163
|
|
8
|
-
wafer/cli.py,sha256=lBBTQCcmKREqZDOQh27qSq8i6NedjHW5oh1JiuT9aho,254241
|
|
9
|
-
wafer/config.py,sha256=h5Eo9_yfWqWGoPNdVQikI9GoZVUeysunSYiixf1mKcw,3411
|
|
10
|
-
wafer/corpus.py,sha256=x5aFhCsTSAtgzFG9AMFpqq92Ej63mXofL-vvvpjj1sM,12913
|
|
11
|
-
wafer/evaluate.py,sha256=bLTfL7jAGQlfqLL39hSGSB7bnBp5THTCY7nl6giVMkQ,176005
|
|
12
|
-
wafer/global_config.py,sha256=fhaR_RU3ufMksDmOohH1OLeQ0JT0SDW1hEip_zaP75k,11345
|
|
13
|
-
wafer/gpu_run.py,sha256=TwqXy72T7f2I7e6n5WWod3xgxCPnDhU0BgLsB4CUoQY,9716
|
|
14
|
-
wafer/inference.py,sha256=tZCO5i05FKY27ewis3CSBHFBeFbXY3xwj0DSjdoMY9s,4314
|
|
15
|
-
wafer/kernel_scope.py,sha256=YtnxknAChkJoeU_vIdxiqWsAITGBeabp9OGIK-X32i0,20796
|
|
16
|
-
wafer/ncu_analyze.py,sha256=rAWzKQRZEY6E_CL3gAWUaW3uZ4kvQVZskVCPDpsFJuE,24633
|
|
17
|
-
wafer/nsys_analyze.py,sha256=AhNcjPaapB0QCbqiHRXvyy-ccjevvVwEyxes84D28JU,36124
|
|
18
|
-
wafer/nsys_profile.py,sha256=QFBl8pkr8r4uRNdNUO9gY-obj9slqpOgVYFZ_sXu6Nw,15478
|
|
19
|
-
wafer/output.py,sha256=8jw5ifvIMK8ldyBMGW4NhrKvJPl66TV2Y2fJ5Tlhh1I,8293
|
|
20
|
-
wafer/problems.py,sha256=ce2sy10A1nnNUG3VGsseTS8jL7LZsku4dE8zVf9JHQ4,11296
|
|
21
|
-
wafer/rocprof_compute.py,sha256=n_yOGZaFbOXna_ghhmYWXeyUoSabgH4KkjlYq38DlHo,19888
|
|
22
|
-
wafer/rocprof_sdk.py,sha256=0Q7Ye6dUfa1anFZbqKc21rItgqva8V8VIZoSB7wqbmA,10085
|
|
23
|
-
wafer/rocprof_systems.py,sha256=4IWbMcbYk1x_8iS7P3FC_u5sgH6EXADCtR2lV9id80M,18629
|
|
24
|
-
wafer/ssh_keys.py,sha256=9kSdhV_dg9T6pQu2JmNQptarkkwGtN9rLyRkI1bW4i4,8094
|
|
25
|
-
wafer/target_lock.py,sha256=SDKhNzv2N7gsphGflcNni9FE5YYuAMuEthngAJEo4Gs,7809
|
|
26
|
-
wafer/targets.py,sha256=9r-iRWoKSH5cQl1LcamaX-T7cNVOg99ngIm_hlRk-qU,26922
|
|
27
|
-
wafer/targets_ops.py,sha256=jN1oIBx0mutxRNE9xpIc7SaBxPkVmOyus2eqn0kEKNI,21475
|
|
28
|
-
wafer/tracelens.py,sha256=g9ZIeFyNojZn4uTd3skPqIrRiL7aMJOz_-GOd3aiyy4,7998
|
|
29
|
-
wafer/wevin_cli.py,sha256=vF3GNH-qWXO4hAlXaDg98VZpS4uFexVUp94BHsJjjMU,22179
|
|
30
|
-
wafer/workspaces.py,sha256=XZvN-13oq40fkpoJTB2UWTG9KkD-eO47ptXK0FY6360,30083
|
|
31
|
-
wafer/skills/wafer-guide/SKILL.md,sha256=KWetJw2TVTbz11_nzqazqOJWWRlbHRFShs4sOoreiWo,3255
|
|
32
|
-
wafer/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
33
|
-
wafer/templates/ask_docs.py,sha256=Lxs-faz9v5m4Qa4NjF2X_lE8KwM9ES9MNJkxo7ep56o,2256
|
|
34
|
-
wafer/templates/optimize_kernel.py,sha256=u6AL7Q3uttqlnBLzcoFdsiPq5lV2TV3bgqwCYYlK9gk,2357
|
|
35
|
-
wafer/templates/optimize_kernelbench.py,sha256=aoOA13zWEl89r6QW03xF9NKxQ7j4mWe9rwua6-mlr4Y,4780
|
|
36
|
-
wafer/templates/trace_analyze.py,sha256=XE1VqzVkIUsZbXF8EzQdDYgg-AZEYAOFpr6B_vnRELc,2880
|
|
37
|
-
wafer_cli-0.2.14.dist-info/METADATA,sha256=Ul8te_86H-H1ZWNrK7P61EU_wlBIpS6qPIkygJV1zjg,560
|
|
38
|
-
wafer_cli-0.2.14.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
|
|
39
|
-
wafer_cli-0.2.14.dist-info/entry_points.txt,sha256=WqB7hB__WhtPY8y1cO2sZiUz7fCq6Ik-usAigpeFvWE,41
|
|
40
|
-
wafer_cli-0.2.14.dist-info/top_level.txt,sha256=2MK1IVMWfpLL8BZCQ3E9aG6L6L666gSA_teYlwan4fs,6
|
|
41
|
-
wafer_cli-0.2.14.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|