jeopi-cli 16.6.9 → 16.6.12
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/CHANGELOG.md +28 -0
- package/README.md +34 -9
- package/dist/cli.js +3492 -3483
- package/dist/types/main.d.ts +1 -1
- package/dist/types/messenger/artifacts.d.ts +12 -0
- package/dist/types/messenger/live-session.d.ts +32 -0
- package/dist/types/messenger/types.d.ts +10 -0
- package/dist/types/modes/interactive-mode.d.ts +2 -0
- package/dist/types/modes/session-teardown.d.ts +13 -8
- package/dist/types/modes/types.d.ts +2 -0
- package/dist/types/session/agent-session.d.ts +3 -1
- package/package.json +12 -12
- package/src/config/model-registry.ts +50 -17
- package/src/internal-urls/docs-index.generated.txt +1 -1
- package/src/main.ts +12 -2
- package/src/messenger/artifacts.ts +167 -0
- package/src/messenger/config.ts +14 -2
- package/src/messenger/discord.ts +272 -22
- package/src/messenger/gateway.ts +53 -7
- package/src/messenger/http.ts +1 -0
- package/src/messenger/live-session.ts +502 -0
- package/src/messenger/session.ts +8 -1
- package/src/messenger/types.ts +10 -0
- package/src/modes/controllers/input-controller.ts +26 -4
- package/src/modes/interactive-mode.ts +31 -7
- package/src/modes/session-teardown.test.ts +61 -0
- package/src/modes/session-teardown.ts +20 -8
- package/src/modes/types.ts +2 -0
- package/src/prompts/system/messenger-artifacts.md +4 -0
- package/src/sdk.ts +12 -5
- package/src/session/agent-session.ts +14 -10
- package/src/slash-commands/builtin-registry.ts +127 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,34 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [16.6.12] - 2026-10-29
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
|
|
9
|
+
- Added explicitly opted-in local response relay with `/discord relay <allowed-channel-id|off>`; the destination resets when the bridge stops or the session changes.
|
|
10
|
+
- Discord server-channel requests now use threads, report progress with reactions, and send long replies in ordered chunks with bounded rate-limit retries.
|
|
11
|
+
- Added opt-in Discord attachment staging and file delivery via `platforms.discord.artifactDir`; see the [file workflow and security limits](../../docs/messenger/discord.md#discord-file-workflow).
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
|
|
15
|
+
- The interactive Discord bridge supports `/discord status` and uses the host session's tools and approval policy; see the [security guidance](./README.md#interactive-discord-bridge-and-local-relay).
|
|
16
|
+
|
|
17
|
+
## [16.6.11] - 2026-10-28
|
|
18
|
+
|
|
19
|
+
### Added
|
|
20
|
+
|
|
21
|
+
- Added `/discord live <configPath> --allow-full-control` command to attach an authorized Discord channel directly to an active interactive session without running a standalone `messenger` gateway. The bridge loads a private `messenger.json` config, reuses the Discord platform setup, maintains per-channel-per-user conversation history, and terminates with `/discord stop`. Full documentation in `docs/messenger/discord.md`.
|
|
22
|
+
|
|
23
|
+
### Fixed
|
|
24
|
+
|
|
25
|
+
- Fall back to the base `google-antigravity` provider cache key during synchronous `ModelRegistry` startup when unauthenticated rather than deriving a pseudo-scoped cache key from an opaque identity hash.
|
|
26
|
+
|
|
27
|
+
## [16.6.10] - 2026-10-25
|
|
28
|
+
|
|
29
|
+
### Fixed
|
|
30
|
+
|
|
31
|
+
- Resolve account-scoped `google-antigravity` discovery cache keys during synchronous `ModelRegistry` startup and static reloads, and include `google-antigravity` and `openai-codex` in authoritative runtime catalog providers so cached `gemini-4-argon-*` models are immediately available at startup and are not overwritten when other providers (`anthropic`, `openai-codex`) refresh.
|
|
32
|
+
|
|
5
33
|
## [16.6.9] - 2026-10-17
|
|
6
34
|
|
|
7
35
|
### Fixed
|
package/README.md
CHANGED
|
@@ -15,7 +15,7 @@ Package-specific references:
|
|
|
15
15
|
|
|
16
16
|
## Messenger gateway
|
|
17
17
|
|
|
18
|
-
`jeopi messenger` connects authorized Discord, Telegram, and Slack bots to headless agent sessions for bidirectional
|
|
18
|
+
`jeopi messenger` connects authorized Discord, Telegram, and Slack bots to headless agent sessions for bidirectional conversations. Discord optionally supports file attachments as described in the [Discord guide](../../docs/messenger/discord.md#discord-file-workflow). Discord Gateway and Slack Socket Mode use outbound WebSockets; Telegram uses outbound long polling. No public HTTP ingress, webhook endpoint, or tunnel is required. Configure a working jeopi model/provider first using the [main setup guide](../../README.md).
|
|
19
19
|
|
|
20
20
|
### Configuration and CLI
|
|
21
21
|
|
|
@@ -71,8 +71,11 @@ jeopi messenger run --config /absolute/private/path/messenger.json
|
|
|
71
71
|
|
|
72
72
|
1. Create an application with a bot user; store the **bot token**, not a user token or client secret, as `JEOPI_DISCORD_BOT_TOKEN`.
|
|
73
73
|
2. In the Bot settings, enable the privileged **Message Content Intent** (obtain approval if Discord requires it for your app). The adapter requests `GUILD_MESSAGES`, `DIRECT_MESSAGES`, and `MESSAGE_CONTENT`; it does not request member or presence intents.
|
|
74
|
-
3. Install/invite the bot
|
|
75
|
-
4. Enable Developer Mode in Discord's Advanced settings, then use **Copy User ID** for each authorized human and **Copy Channel ID** for each allowed channel/DM.
|
|
74
|
+
3. Install/invite the bot with the `bot` scope and **View Channels**, **Send Messages**, and **Read Message History**. For server-channel requests, also grant **Create Public Threads**, **Send Messages in Threads**, **Add Reactions**, and **Attach Files** in the intended channels; existing threads must be accessible to the bot. Attach Files is needed for exact copies when Discord would strip boundary whitespace. Administrator permission is not required.
|
|
75
|
+
4. Enable Developer Mode in Discord's Advanced settings, then use **Copy User ID** for each authorized human and **Copy Channel ID** for each allowed channel/DM. Use exact numeric IDs as strings. Allowing a parent channel permits authorized requests in its threads; a thread ID can also be allowed directly. Users must be able to DM the bot under their Discord privacy settings.
|
|
76
|
+
5. Mention the bot for a server-channel request: it creates a thread for that request. A request in an existing thread stays there; DMs remain direct. The original sender can continue without mentioning the bot in a bot-created thread while its in-memory mapping survives; restart or eviction loses that association. Explicitly mention the bot in other thread requests. Progress reactions are best-effort: ⏳ while processing, then ✅ or ❌.
|
|
77
|
+
|
|
78
|
+
For Discord file exchange, explicitly configure `platforms.discord.artifactDir` as a pre-existing private staging directory and enable the needed host tools; see the [file workflow and limits](../../docs/messenger/discord.md#discord-file-workflow). The gateway reuses the configured model/provider authentication; attachments and tool results may be sent to that provider. Created server threads are public to people who can view the channel, not just allowlisted users.
|
|
76
79
|
|
|
77
80
|
**Slack** ([Socket Mode setup](https://docs.slack.dev/apis/events-api/using-socket-mode/), [app settings](https://api.slack.com/apps)):
|
|
78
81
|
|
|
@@ -81,17 +84,39 @@ jeopi messenger run --config /absolute/private/path/messenger.json
|
|
|
81
84
|
3. Enable Event Subscriptions and subscribe to bot events `message.im` and `app_mention`. Socket Mode needs no Request URL. Enable App Home's Messages tab and allow users to send messages to the app for DMs.
|
|
82
85
|
4. Invite the bot to each allowed channel with `/invite @YourBot`. Copy each human's **Member ID** from their profile menu into `allowedUserIds`. Copy the channel ID from channel details, or the DM conversation ID from its Slack link (`D...`), into `allowedChannelIds`; use IDs, not display names. Channel requests must mention the bot and replies remain in their thread.
|
|
83
86
|
|
|
87
|
+
### Interactive Discord bridge and local relay
|
|
88
|
+
|
|
89
|
+
In an interactive jeopi session, start the bridge with the private configuration above (Discord must be configured):
|
|
90
|
+
|
|
91
|
+
```text
|
|
92
|
+
/discord live /absolute/private/path/messenger.json --allow-full-control
|
|
93
|
+
/discord status
|
|
94
|
+
/discord stop
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
**Full control is dangerous:** authorized Discord users prompt the active local session, with its active tools, provider authentication, and approval policy, rather than the isolated headless gateway's `toolNames` restrictions. They may read or modify local data or execute commands according to that policy. This is not a sandbox; use a dedicated account and workspace, restrict both allowlists, and do not expose secrets. Other members who can view a destination can see messages and files posted there. Stopping the bridge prevents new remote requests but cannot undo an already-started host action or retract delivered content.
|
|
98
|
+
|
|
99
|
+
Local responses are not relayed by default. To explicitly opt in, add the exact destination channel or thread ID to Discord's `allowedChannelIds`, then run:
|
|
100
|
+
|
|
101
|
+
```text
|
|
102
|
+
/discord relay <allowed-channel-id>
|
|
103
|
+
/discord status
|
|
104
|
+
/discord relay off
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Relay sends the final assistant text from eligible successful, directly submitted idle local turns, including expanded prompts, not the local prompt. Queued, conflicting, aborted, or remote turns are not relayed; a turn may be skipped with a warning if it cannot be safely identified. Relay is disabled on stop, session change, or gateway exit and must be enabled again. Delivery can fail or be partial; it is not a durable outbox.
|
|
108
|
+
|
|
84
109
|
### Security boundaries and limits
|
|
85
110
|
|
|
86
|
-
- Every configured platform requires a nonempty `allowedUserIds` list of exact IDs; wildcards are rejected. Optional `allowedChannelIds` further restricts channels **including DMs**; if supplied it must be nonempty. Omitting it permits that platform's allowed users in any reachable channel,
|
|
87
|
-
-
|
|
111
|
+
- Every configured platform requires a nonempty `allowedUserIds` list of exact IDs; wildcards are rejected. Optional `allowedChannelIds` further restricts channels **including DMs**; if supplied it must be nonempty. Omitting it permits that platform's allowed users in any reachable channel, subject to the mention rules described above.
|
|
112
|
+
- Headless gateway conversation history is isolated by platform, bot/workspace identity, channel, thread/topic where applicable, and **sender**, with `cwd` included in the persisted route. This is history separation, not access control over messages visible to other members of a group or over local files. The interactive bridge instead uses the active local session.
|
|
88
113
|
- Keep configuration, workspace, and session storage under a dedicated private directory/account. Session directories/files are restricted to modes `0700`/`0600`; transcripts persist on disk and are not encrypted by this feature. Authorized prompts and enabled-tool results can reach your configured model provider and replies go back to the originating chat. Never use a sensitive personal workspace for remote prompts.
|
|
89
|
-
- `toolNames` defaults to `[]`, so remote sessions have no tools. They do not load workspace context files, skills, rules, prompt templates, custom tools, extension discovery, MCP, or LSP. Slash-looking input, including `/new`, is ordinary user text; there is no remote session-management command surface.
|
|
90
|
-
- **Dangerous opt-in:** the entire supported local-tool list is `"toolNames": ["read", "grep", "glob", "bash", "edit", "write"]`. Enable only the subset you deliberately authorize, never by default. Selected tools are allowed without per-call interactive approval: even read/search tools can disclose local data, and shell/write tools grant local execution/modification authority. `cwd` is not a filesystem jail. This is **not a sandbox**; isolate the OS account/container and its credentials before granting remote users tools.
|
|
114
|
+
- For the headless gateway, `toolNames` defaults to `[]`, so remote sessions have no tools. They do not load workspace context files, skills, rules, prompt templates, custom tools, extension discovery, MCP, or LSP. Slash-looking input, including `/new`, is ordinary user text; there is no remote session-management command surface.
|
|
115
|
+
- **Dangerous gateway opt-in:** the entire supported local-tool list is `"toolNames": ["read", "grep", "glob", "bash", "edit", "write"]`. Enable only the subset you deliberately authorize, never by default. Selected tools are allowed without per-call interactive approval: even read/search tools can disclose local data, and shell/write tools grant local execution/modification authority. `cwd` is not a filesystem jail. This is **not a sandbox**; isolate the OS account/container and its credentials before granting remote users tools.
|
|
91
116
|
- Incoming text is limited to 32,000 UTF-16 units. Turns are serialized across platforms with at most 100 pending messages; excess messages are dropped. Deduplication and transport cursors are in memory, not a durable delivery queue. Reconnects retry transient failures, but fatal authentication/configuration errors stop the gateway; restart after correcting them. Do not assume exactly-once processing or recovery of every message after an outage.
|
|
92
|
-
- Replies are split into provider-sized text chunks (Discord 2,000, Telegram 4,096, Slack 4,000 UTF-16 units). Slack spaces chunks;
|
|
117
|
+
- Replies are split into provider-sized text chunks (Discord 2,000, Telegram 4,096, Slack 4,000 UTF-16 units). Discord sends chunks sequentially and retries the current chunk on rate limits; Slack spaces chunks. Discord may add invisible U+200B characters around unavoidable whitespace boundaries to prevent Discord from stripping that whitespace. When it does, it also sends the original response as `response.txt` for exact UTF-8 copying; this requires attachment permission and is subject to Discord upload limits. There is no general outbound rate-limit scheduler or durable retry/outbox. Failed sends are not automatically replayed and a multi-chunk reply can be partial. Check provider limits and connectivity before manually retrying a request that may already have run tools.
|
|
93
118
|
|
|
94
|
-
These are native jeopi transports, informed by Aside's bundled `~/.aside/u/0/skills/builtin/channel/SKILL.md` context/reply model and [Hermes Agent gateway architecture at `040b6df2c40b0f4f88f51e4c2062eafc4d7463c5`](https://github.com/NousResearch/hermes-agent/tree/040b6df2c40b0f4f88f51e4c2062eafc4d7463c5), **not full ports**. Aside's moderation/history/reaction tools and Hermes media support are not included.
|
|
119
|
+
These are native jeopi transports, informed by Aside's bundled `~/.aside/u/0/skills/builtin/channel/SKILL.md` context/reply model and [Hermes Agent gateway architecture at `040b6df2c40b0f4f88f51e4c2062eafc4d7463c5`](https://github.com/NousResearch/hermes-agent/tree/040b6df2c40b0f4f88f51e4c2062eafc4d7463c5), **not full ports**. Aside's moderation/history/reaction tools and Hermes media support are not included. Incoming attachments, image/audio/video processing, and general media uploads are not supported; Discord's exact-text attachment is the exception described above.
|
|
95
120
|
|
|
96
121
|
### Detailed Guides and Agent Skill
|
|
97
122
|
|