shadok-ai 0.13.7 → 0.13.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 +10 -0
- package/context/pilot-prompt.md +6 -0
- package/dist/server.js +8 -1
- package/dist/server.js.map +1 -1
- package/dist/telegram.d.ts +4 -1
- package/dist/telegram.js +40 -2
- package/dist/telegram.js.map +1 -1
- package/dist/whisper.d.ts +158 -0
- package/dist/whisper.js +353 -0
- package/dist/whisper.js.map +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -140,6 +140,16 @@ Enter to skip; you can add it later from the web UI).
|
|
|
140
140
|
- **Engine room** — the raw TUI screen, live, with clickable keys, for anything
|
|
141
141
|
the chat can't express. With tmux there is also an **experimental real
|
|
142
142
|
terminal** (xterm.js over the pane's byte stream) when a snapshot isn't enough.
|
|
143
|
+
- **Voice notes on Telegram** — send a voice message to an agent's topic and it
|
|
144
|
+
is transcribed locally, then acted on. What was understood is echoed back
|
|
145
|
+
first (`🎙 « … »`), so a misheard instruction is visible before it runs —
|
|
146
|
+
and the agent is told the words were **spoken**, so it asks about an odd
|
|
147
|
+
file name or branch instead of acting on a mishearing.
|
|
148
|
+
Transcription is installed **on first use** — a static ffmpeg, whisper.cpp and
|
|
149
|
+
a 181 MB model — and the topic says so rather than going quiet for minutes.
|
|
150
|
+
`SHADOK_WHISPER_MODEL` picks a bigger one if your recordings need it.
|
|
151
|
+
Set `SHADOK_WHISPER_DIR` to a directory shared between containers and one copy
|
|
152
|
+
serves them all.
|
|
143
153
|
- **Files an agent hands you** — when an agent's result IS a file (a report, an
|
|
144
154
|
export, a screenshot, an archive) it arrives as a download card in the chat,
|
|
145
155
|
inline if it is an image, and as an upload in the Telegram topic. It goes
|
package/context/pilot-prompt.md
CHANGED
|
@@ -23,6 +23,12 @@ Claude Code sessions in parallel. A human pilots you from a browser chat
|
|
|
23
23
|
Avoid very wide previews in the options.
|
|
24
24
|
- The user may be on a phone: conclusion first, compact responses, no long
|
|
25
25
|
tables where a list would do.
|
|
26
|
+
- **A message marked `vocal`** in its context header is the **transcription**
|
|
27
|
+
of something spoken, not text the human typed. Transcription mishears
|
|
28
|
+
homophones, proper nouns and technical terms. Read the intention rather than
|
|
29
|
+
the letter — and when something load-bearing looks garbled (a file name, a
|
|
30
|
+
branch, a command, a number), **ask instead of guessing**: acting on a
|
|
31
|
+
misheard instruction costs far more than one clarifying question.
|
|
26
32
|
- **Handing over a file.** The person reading you is in a browser or on
|
|
27
33
|
Telegram — **not on this machine**. A local path is a string they cannot open,
|
|
28
34
|
so when your result IS a file (a report, an export, a screenshot, an archive)
|
package/dist/server.js
CHANGED
|
@@ -3363,7 +3363,14 @@ wss.on("connection", (ws, req) => {
|
|
|
3363
3363
|
// speaking", so they get no header.
|
|
3364
3364
|
let submitText = text;
|
|
3365
3365
|
if (origin === "web" || origin === "telegram" || origin === "cli") {
|
|
3366
|
-
|
|
3366
|
+
// A transcribed voice note says so IN the platform field rather than
|
|
3367
|
+
// through a different `origin`: the gate just above matches the origin
|
|
3368
|
+
// EXACTLY, so an origin of "telegram vocal" would drop the header
|
|
3369
|
+
// entirely — losing the time and the sender to gain one word.
|
|
3370
|
+
// `parsePromptMeta` reads the platform as the first field and the
|
|
3371
|
+
// sender as everything past the time, so this widens neither.
|
|
3372
|
+
const platform = msg.voice === true ? `${origin} vocal` : origin;
|
|
3373
|
+
submitText = markPromptMeta(text, promptMetaHeader(platform, new Date(), author, defaultTimeZone()));
|
|
3367
3374
|
}
|
|
3368
3375
|
// Push the ledger DELTA ahead of the message: rows changed since this
|
|
3369
3376
|
// agent last saw the ledger, so it learns what siblings resolved /
|