Commit Graph

44 Commits

Author SHA1 Message Date
Peter Steinberger
78646030f4 Auto-reply: show tool results before main reply in verbose mode 2025-12-03 09:14:10 +00:00
Peter Steinberger
4c6bef34cf Chore: format + lint fixes 2025-12-03 09:09:34 +00:00
Peter Steinberger
ffd14dc6c6 Auto-reply: add verbose session hint 2025-12-03 09:07:17 +00:00
Peter Steinberger
e33c7a813d Auto-reply: add /verbose directives and tool result replies 2025-12-03 09:04:37 +00:00
Peter Steinberger
ddf5cc12c2 Auto-reply: treat prefixed think directives as directive-only 2025-12-03 08:57:30 +00:00
Peter Steinberger
e5fff1d374 Auto-reply: ack think directives 2025-12-03 08:54:38 +00:00
Peter Steinberger
ff6d832151 Auto-reply: add thinking directives 2025-12-03 08:45:23 +00:00
Joao Lisboa
24bc88b638 chore: user-agnostic Claude identity and tests
- Use ~/Clawd instead of hardcoded /Users/steipete/clawd
- Add MEDIA: syntax instructions to identity prefix
- Update tests to check for 'scratchpad' instead of specific path

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-02 21:07:13 +00:00
Peter Steinberger
2a2b662c3e perf(pi): reuse tau rpc for command auto-replies 2025-12-02 20:09:51 +00:00
Peter Steinberger
d61e641496 Agents: add pluggable CLIs
Co-authored-by: RealSid08 <RealSid08@users.noreply.github.com>
2025-12-02 11:07:46 +00:00
Peter Steinberger
9f1c2169eb Fix test isolation to prevent loading real user config
Tests were picking up real ~/.warelay/warelay.json with emojis and
prefixes (like "🦞"), causing test assertions to fail. Added proper
config mocks to all test files.

Changes:
- Mock loadConfig() in index.core.test.ts, inbound.media.test.ts,
  monitor-inbox.test.ts
- Update test-helpers.ts default mock to disable all prefixes
- Tests now use clean config: no messagePrefix, no responsePrefix,
  no timestamp, allowFrom=["*"]

This ensures tests validate core behavior without user-specific config.
The responsePrefix feature itself is already fully config-driven - this
only fixes test isolation.
2025-11-30 18:00:57 +00:00
Peter Steinberger
a7b6914a64 feat: same-phone mode with echo detection and configurable marker
Adds full support for self-messaging setups where you chat with yourself
and an AI assistant replies in the same WhatsApp bubble.

Changes:
- Same-phone mode (from === to) always allowed, bypasses allowFrom check
- Echo detection via bounded Set (max 100) prevents infinite loops
- Configurable samePhoneMarker in config (default: "[same-phone]")
- Messages prefixed with marker so assistants know the context
- fromMe filter removed from inbound.ts (echo detection in auto-reply)
- Verbose logging for same-phone detection and echo skips

Tests:
- Same-phone allowed without/despite allowFrom configuration
- Body prefixed only when from === to
- Non-same-phone rejected when not in allowFrom
2025-11-29 04:52:21 +00:00
Peter Steinberger
00cd24e7e5 web: add heartbeat and bounded reconnect tuning 2025-11-26 02:34:43 +01:00
Peter Steinberger
9fa3cbab8a chore: format to 2-space and bump changelog 2025-11-26 00:53:53 +01:00
Peter Steinberger
f51ca895a0 chore: format + lint 2025-11-26 00:30:30 +01:00
Peter Steinberger
1eee9d9f2e style: normalize indentation to 2 spaces 2025-11-26 00:15:10 +01:00
Peter Steinberger
e429e873a4 docs/tests: typing interval docs and coverage 2025-11-26 00:10:38 +01:00
Peter Steinberger
41dc5ed5eb feat: keep typing indicators alive during commands 2025-11-26 00:05:11 +01:00
Peter Steinberger
c08dd4bbd4 test: cover sendSystemOnce default 2025-11-25 23:57:41 +01:00
Peter Steinberger
1dfc2ccf6e feat: send session prompt once 2025-11-25 23:52:38 +01:00
Peter Steinberger
918ca94df8 feat: support audio/video/doc media caps and transcript context 2025-11-25 23:21:35 +01:00
Peter Steinberger
ecf0986fe4 feat: transcribe audio and surface transcript to prompts 2025-11-25 23:13:22 +01:00
Peter Steinberger
9b8bcf36c3 feat: optional audio transcription via CLI 2025-11-25 23:06:54 +01:00
Peter Steinberger
7dc5681102 Auto-reply: send timeout fallback and tests 2025-11-25 17:52:57 +01:00
Peter Steinberger
d219526d97 test: sync updated specs 2025-11-25 12:12:29 +01:00
Peter Steinberger
1cad440404 claude: tell Clawd to use ~/clawd markdown scratchpad 2025-11-25 06:49:10 +01:00
Peter Steinberger
184781b85d claude: prefix prompt with Clawd identity 2025-11-25 06:41:27 +01:00
Peter Steinberger
018c0fab6d auto-reply: handle empty stdout gracefully 2025-11-25 06:33:49 +01:00
Peter Steinberger
3e4cf4ee03 fix: strip trailing punctuation from MEDIA tokens and add tests 2025-11-25 06:07:11 +01:00
Peter Steinberger
8e499e807e test: cover MEDIA backticks and web media fallback logging 2025-11-25 06:04:41 +01:00
Peter Steinberger
60e9344c2a refactor: extract MEDIA parsing helper and tidy whitespace 2025-11-25 05:49:18 +01:00
Peter Steinberger
b33f4e710a fix: handle inline MEDIA tokens and host webhook media 2025-11-25 05:47:12 +01:00
Peter Steinberger
ccacfcc223 fix: accept file/media tokens safely and improve web media send 2025-11-25 05:34:08 +01:00
Peter Steinberger
3069bd5c0e fix: harden MEDIA parsing and add tests 2025-11-25 05:25:57 +01:00
Peter Steinberger
7aee77be2b test: cover media url extraction from command stdout 2025-11-25 05:21:59 +01:00
Peter Steinberger
0bcb3b404d chore: surface media URL in command prompts and tests 2025-11-25 05:20:50 +01:00
Peter Steinberger
b878d51488 feat: download inbound media and expose to templating 2025-11-25 05:17:59 +01:00
Peter Steinberger
0bd9c5f5c7 feat: add image support across web and twilio 2025-11-25 04:58:31 +01:00
Peter Steinberger
d580c7669c feat: serialize command auto-replies with queue 2025-11-25 04:40:49 +01:00
Peter Steinberger
b8c813ddeb chore: logger cleanup and test fixes 2025-11-25 04:05:02 +01:00
Peter Steinberger
7ec3e5a106 Parse Claude JSON output to return text replies 2025-11-25 01:41:52 +01:00
Peter Steinberger
75407bba0a Ignore coverage output and document Claude text mode 2025-11-25 01:38:43 +01:00
Peter Steinberger
f910653624 Fix provider-web mocks and make tests green 2025-11-25 00:16:01 +01:00
Peter Steinberger
9a2c3fa2d7 Fix lint warnings and tighten test mocks 2025-11-25 00:10:34 +01:00