@agentreel/agent 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 +74 -0
- package/dist/cli.js +1148 -0
- package/dist/cli.js.map +1 -0
- package/package.json +67 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 AgentReel / Black Highlights
|
|
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,74 @@
|
|
|
1
|
+
# @agentreel/agent
|
|
2
|
+
|
|
3
|
+
> **Loom for AI coding sessions.** The local agent for [AgentReel](https://agentreel.dev) — captures every Claude Code and Cursor session on your machine, scrubs PII before anything leaves it, and ships replays you can share, scrub, and export to MP4.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
npx @agentreel/agent init
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
`init` writes Claude Code hooks into `~/.claude/settings.json` and creates a local SQLite buffer at `~/.agentreel/sessions.db`. That's the entire setup.
|
|
12
|
+
|
|
13
|
+
For faster cold-starts on every hook fire, install globally instead:
|
|
14
|
+
|
|
15
|
+
```sh
|
|
16
|
+
npm install -g @agentreel/agent
|
|
17
|
+
agentreel init
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## What it does
|
|
21
|
+
|
|
22
|
+
- **Claude Code** — installs hooks for every lifecycle event (`PreToolUse`, `PostToolUse`, `UserPromptSubmit`, `SessionStart`, `SessionEnd`, plus the rest). Each event is normalized and persisted locally.
|
|
23
|
+
- **Cursor** — watches `~/Library/Application Support/Cursor/User/History/` and turns every saved snapshot into a unified diff against the previous version. Distinguishes AI-driven (Composer) edits from manual ones.
|
|
24
|
+
- **PII scrubbing, default-on** — AWS / GitHub / OpenAI / Anthropic / Stripe / Slack / Google / npm tokens, JWTs, PEM private keys, dotenv `KEY=VAL` lines, emails, IPv4. Scrubs *before* anything is persisted, never after.
|
|
25
|
+
- **`.agentreelignore`** — gitignore-syntax exclusions per workspace.
|
|
26
|
+
- **Local first** — works offline. Sign in only when you want to share.
|
|
27
|
+
|
|
28
|
+
## Usage
|
|
29
|
+
|
|
30
|
+
```sh
|
|
31
|
+
agentreel init # install Claude Code hooks + create local DB
|
|
32
|
+
agentreel watch # start the Cursor filesystem watcher
|
|
33
|
+
agentreel status # what's captured, what's pending upload
|
|
34
|
+
agentreel link <api-key> # authenticate with agentreel.dev
|
|
35
|
+
agentreel push # upload pending events to the cloud
|
|
36
|
+
agentreel uninstall # remove hooks from ~/.claude/settings.json
|
|
37
|
+
agentreel logout # clear local credentials
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
Get an API key at [agentreel.dev/dashboard/settings](https://agentreel.dev/dashboard/settings).
|
|
41
|
+
|
|
42
|
+
## Where things live
|
|
43
|
+
|
|
44
|
+
| Path | What |
|
|
45
|
+
| ------------------------- | ------------------------------------------------- |
|
|
46
|
+
| `~/.agentreel/sessions.db`| SQLite buffer for sessions + events |
|
|
47
|
+
| `~/.agentreel/config.json`| API key (if linked), API base URL |
|
|
48
|
+
| `~/.agentreel/agent.log` | Hook-handler error log |
|
|
49
|
+
| `~/.claude/settings.json` | Claude Code hooks (added by `agentreel init`) |
|
|
50
|
+
| `<workspace>/.agentreelignore` | Per-project exclusions, gitignore syntax |
|
|
51
|
+
|
|
52
|
+
## Privacy
|
|
53
|
+
|
|
54
|
+
PII scrubbing runs at the source, not in the cloud. The unified diff stored on each Cursor edit is computed against the **scrubbed** versions of the file, so secrets never enter the patch text. Verify it yourself:
|
|
55
|
+
|
|
56
|
+
```sh
|
|
57
|
+
agentreel status
|
|
58
|
+
sqlite3 ~/.agentreel/sessions.db "SELECT payload FROM events LIMIT 5;" | grep -E "AKIA|ghp_|sk-"
|
|
59
|
+
# (no matches expected)
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## Requirements
|
|
63
|
+
|
|
64
|
+
- Node 20+
|
|
65
|
+
- macOS, Linux, or Windows (WSL recommended)
|
|
66
|
+
- Claude Code or Cursor (or both)
|
|
67
|
+
|
|
68
|
+
## License
|
|
69
|
+
|
|
70
|
+
MIT — see [LICENSE](./LICENSE).
|
|
71
|
+
|
|
72
|
+
---
|
|
73
|
+
|
|
74
|
+
Built by [Black Highlights](https://blackhighlights.com). Source: [github.com/agentreel/agentreel](https://github.com/agentreel/agentreel).
|