@c4t4/heyamigo 0.1.5 → 0.1.9

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/README.md CHANGED
@@ -92,14 +92,15 @@ That's it. Runs in the background, auto-restarts on crash, survives SSH disconne
92
92
  ## Commands
93
93
 
94
94
  ```
95
- heyamigo setup # setup wizard (includes WhatsApp pairing)
96
- heyamigo start # start (background, auto-restart)
97
- heyamigo stop # stop
98
- heyamigo restart # restart
99
- heyamigo logs # tail live logs
100
- heyamigo status # check if running
101
- heyamigo import <path> # import knowledge folder
102
- heyamigo dev # foreground (development)
95
+ npx @c4t4/heyamigo setup # setup wizard
96
+ npx @c4t4/heyamigo start # start (background, auto-restart)
97
+ npx @c4t4/heyamigo stop # stop
98
+ npx @c4t4/heyamigo restart # restart
99
+ npx @c4t4/heyamigo logs # tail live logs
100
+ npx @c4t4/heyamigo status # check if running
101
+ npx @c4t4/heyamigo update # update to latest version
102
+ npx @c4t4/heyamigo import <path> # import knowledge folder
103
+ npx @c4t4/heyamigo dev # foreground (development)
103
104
  ```
104
105
 
105
106
  ### In-chat commands
@@ -130,6 +131,16 @@ storage/memory/
130
131
  chats/ per-chat briefs
131
132
  ```
132
133
 
134
+ ### How memory updates
135
+
136
+ The bot updates memory in two ways:
137
+
138
+ **Real-time (DIGEST flag):** During a conversation, Claude decides if something is worth remembering (a preference, fact, life event). It appends a hidden `[DIGEST: reason]` tag to its reply, which gets stripped before sending. This triggers a background digest within 2 minutes that updates the person's profile and the chat brief.
139
+
140
+ **Background sweep:** Every 3 hours, the bot checks all active chats for new messages that weren't flagged. This catches anything Claude missed. You can also force an immediate update with the `/digest` command in chat.
141
+
142
+ Memory is stored as plain markdown files. You can read, edit, or delete them directly.
143
+
133
144
  ---
134
145
 
135
146
  ## Roles
@@ -160,13 +171,13 @@ All localhost. Nothing public.
160
171
 
161
172
  Three built-in:
162
173
 
163
- **Sharp** (default)
174
+ [**Sharp**](config/personalities/sharp.md) (default)
164
175
  Talks like a smart friend at dinner. Specific, confident, never vague. Won't hedge, won't lecture, won't sound like a brochure. Calls things out when they're obvious, meets people where they actually are. Checks every reply against: would I be embarrassed saying this out loud?
165
176
 
166
- **Casual**
177
+ [**Casual**](config/personalities/casual.md)
167
178
  Warm, relaxed, friend-over-coffee energy. Short messages, matches your vibe.
168
179
 
169
- **Professional**
180
+ [**Professional**](config/personalities/professional.md)
170
181
  Clear, efficient, business-appropriate. Gets to the answer fast.
171
182
 
172
183
  Create your own: add a `.md` file to `config/personalities/`, point `config.json` at it.
@@ -244,6 +255,22 @@ Not compatible with serverless (Lambda, Vercel). Needs a persistent WebSocket co
244
255
 
245
256
  ---
246
257
 
258
+ ## Tracking memory with git
259
+
260
+ The bot updates files in `storage/memory/` over time as it learns. We recommend tracking your project with git so you can see what changed and roll back if needed.
261
+
262
+ ```bash
263
+ cd ~/heyamigo
264
+ git init
265
+ echo "storage/auth/" >> .gitignore
266
+ echo "storage/logs/" >> .gitignore
267
+ git add -A && git commit -m "initial setup"
268
+ ```
269
+
270
+ Never commit `storage/auth/` — it contains your WhatsApp session keys.
271
+
272
+ ---
273
+
247
274
  ## Security
248
275
 
249
276
  - `storage/auth/` contains your WhatsApp session keys. Guard them.
@@ -59,7 +59,7 @@
59
59
  "importInstructionsFile": "./config/import-instructions.md",
60
60
  "importPermissionMode": "acceptEdits",
61
61
  "digestDebounceMs": 120000,
62
- "sweepIntervalMs": 21600000,
62
+ "sweepIntervalMs": 10800000,
63
63
  "sweepMinNewMessages": 5,
64
64
  "maxHistoryForDigest": 100
65
65
  },
@@ -14,12 +14,16 @@ Talk like a friend at dinner, not a brochure. If you wouldn't say it out loud to
14
14
 
15
15
  Confident, charming, magnetic. Never arrogant, weak, or desperate.
16
16
 
17
- - Confident: state things without hedging. No "maybe", no "possibly", no "könnte eventuell".
17
+ - Confident: state things without hedging. No "maybe", no "possibly".
18
18
  - Charming: light enough that people nod or smile, not feel lectured.
19
19
  - Magnetic: don't chase, don't beg, don't push.
20
20
 
21
21
  Avoid: lecturing (arrogant), hedging (weak), over-eager pushing (desperate).
22
22
 
23
+ ## Nuance
24
+
25
+ Super nuanced. See the layers in things. Most questions have a surface answer and a real answer. Give the real one. Notice tensions, trade-offs, and contradictions that others gloss over. When something is genuinely complicated, say so, but still take a position. Nuance doesn't mean wishy-washy. It means you see more and still commit.
26
+
23
27
  ## Rules
24
28
 
25
29
  - Name the elephant. If something obvious is awkward, say it first.
package/dist/cli/index.js CHANGED
@@ -60,6 +60,23 @@ program
60
60
  process.exit(1);
61
61
  }
62
62
  });
63
+ program
64
+ .command('update')
65
+ .alias('upgrade')
66
+ .description('Update heyamigo to the latest version')
67
+ .action(async () => {
68
+ const { execSync } = await import('child_process');
69
+ console.log('Updating @c4t4/heyamigo...');
70
+ try {
71
+ execSync('npm install @c4t4/heyamigo@latest', { stdio: 'inherit' });
72
+ console.log('\nUpdated. Restart the bot:');
73
+ console.log(' npx @c4t4/heyamigo restart');
74
+ }
75
+ catch {
76
+ console.error('Update failed. Try manually: npm install @c4t4/heyamigo@latest');
77
+ process.exit(1);
78
+ }
79
+ });
63
80
  program
64
81
  .command('dev')
65
82
  .description('Start in foreground with file watching (development)')
package/dist/cli/setup.js CHANGED
@@ -671,6 +671,9 @@ export async function runSetup() {
671
671
  'Import existing knowledge:',
672
672
  ' npx @c4t4/heyamigo import /path/to/folder',
673
673
  '',
674
+ 'Update to latest version:',
675
+ ' npx @c4t4/heyamigo update',
676
+ '',
674
677
  'Other commands:',
675
678
  ' npx @c4t4/heyamigo stop / restart / status',
676
679
  '',
@@ -692,5 +695,12 @@ export async function runSetup() {
692
695
  ' Step 5 — Mention the bot\'s name in the group to get a reply.\n\n' +
693
696
  ' Debugging:\n' +
694
697
  ' npx @c4t4/heyamigo logs');
698
+ p.log.info('TIP: Track your bot\'s memory with git.\n' +
699
+ 'The bot updates files in storage/memory/ over time. Use git to track changes and roll back if needed.\n\n' +
700
+ ' cd ' + cwd + '\n' +
701
+ ' git init\n' +
702
+ ' echo "storage/auth/" >> .gitignore\n' +
703
+ ' echo "storage/logs/" >> .gitignore\n' +
704
+ ' git add -A && git commit -m "initial setup"');
695
705
  p.outro('Happy chatting!');
696
706
  }
@@ -15,6 +15,8 @@ async function spawnDigester(prompt) {
15
15
  'json',
16
16
  '--model',
17
17
  config.claude.model,
18
+ '--permission-mode',
19
+ 'acceptEdits',
18
20
  ];
19
21
  const startedAt = Date.now();
20
22
  return new Promise((resolvePromise, rejectPromise) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@c4t4/heyamigo",
3
- "version": "0.1.5",
3
+ "version": "0.1.9",
4
4
  "description": "WhatsApp AI bot powered by Claude with long-term memory, browser control, and role-based access",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -36,6 +36,10 @@
36
36
  "bot",
37
37
  "anthropic"
38
38
  ],
39
+ "repository": {
40
+ "type": "git",
41
+ "url": "https://github.com/C4T4/heyamigo.git"
42
+ },
39
43
  "author": "Catalin Waack",
40
44
  "license": "MIT",
41
45
  "publishConfig": {