runtrim 0.1.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 +21 -0
- package/README.md +230 -0
- package/dist-cli/package.json +3 -0
- package/dist-cli/runtrim.cjs +5 -0
- package/dist-cli/runtrim.js +5365 -0
- package/package.json +96 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 RunTrim
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
# RunTrim
|
|
2
|
+
|
|
3
|
+
Scope the run before the agent touches your repo.
|
|
4
|
+
|
|
5
|
+
RunTrim is a local-first control layer for AI coding agents. It prepares guarded prompts, monitors execution scope, checks outcomes, and keeps project memory so the next run starts with context.
|
|
6
|
+
|
|
7
|
+
## What RunTrim is
|
|
8
|
+
|
|
9
|
+
RunTrim is a CLI for developers using tools like Claude Code, Codex, Cursor, and ChatGPT. It sits in front of your coding run and helps you avoid risky, oversized, or context-wasting prompts.
|
|
10
|
+
|
|
11
|
+
## Why RunTrim exists
|
|
12
|
+
|
|
13
|
+
AI coding runs often fail for operational reasons, not model quality:
|
|
14
|
+
- tasks are too broad
|
|
15
|
+
- sensitive surfaces are touched by accident
|
|
16
|
+
- context is lost between sessions
|
|
17
|
+
- teams repeat failed attempts without a reliable run log
|
|
18
|
+
|
|
19
|
+
RunTrim adds structure before the run and continuity after the run.
|
|
20
|
+
|
|
21
|
+
## Daily loop
|
|
22
|
+
|
|
23
|
+
Recommended daily flow:
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
runtrim go "your task"
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
RunTrim prepares a guarded prompt, copies it for your agent, records the run locally, and prints the next steps.
|
|
30
|
+
Paste the guarded prompt into your agent.
|
|
31
|
+
Keep the local panel open:
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
runtrim panel --monitor
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
After edits:
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
runtrim check
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
If context or usage runs out:
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
runtrim continue --reason usage_limit
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Guided menu when unsure:
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
runtrim start
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
`runtrim start` checks repo state and tells you the next safe command.
|
|
56
|
+
Free includes 1 tracked local repo.
|
|
57
|
+
|
|
58
|
+
Direct operator flow:
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
runtrim go "fix checkout redirect"
|
|
62
|
+
runtrim panel --monitor
|
|
63
|
+
runtrim check
|
|
64
|
+
runtrim continue --reason usage_limit
|
|
65
|
+
runtrim memory
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Install
|
|
69
|
+
|
|
70
|
+
Global install for end users:
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
npm install -g runtrim
|
|
74
|
+
runtrim go "your task"
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
Local preview for repository development:
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
git clone https://github.com/michelpronkk-oss/rtrim
|
|
81
|
+
cd rtrim
|
|
82
|
+
npm install
|
|
83
|
+
npm run runtrim -- init
|
|
84
|
+
npm run runtrim -- start
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
## What RunTrim does
|
|
88
|
+
|
|
89
|
+
- audits task scope before execution
|
|
90
|
+
- blocks unsafe mega-runs and suggests split-safe follow-ups
|
|
91
|
+
- generates guarded prompts with explicit stop rules
|
|
92
|
+
- monitors changed files during execution
|
|
93
|
+
- checks output quality and missing proof after edits
|
|
94
|
+
- stores local run memory in `.runtrim/`
|
|
95
|
+
|
|
96
|
+
## Core commands
|
|
97
|
+
|
|
98
|
+
```bash
|
|
99
|
+
runtrim init
|
|
100
|
+
runtrim go "<task>"
|
|
101
|
+
runtrim start
|
|
102
|
+
runtrim prepare "<task>"
|
|
103
|
+
runtrim panel
|
|
104
|
+
runtrim panel --monitor
|
|
105
|
+
runtrim check
|
|
106
|
+
runtrim continue --reason usage_limit
|
|
107
|
+
runtrim memory
|
|
108
|
+
runtrim sync
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
Advanced commands:
|
|
112
|
+
|
|
113
|
+
```bash
|
|
114
|
+
runtrim prepare "<task>"
|
|
115
|
+
runtrim start
|
|
116
|
+
runtrim panel
|
|
117
|
+
runtrim panel --monitor
|
|
118
|
+
runtrim check
|
|
119
|
+
runtrim continue --reason usage_limit
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
## Examples
|
|
123
|
+
|
|
124
|
+
Guarded prepare flow:
|
|
125
|
+
|
|
126
|
+
```bash
|
|
127
|
+
runtrim prepare "fix checkout redirect"
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
High-risk split-required flow:
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
runtrim prepare "rewrite auth flow, middleware, database schema and billing"
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
## Monitor and panel
|
|
137
|
+
|
|
138
|
+
Use `runtrim panel` to open a local browser panel on localhost.
|
|
139
|
+
Use `runtrim panel --monitor` to open the same local panel with live git change monitoring.
|
|
140
|
+
|
|
141
|
+
It keeps local run state visible and warns when scope drifts into risky or forbidden areas.
|
|
142
|
+
Quick keys in panel:
|
|
143
|
+
- `p` prepare
|
|
144
|
+
- `g` guard
|
|
145
|
+
- `c` check
|
|
146
|
+
- `m` memory
|
|
147
|
+
- `r` report
|
|
148
|
+
- `s` sync
|
|
149
|
+
- `q` quit
|
|
150
|
+
|
|
151
|
+
## Check
|
|
152
|
+
|
|
153
|
+
Run `runtrim check` after the agent edits files.
|
|
154
|
+
|
|
155
|
+
It validates changed files, summarizes risk posture, and reports missing proof items before you continue.
|
|
156
|
+
|
|
157
|
+
## Continuation recovery
|
|
158
|
+
|
|
159
|
+
When a run stops due to usage or context limits:
|
|
160
|
+
|
|
161
|
+
```bash
|
|
162
|
+
runtrim continue --reason usage_limit
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
RunTrim prepares a continuation prompt and stores continuation metadata in local memory.
|
|
166
|
+
|
|
167
|
+
## Project memory
|
|
168
|
+
|
|
169
|
+
`runtrim memory` shows where the project currently stands:
|
|
170
|
+
- latest task and run status
|
|
171
|
+
- changed files
|
|
172
|
+
- missing proof
|
|
173
|
+
- protected areas
|
|
174
|
+
- next safe action
|
|
175
|
+
|
|
176
|
+
## Sync V0 private beta
|
|
177
|
+
|
|
178
|
+
Cloud sync is private beta and metadata-only.
|
|
179
|
+
|
|
180
|
+
Sync can upload:
|
|
181
|
+
- project name and status
|
|
182
|
+
- run status and risk metadata
|
|
183
|
+
- RunTrim-generated prompts
|
|
184
|
+
- changed file paths
|
|
185
|
+
- project memory summaries
|
|
186
|
+
- timestamps and estimated savings
|
|
187
|
+
|
|
188
|
+
Sync does not intentionally upload:
|
|
189
|
+
- source code
|
|
190
|
+
- `.env` values
|
|
191
|
+
- secret file contents
|
|
192
|
+
|
|
193
|
+
```bash
|
|
194
|
+
runtrim auth set "<token>"
|
|
195
|
+
runtrim config set dashboard-url https://www.runtrim.com/app
|
|
196
|
+
runtrim sync
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
## Privacy model
|
|
200
|
+
|
|
201
|
+
RunTrim Free runs locally and stores state in `.runtrim`.
|
|
202
|
+
Free includes 1 tracked local repo. Builder early access supports unlimited tracked repos.
|
|
203
|
+
A tracked repo is one codebase with its own `.runtrim` workspace.
|
|
204
|
+
|
|
205
|
+
V1 is designed so source code is not uploaded. Cloud sync stores metadata only when enabled.
|
|
206
|
+
|
|
207
|
+
See:
|
|
208
|
+
- https://www.runtrim.com/privacy
|
|
209
|
+
- https://www.runtrim.com/security
|
|
210
|
+
|
|
211
|
+
## Status
|
|
212
|
+
|
|
213
|
+
RunTrim is in early V1.
|
|
214
|
+
|
|
215
|
+
Free local CLI is available. Cloud sync and hosted dashboard access are private beta.
|
|
216
|
+
|
|
217
|
+
## Roadmap
|
|
218
|
+
|
|
219
|
+
- npm package launch hardening
|
|
220
|
+
- stronger local policy presets
|
|
221
|
+
- richer post-run verification workflows
|
|
222
|
+
- expanded cloud memory rollout
|
|
223
|
+
|
|
224
|
+
## Packaging
|
|
225
|
+
|
|
226
|
+
```bash
|
|
227
|
+
npm run build
|
|
228
|
+
npm run build:cli
|
|
229
|
+
npm pack --dry-run
|
|
230
|
+
```
|