ws-aitoolkit 0.1.4__tar.gz → 0.1.6__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 (118) hide show
  1. ws_aitoolkit-0.1.6/PKG-INFO +154 -0
  2. ws_aitoolkit-0.1.6/README.md +133 -0
  3. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/pyproject.toml +5 -1
  4. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/pyproject.toml.orig +5 -1
  5. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/_build.py +2 -2
  6. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/approvals.py +13 -1
  7. ws_aitoolkit-0.1.6/src/ws/brand.py +348 -0
  8. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/cli.py +16 -5
  9. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/doctor.py +35 -7
  10. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/evalstats.py +20 -0
  11. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/extcmd.py +8 -2
  12. ws_aitoolkit-0.1.6/src/ws/guards/claims.py +457 -0
  13. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/guards/record_calls.py +8 -4
  14. ws_aitoolkit-0.1.6/src/ws/guards/session_context.py +186 -0
  15. ws_aitoolkit-0.1.6/src/ws/guards/skill_gate.py +263 -0
  16. ws_aitoolkit-0.1.6/src/ws/guards/spawn_cap.py +164 -0
  17. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/guards/syntax_check.py +5 -1
  18. ws_aitoolkit-0.1.6/src/ws/home/__init__.py +5 -0
  19. ws_aitoolkit-0.1.6/src/ws/home/api.py +442 -0
  20. ws_aitoolkit-0.1.6/src/ws/home/cli.py +53 -0
  21. ws_aitoolkit-0.1.6/src/ws/home/records.py +373 -0
  22. ws_aitoolkit-0.1.6/src/ws/home/sources/__init__.py +62 -0
  23. ws_aitoolkit-0.1.6/src/ws/home/sources/_files.py +148 -0
  24. ws_aitoolkit-0.1.6/src/ws/home/sources/asks_jsonl.py +71 -0
  25. ws_aitoolkit-0.1.6/src/ws/home/sources/claude_code.py +139 -0
  26. ws_aitoolkit-0.1.6/src/ws/home/sources/collie.py +18 -0
  27. ws_aitoolkit-0.1.6/src/ws/home/sources/events_dir.py +47 -0
  28. ws_aitoolkit-0.1.6/src/ws/home/sources/otel_jsonl.py +47 -0
  29. ws_aitoolkit-0.1.6/src/ws/home/sources/transcripts.py +75 -0
  30. ws_aitoolkit-0.1.6/src/ws/home/sources/ws_approvals.py +46 -0
  31. ws_aitoolkit-0.1.6/src/ws/home/sources/ws_eval.py +79 -0
  32. ws_aitoolkit-0.1.6/src/ws/home/sources/ws_plugins.py +34 -0
  33. ws_aitoolkit-0.1.6/src/ws/home/sources/ws_runs.py +66 -0
  34. ws_aitoolkit-0.1.6/src/ws/home/sources/ws_sessions.py +37 -0
  35. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/install.py +282 -79
  36. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/jsonl.py +52 -6
  37. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/modules.py +27 -4
  38. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/output.py +23 -9
  39. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/policy.py +205 -31
  40. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/rating.py +3 -2
  41. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/_schedule.py +30 -0
  42. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/systemd.py +30 -14
  43. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/run.py +4 -2
  44. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/runrecord.py +3 -2
  45. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/runschema.py +6 -1
  46. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/sandbox.py +72 -11
  47. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/session.py +8 -3
  48. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/setup_ui/__init__.py +26 -14
  49. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/setup_ui/flow.py +16 -6
  50. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/setup_ui/inline.py +46 -36
  51. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/setup_ui/web.py +109 -217
  52. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/skills/taste_gate.py +3 -3
  53. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/status.py +30 -7
  54. ws_aitoolkit-0.1.6/src/ws/style.py +116 -0
  55. ws_aitoolkit-0.1.6/src/ws/ui/__init__.py +8 -0
  56. ws_aitoolkit-0.1.6/src/ws/ui/components.py +109 -0
  57. ws_aitoolkit-0.1.6/src/ws/ui/css.py +84 -0
  58. ws_aitoolkit-0.1.6/src/ws/ui/server.py +197 -0
  59. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/usage.py +61 -5
  60. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/userconfig.py +64 -11
  61. ws_aitoolkit-0.1.4/PKG-INFO +0 -144
  62. ws_aitoolkit-0.1.4/README.md +0 -127
  63. ws_aitoolkit-0.1.4/src/ws/guards/claims.py +0 -228
  64. ws_aitoolkit-0.1.4/src/ws/guards/session_context.py +0 -86
  65. ws_aitoolkit-0.1.4/src/ws/guards/skill_gate.py +0 -98
  66. ws_aitoolkit-0.1.4/src/ws/guards/spawn_cap.py +0 -93
  67. ws_aitoolkit-0.1.4/src/ws/setup_ui/brand.py +0 -94
  68. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/LICENSE +0 -0
  69. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/NOTICE +0 -0
  70. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/__init__.py +0 -0
  71. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/__main__.py +0 -0
  72. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/adapters/__init__.py +0 -0
  73. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/adapters/claude_code.py +0 -0
  74. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/adapters/opencode.py +0 -0
  75. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/adapters/opencode_plugin.py +0 -0
  76. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/broker.py +0 -0
  77. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/canary.py +0 -0
  78. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/config_cmd.py +0 -0
  79. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/devices.py +0 -0
  80. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/eval.py +0 -0
  81. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/frontmatter.py +0 -0
  82. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/gate.py +0 -0
  83. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/globals.py +0 -0
  84. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/guards/__init__.py +0 -0
  85. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/guards/_paths.py +0 -0
  86. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/guards/bulk_staging.py +0 -0
  87. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/guards/test_weakening.py +0 -0
  88. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/jobs.py +0 -0
  89. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/mcp_server.py +0 -0
  90. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/memory.py +0 -0
  91. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/notes.py +0 -0
  92. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/notesdetect.py +0 -0
  93. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/osinfo.py +0 -0
  94. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/profile.py +0 -0
  95. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/__init__.py +0 -0
  96. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/anthropic.py +0 -0
  97. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/commands.py +0 -0
  98. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/launchd.py +0 -0
  99. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/markdown_git.py +0 -0
  100. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/notify_none.py +0 -0
  101. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/ntfy.py +0 -0
  102. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/opencode.py +0 -0
  103. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/restic.py +0 -0
  104. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/secrets_env.py +0 -0
  105. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/secrets_ws.py +0 -0
  106. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/roles/sops_age.py +0 -0
  107. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/secrets.py +0 -0
  108. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/selfcmd.py +0 -0
  109. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/skills/__init__.py +0 -0
  110. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/skills/align.py +0 -0
  111. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/skills/checkpoint.py +0 -0
  112. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/skills/dataviz.py +0 -0
  113. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/skills/resume.py +0 -0
  114. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/skills/ship.py +0 -0
  115. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/testing/__init__.py +0 -0
  116. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/testing/mockprovider.py +0 -0
  117. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/testing/scenarios.py +0 -0
  118. {ws_aitoolkit-0.1.4 → ws_aitoolkit-0.1.6}/src/ws/version.py +0 -0
@@ -0,0 +1,154 @@
1
+ Metadata-Version: 2.4
2
+ Name: ws-aitoolkit
3
+ Version: 0.1.6
4
+ Summary: Your memory, skills and rules, in any AI.
5
+ Author: Michael Fry
6
+ License-Expression: Apache-2.0
7
+ License-File: LICENSE
8
+ License-File: NOTICE
9
+ Classifier: Development Status :: 2 - Pre-Alpha
10
+ Classifier: Environment :: Console
11
+ Classifier: Operating System :: MacOS
12
+ Classifier: Operating System :: POSIX :: Linux
13
+ Classifier: Programming Language :: Python :: 3
14
+ Requires-Python: >=3.11
15
+ Project-URL: Source, https://github.com/Michael-A-Fry/ws
16
+ Project-URL: Documentation, https://github.com/Michael-A-Fry/ws/blob/main/docs/README.md
17
+ Project-URL: Changelog, https://github.com/Michael-A-Fry/ws/blob/main/CHANGELOG.md
18
+ Project-URL: Issues, https://github.com/Michael-A-Fry/ws/issues
19
+ Project-URL: Security, https://github.com/Michael-A-Fry/ws/blob/main/SECURITY.md
20
+ Description-Content-Type: text/markdown
21
+
22
+ # ws: Your memory, skills and rules, in any AI
23
+
24
+ [![PyPI version](https://img.shields.io/pypi/v/ws-aitoolkit)](https://pypi.org/project/ws-aitoolkit/)
25
+ [![Python versions](https://img.shields.io/pypi/pyversions/ws-aitoolkit)](https://pypi.org/project/ws-aitoolkit/)
26
+ [![Licence: Apache-2.0](https://img.shields.io/pypi/l/ws-aitoolkit)](LICENSE)
27
+ [![CI](https://github.com/Michael-A-Fry/ws/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/Michael-A-Fry/ws/actions/workflows/ci.yml)
28
+
29
+ ws turns one `policy.toml` into each AI tool's own config, answers the tools' hooks, and runs headless jobs that leave
30
+ one complete record each. Your memory, skills and rules live in plain files that you own, so you can change tool or
31
+ model without starting again.
32
+
33
+ ws is a small command-line toolkit. The core is Python 3.11 or newer and the standard library only. It runs on macOS and
34
+ Linux. On Windows it runs inside WSL2.
35
+
36
+ ## Install
37
+
38
+ Run the installer. It checks the machine, installs the `ws` command with uv or pipx, and runs a smoke test.
39
+
40
+ ```sh
41
+ curl -fsSL https://raw.githubusercontent.com/Michael-A-Fry/ws/main/install.sh | bash
42
+ ```
43
+
44
+ Or install the package yourself:
45
+
46
+ ```sh
47
+ pipx install ws-aitoolkit
48
+ ```
49
+
50
+ For other ways to install, including a pinned version, see [Install ws](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/install.md).
51
+
52
+ ## First command
53
+
54
+ ```sh
55
+ ws doctor
56
+ ```
57
+
58
+ `ws doctor` prints one line per check, each with a stable ID. `WS0xx` checks cover the machine and `WS1xx` checks cover
59
+ the roles you set up (runner, model, budget, secrets, memory, notes, scheduler, notify, backup, usage).
60
+
61
+ | Status | Meaning |
62
+ |---|---|
63
+ | `ok` | The check passed. |
64
+ | `warn` | It works, but something weakens it. Read the `fix:` line. |
65
+ | `unconfigured` | You haven't set this up yet. This is normal on a new install. |
66
+ | `fail` | Something is wrong. Read the `fix:` line. |
67
+
68
+ Doctor exits with 1 while anything needs doing, so a new install exits with 1. Run `ws init` to answer the three setup
69
+ questions, or `ws setup` to go step by step. `ws doctor --json` gives the same report for scripts.
70
+
71
+ To follow a whole first session, see the [first-run tutorial](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/tutorials/first-run.md).
72
+
73
+ ## Skills
74
+
75
+ `ws install` puts six skills in your runner's skills folder: `align`, `checkpoint`, `taste-gate`, `dataviz`, `resume`
76
+ and `ship`. `ws skills` lists them per runner. A skill you already have under one of those names stays as it is.
77
+
78
+ To use ws's version of a name you already have, run `ws skills adopt NAME`. Yours moves to
79
+ `$WS_HOME/backups/skills/<runner>/` and ws installs its own. `ws skills restore NAME` takes ws's copy out and moves yours
80
+ back.
81
+
82
+ ## Verify
83
+
84
+ Check which build you have:
85
+
86
+ ```sh
87
+ ws version --json
88
+ ```
89
+
90
+ The output has `version`, `git_sha`, `dirty`, `build_date`, `python`, `install_path` and `install_source`. Each release
91
+ carries a checksum, a build provenance attestation, a Sigstore bundle and an SBOM. To check them, see
92
+ [Verify a release](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/verify-a-release.md).
93
+
94
+ ## Troubleshooting
95
+
96
+ | Problem | Fix |
97
+ |---|---|
98
+ | Neither uv nor pipx is installed | Install one: `curl -LsSf https://astral.sh/uv/install.sh \| sh`. The installer prints the line for your OS. |
99
+ | Python is older than 3.11 | Use uv, which fetches a current Python for you. |
100
+ | Native Windows | ws runs inside WSL2. Run `wsl --install -d Ubuntu-24.04`, then run the installer in that shell. |
101
+ | `ws` isn't found after the install | Run `uv tool update-shell` or `pipx ensurepath`, then open a new terminal. |
102
+
103
+ For more, see [Troubleshoot ws](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/troubleshoot.md).
104
+
105
+ ## Documentation
106
+
107
+ Start with the [documentation map](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/README.md). Pages are grouped as tutorials, how-to guides, explanation and
108
+ reference (the [Diátaxis](https://diataxis.fr/) split).
109
+
110
+ | Page | What it covers |
111
+ |---|---|
112
+ | [Usage](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/usage.md) | Every command, one task each |
113
+ | [First run](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/tutorials/first-run.md) | Install, check, set up and run a first task |
114
+ | [Install](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/install.md) | Install options and pinning a version |
115
+ | [Verify a release](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/verify-a-release.md) | Checksum, attestation, Sigstore bundle |
116
+ | [Upgrade and uninstall](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/upgrade-and-uninstall.md) | Move to a new version, or remove ws |
117
+ | [Troubleshoot](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/troubleshoot.md) | Install and doctor failures |
118
+ | [Use the gate](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/use-the-gate.md) | Turn the policy into each runner's rules |
119
+ | [Use the wall](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/use-the-wall.md) | Run a runner inside the sandbox |
120
+ | [Approve a command](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/approve-a-command.md) | Give a refused call a single-use yes |
121
+ | [Store a secret](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/store-a-secret.md) | Keep a key where agents can't read it |
122
+ | [Apply the Rule of Two](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/apply-the-rule-of-two.md) | Limit what one session can combine |
123
+ | [Set a budget](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/set-a-budget.md) | Cap spend per month |
124
+ | [Send drafts only](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/send-drafts-only.md) | Let agents draft, never send |
125
+ | [Run an eval](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/run-an-eval.md) | Compare two setups on your own tasks |
126
+ | [The gate](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/gate.md) | How policy becomes enforcement |
127
+ | [The wall](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/wall.md) | What the sandbox stops and what it doesn't |
128
+ | [Approvals](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/approvals.md) | Why an approval is bound and single-use |
129
+ | [The broker](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/broker.md) | Why agents never see a secret |
130
+ | [The Rule of Two](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/rule-of-two.md) | The design rule behind the policy |
131
+ | [Budget](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/budget.md) | How caps are counted |
132
+ | [Draft-only sending](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/draft-only-sending.md) | Why ws never sends for you |
133
+ | [Known limits](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/known-limits.md) | What ws doesn't protect against yet |
134
+ | [Write-up 1](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/write-up-1.md) | The design and what we measured |
135
+ | [CLI reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/cli.md) | Every command and flag |
136
+ | [Doctor checks](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/doctor-checks.md) | Every check ID |
137
+ | [Policy reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/policy.md) | Every `policy.toml` key |
138
+ | [Eval reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/eval.md) | Task format, graders, metrics |
139
+ | [Lab reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/lab.md) | The lab machine and the launch matrix |
140
+ | [`ws version --json`](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/version-json.md) | The fields of the version report |
141
+ | [Principles](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/principles.md) | The rules ws follows and the check for each |
142
+
143
+ For contributors: [CONTRIBUTING.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CONTRIBUTING.md), [SECURITY.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/SECURITY.md), [SUPPORT.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/SUPPORT.md),
144
+ [CHANGELOG.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CHANGELOG.md) and [AGENTS.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/AGENTS.md).
145
+
146
+ ## Status
147
+
148
+ ws is pre-1.0. Commands, JSON output and `policy.toml` keys can still change between releases, and the
149
+ [CHANGELOG](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CHANGELOG.md) says when they do. Doctor IDs never change meaning once released. Read
150
+ [Known limits](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/known-limits.md) before you rely on the wall or the gate.
151
+
152
+ ## Licence
153
+
154
+ ws is [Apache-2.0](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/LICENSE). Contributions need the [CLA](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CLA.md), signed through a bot on your first pull request.
@@ -0,0 +1,133 @@
1
+ # ws: Your memory, skills and rules, in any AI
2
+
3
+ [![PyPI version](https://img.shields.io/pypi/v/ws-aitoolkit)](https://pypi.org/project/ws-aitoolkit/)
4
+ [![Python versions](https://img.shields.io/pypi/pyversions/ws-aitoolkit)](https://pypi.org/project/ws-aitoolkit/)
5
+ [![Licence: Apache-2.0](https://img.shields.io/pypi/l/ws-aitoolkit)](LICENSE)
6
+ [![CI](https://github.com/Michael-A-Fry/ws/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/Michael-A-Fry/ws/actions/workflows/ci.yml)
7
+
8
+ ws turns one `policy.toml` into each AI tool's own config, answers the tools' hooks, and runs headless jobs that leave
9
+ one complete record each. Your memory, skills and rules live in plain files that you own, so you can change tool or
10
+ model without starting again.
11
+
12
+ ws is a small command-line toolkit. The core is Python 3.11 or newer and the standard library only. It runs on macOS and
13
+ Linux. On Windows it runs inside WSL2.
14
+
15
+ ## Install
16
+
17
+ Run the installer. It checks the machine, installs the `ws` command with uv or pipx, and runs a smoke test.
18
+
19
+ ```sh
20
+ curl -fsSL https://raw.githubusercontent.com/Michael-A-Fry/ws/main/install.sh | bash
21
+ ```
22
+
23
+ Or install the package yourself:
24
+
25
+ ```sh
26
+ pipx install ws-aitoolkit
27
+ ```
28
+
29
+ For other ways to install, including a pinned version, see [Install ws](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/install.md).
30
+
31
+ ## First command
32
+
33
+ ```sh
34
+ ws doctor
35
+ ```
36
+
37
+ `ws doctor` prints one line per check, each with a stable ID. `WS0xx` checks cover the machine and `WS1xx` checks cover
38
+ the roles you set up (runner, model, budget, secrets, memory, notes, scheduler, notify, backup, usage).
39
+
40
+ | Status | Meaning |
41
+ |---|---|
42
+ | `ok` | The check passed. |
43
+ | `warn` | It works, but something weakens it. Read the `fix:` line. |
44
+ | `unconfigured` | You haven't set this up yet. This is normal on a new install. |
45
+ | `fail` | Something is wrong. Read the `fix:` line. |
46
+
47
+ Doctor exits with 1 while anything needs doing, so a new install exits with 1. Run `ws init` to answer the three setup
48
+ questions, or `ws setup` to go step by step. `ws doctor --json` gives the same report for scripts.
49
+
50
+ To follow a whole first session, see the [first-run tutorial](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/tutorials/first-run.md).
51
+
52
+ ## Skills
53
+
54
+ `ws install` puts six skills in your runner's skills folder: `align`, `checkpoint`, `taste-gate`, `dataviz`, `resume`
55
+ and `ship`. `ws skills` lists them per runner. A skill you already have under one of those names stays as it is.
56
+
57
+ To use ws's version of a name you already have, run `ws skills adopt NAME`. Yours moves to
58
+ `$WS_HOME/backups/skills/<runner>/` and ws installs its own. `ws skills restore NAME` takes ws's copy out and moves yours
59
+ back.
60
+
61
+ ## Verify
62
+
63
+ Check which build you have:
64
+
65
+ ```sh
66
+ ws version --json
67
+ ```
68
+
69
+ The output has `version`, `git_sha`, `dirty`, `build_date`, `python`, `install_path` and `install_source`. Each release
70
+ carries a checksum, a build provenance attestation, a Sigstore bundle and an SBOM. To check them, see
71
+ [Verify a release](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/verify-a-release.md).
72
+
73
+ ## Troubleshooting
74
+
75
+ | Problem | Fix |
76
+ |---|---|
77
+ | Neither uv nor pipx is installed | Install one: `curl -LsSf https://astral.sh/uv/install.sh \| sh`. The installer prints the line for your OS. |
78
+ | Python is older than 3.11 | Use uv, which fetches a current Python for you. |
79
+ | Native Windows | ws runs inside WSL2. Run `wsl --install -d Ubuntu-24.04`, then run the installer in that shell. |
80
+ | `ws` isn't found after the install | Run `uv tool update-shell` or `pipx ensurepath`, then open a new terminal. |
81
+
82
+ For more, see [Troubleshoot ws](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/troubleshoot.md).
83
+
84
+ ## Documentation
85
+
86
+ Start with the [documentation map](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/README.md). Pages are grouped as tutorials, how-to guides, explanation and
87
+ reference (the [Diátaxis](https://diataxis.fr/) split).
88
+
89
+ | Page | What it covers |
90
+ |---|---|
91
+ | [Usage](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/usage.md) | Every command, one task each |
92
+ | [First run](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/tutorials/first-run.md) | Install, check, set up and run a first task |
93
+ | [Install](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/install.md) | Install options and pinning a version |
94
+ | [Verify a release](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/verify-a-release.md) | Checksum, attestation, Sigstore bundle |
95
+ | [Upgrade and uninstall](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/upgrade-and-uninstall.md) | Move to a new version, or remove ws |
96
+ | [Troubleshoot](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/troubleshoot.md) | Install and doctor failures |
97
+ | [Use the gate](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/use-the-gate.md) | Turn the policy into each runner's rules |
98
+ | [Use the wall](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/use-the-wall.md) | Run a runner inside the sandbox |
99
+ | [Approve a command](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/approve-a-command.md) | Give a refused call a single-use yes |
100
+ | [Store a secret](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/store-a-secret.md) | Keep a key where agents can't read it |
101
+ | [Apply the Rule of Two](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/apply-the-rule-of-two.md) | Limit what one session can combine |
102
+ | [Set a budget](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/set-a-budget.md) | Cap spend per month |
103
+ | [Send drafts only](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/send-drafts-only.md) | Let agents draft, never send |
104
+ | [Run an eval](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/how-to/run-an-eval.md) | Compare two setups on your own tasks |
105
+ | [The gate](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/gate.md) | How policy becomes enforcement |
106
+ | [The wall](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/wall.md) | What the sandbox stops and what it doesn't |
107
+ | [Approvals](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/approvals.md) | Why an approval is bound and single-use |
108
+ | [The broker](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/broker.md) | Why agents never see a secret |
109
+ | [The Rule of Two](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/rule-of-two.md) | The design rule behind the policy |
110
+ | [Budget](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/budget.md) | How caps are counted |
111
+ | [Draft-only sending](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/draft-only-sending.md) | Why ws never sends for you |
112
+ | [Known limits](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/known-limits.md) | What ws doesn't protect against yet |
113
+ | [Write-up 1](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/write-up-1.md) | The design and what we measured |
114
+ | [CLI reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/cli.md) | Every command and flag |
115
+ | [Doctor checks](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/doctor-checks.md) | Every check ID |
116
+ | [Policy reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/policy.md) | Every `policy.toml` key |
117
+ | [Eval reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/eval.md) | Task format, graders, metrics |
118
+ | [Lab reference](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/lab.md) | The lab machine and the launch matrix |
119
+ | [`ws version --json`](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/version-json.md) | The fields of the version report |
120
+ | [Principles](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/reference/principles.md) | The rules ws follows and the check for each |
121
+
122
+ For contributors: [CONTRIBUTING.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CONTRIBUTING.md), [SECURITY.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/SECURITY.md), [SUPPORT.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/SUPPORT.md),
123
+ [CHANGELOG.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CHANGELOG.md) and [AGENTS.md](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/AGENTS.md).
124
+
125
+ ## Status
126
+
127
+ ws is pre-1.0. Commands, JSON output and `policy.toml` keys can still change between releases, and the
128
+ [CHANGELOG](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CHANGELOG.md) says when they do. Doctor IDs never change meaning once released. Read
129
+ [Known limits](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/docs/explanation/known-limits.md) before you rely on the wall or the gate.
130
+
131
+ ## Licence
132
+
133
+ ws is [Apache-2.0](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/LICENSE). Contributions need the [CLA](https://github.com/Michael-A-Fry/ws/blob/v0.1.6/CLA.md), signed through a bot on your first pull request.
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "ws-aitoolkit"
3
- version = "0.1.4"
3
+ version = "0.1.6"
4
4
  description = "Your memory, skills and rules, in any AI."
5
5
  readme = "README.md"
6
6
  license = "Apache-2.0"
@@ -23,6 +23,10 @@ name = "Michael Fry"
23
23
 
24
24
  [project.urls]
25
25
  Source = "https://github.com/Michael-A-Fry/ws"
26
+ Documentation = "https://github.com/Michael-A-Fry/ws/blob/main/docs/README.md"
27
+ Changelog = "https://github.com/Michael-A-Fry/ws/blob/main/CHANGELOG.md"
28
+ Issues = "https://github.com/Michael-A-Fry/ws/issues"
29
+ Security = "https://github.com/Michael-A-Fry/ws/blob/main/SECURITY.md"
26
30
 
27
31
  [project.scripts]
28
32
  ws = "ws.cli:main"
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "ws-aitoolkit"
3
- version = "0.1.4"
3
+ version = "0.1.6"
4
4
  description = "Your memory, skills and rules, in any AI."
5
5
  readme = "README.md"
6
6
  license = "Apache-2.0"
@@ -19,6 +19,10 @@ classifiers = [
19
19
 
20
20
  [project.urls]
21
21
  Source = "https://github.com/Michael-A-Fry/ws"
22
+ Documentation = "https://github.com/Michael-A-Fry/ws/blob/main/docs/README.md"
23
+ Changelog = "https://github.com/Michael-A-Fry/ws/blob/main/CHANGELOG.md"
24
+ Issues = "https://github.com/Michael-A-Fry/ws/issues"
25
+ Security = "https://github.com/Michael-A-Fry/ws/blob/main/SECURITY.md"
22
26
 
23
27
  [project.scripts]
24
28
  ws = "ws.cli:main"
@@ -1,6 +1,6 @@
1
1
  """Written by the release workflow before uv build; absent in a checkout."""
2
2
 
3
- git_sha = "9ed7a1d78df76dd7e28498dd93f03890e6b1efb1"
3
+ git_sha = "d10f2190d9b2d0cc5b936d5d3712e06e71387e98"
4
4
  dirty = False
5
- build_date = "2026-11-01T15:26:17Z"
5
+ build_date = "2026-11-02T03:50:41Z"
6
6
  source = "release"
@@ -35,6 +35,9 @@ Who may approve: `ws approve` refuses when stdin is not a terminal, and when the
35
35
  third and the sandbox are what stand then, and this is not a defence against a determined session that can run
36
36
  arbitrary programs outside the wall. It stops the model approving itself by accident or by a plain instruction.
37
37
 
38
+ Each record is one JSON file named by its id, with `schema`, `ts` (when it was made; `v` is the older spelling of
39
+ `schema`) and `created` and `granted` as Unix seconds; docs/reference/stores.md lists it.
40
+
38
41
  Tamper: a granted record whose fields no longer hash to its id, whose timestamps are out of order or in the future, or
39
42
  that is unreadable, is refused and removed; the call goes back to asking. That catches a damaged or edited file. It does
40
43
  not stop a writer who can compute the hash, which is why the folder is a control path.
@@ -64,9 +67,11 @@ import time
64
67
  from dataclasses import dataclass
65
68
  from pathlib import Path
66
69
 
70
+ from ws import jsonl
67
71
  from ws.output import WsError
68
72
  from ws.profile import ws_home
69
73
 
74
+ SCHEMA_VERSION = 1 # the `schema` of a record in approvals/pending and approvals/granted
70
75
  TTL = 600 # seconds a pending or a granted approval lives
71
76
  ENV_MARKER = "WS_GATED_SESSION" # set in a gated session's env; `ws approve` refuses when it is there
72
77
  SANDBOX_MARKER = "WS_SANDBOXED" # set in the env of a session that has ws's sandbox block (the hook checks for it)
@@ -128,7 +133,14 @@ def _write(path: Path, record: dict) -> None:
128
133
 
129
134
 
130
135
  def _record(bound: Bound, created: float, granted: float | None = None) -> dict:
131
- rec = {"v": 1, "id": bound.digest(), "bound": bound.__dict__.copy(), "created": created}
136
+ rec = {
137
+ "v": 1, # legacy spelling of `schema`, kept for one release
138
+ "schema": SCHEMA_VERSION,
139
+ "ts": jsonl.iso_utc(created if granted is None else granted), # when this file was written
140
+ "id": bound.digest(),
141
+ "bound": bound.__dict__.copy(),
142
+ "created": created,
143
+ }
132
144
  if granted is not None:
133
145
  rec["granted"] = granted
134
146
  return rec