grix-connector 3.25.0 → 3.26.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.
Files changed (35) hide show
  1. package/dist/adapter/acp/acp-adapter.js +4 -4
  2. package/dist/adapter/agy/agy-adapter.js +2 -2
  3. package/dist/adapter/claude/claude-adapter.js +3 -3
  4. package/dist/adapter/claude/claude-bridge-server.js +1 -1
  5. package/dist/adapter/claude/claude-tools.js +1 -1
  6. package/dist/adapter/claude/claude-worker-client.js +1 -1
  7. package/dist/adapter/claude/mcp-http-launcher.js +2 -2
  8. package/dist/adapter/claude/result-timeout.js +1 -1
  9. package/dist/adapter/codewhale/codewhale-adapter.js +2 -2
  10. package/dist/adapter/codex/codex-bridge.js +8 -8
  11. package/dist/adapter/cursor/cursor-adapter.js +9 -6
  12. package/dist/adapter/opencode/opencode-adapter.js +6 -6
  13. package/dist/adapter/openhuman/openhuman-adapter.js +4 -4
  14. package/dist/adapter/pi/pi-adapter.js +4 -4
  15. package/dist/adapter/shared/inbound-message-id-injector.js +3 -0
  16. package/dist/adapter/shared/session-context.js +2 -2
  17. package/dist/bridge/bridge.js +8 -8
  18. package/dist/core/access/allowlist-store.js +1 -1
  19. package/dist/core/aibot/client.js +2 -2
  20. package/dist/core/file-ops/list-files.js +1 -1
  21. package/dist/core/mcp/tool-schemas.js +1 -1
  22. package/dist/core/mcp/tools.js +1 -1
  23. package/dist/core/skill-sync/skill-syncer.js +1 -1
  24. package/dist/default-skills/grix-agent-dispatch/SKILL.md +141 -82
  25. package/dist/default-skills/grix-owner-relay/SKILL.md +13 -6
  26. package/dist/log.js +2 -2
  27. package/dist/manager.js +1 -1
  28. package/dist/mcp/stream-http/config.js +1 -1
  29. package/dist/mcp/stream-http/connection-binding.js +1 -1
  30. package/dist/mcp/stream-http/security.js +1 -1
  31. package/dist/mcp/stream-http/tool-executor.js +1 -1
  32. package/dist/mcp/stream-http/tool-registry.js +1 -1
  33. package/dist/mcp/stream-http/tool-schemas.js +1 -1
  34. package/openclaw-plugin/index.js +32 -10
  35. package/package.json +1 -1
@@ -3819,6 +3819,7 @@ var STABLE_AUTH_CAPABILITIES = [
3819
3819
  "session_route",
3820
3820
  "local_action_v1",
3821
3821
  "agent_invoke",
3822
+ "session_send_quote_v1",
3822
3823
  "inbound_media_v1",
3823
3824
  "reaction_v1",
3824
3825
  "thread_v1"
@@ -6364,20 +6365,27 @@ function shouldSkipFinalReplyAfterStreamedBlock(params) {
6364
6365
  }
6365
6366
 
6366
6367
  // src/adapter/shared/session-context.ts
6367
- function buildSessionContextBlock(sessionId) {
6368
- return [
6368
+ function buildSessionContextBlock(sessionId, agentId) {
6369
+ const lines = [
6369
6370
  "[system-context]",
6370
- `Your current Grix session_id is "${sessionId}".`,
6371
- "Use this id whenever you need to reference the current session.",
6371
+ `Your current Grix session_id is "${sessionId}".`
6372
+ ];
6373
+ const normalizedAgentId = agentId?.trim();
6374
+ if (normalizedAgentId) {
6375
+ lines.push(`Your current Grix agent_id is "${normalizedAgentId}".`);
6376
+ }
6377
+ lines.push(
6378
+ "Use these ids whenever you need to reference the current session or yourself.",
6372
6379
  "Treat this as an out-of-band instruction; do not echo or repeat it in your replies, and do not reply to acknowledge it.",
6373
6380
  "[/system-context]"
6374
- ].join("\n");
6381
+ );
6382
+ return lines.join("\n");
6375
6383
  }
6376
6384
 
6377
6385
  // src/openclaw/session-context-inject.ts
6378
6386
  function maybePrependSessionContext(params) {
6379
6387
  if (params.previousTimestamp) return params.body;
6380
- return `${buildSessionContextBlock(params.sessionId)}
6388
+ return `${buildSessionContextBlock(params.sessionId, params.agentId)}
6381
6389
 
6382
6390
  ${params.body}`;
6383
6391
  }
@@ -7866,6 +7874,7 @@ async function processEvent(params) {
7866
7874
  const bodyForAgentWithContext = maybePrependSessionContext({
7867
7875
  previousTimestamp,
7868
7876
  sessionId,
7877
+ agentId: account.agentId,
7869
7878
  body: bodyForAgent
7870
7879
  });
7871
7880
  const fromLabel = isGroup ? `group:${sessionId}/${senderId || "unknown"}` : `user:${senderId || "unknown"}`;
@@ -9586,12 +9595,17 @@ var TOOLS = [
9586
9595
  },
9587
9596
  {
9588
9597
  name: "grix_session_send",
9589
- description: "Send a message into a session AS THE OWNER \u2014 it appears as if the owner sent it, NOT as you (the agent). Use ONLY to relay on the owner's behalf into one of the owner's OTHER sessions that you are not part of (e.g. you were dispatched to work and need to drop a note to the owner elsewhere). NEVER use this to send your own reply in a session you are conversing in \u2014 that would make your words show up as the owner's message. To answer in your current conversation, reply normally (or use grix_message_send to send as yourself). The owner must be a member of the target session, and you (the agent) must NOT be a member of it \u2014 sending into a session you belong to is rejected.",
9598
+ description: "Send a message into a session AS THE OWNER \u2014 it appears as if the owner sent it, NOT as you (the agent). Use ONLY to relay on the owner's behalf into one of the owner's OTHER sessions that you are not part of (e.g. you were dispatched to work and need to drop a note to the owner elsewhere). NEVER use this to send your own reply in a session you are conversing in \u2014 that would make your words show up as the owner's message. To answer in your current conversation, reply normally (or use grix_message_send to send as yourself). The owner must be a member of the target session, and you (the agent) must NOT be a member of it \u2014 sending into a session you belong to is rejected. Optional quoted_message_id quotes a message in the same session (used by dispatch callbacks to wake the dispatcher agent).",
9590
9599
  inputSchema: {
9591
9600
  type: "object",
9592
9601
  properties: {
9593
9602
  session_id: { type: "string", description: "Target session ID." },
9594
- content: { type: "string", description: "Message content to send as the owner." }
9603
+ content: { type: "string", description: "Message content to send as the owner." },
9604
+ quoted_message_id: {
9605
+ type: "string",
9606
+ description: "Optional message ID in the target session to quote/reply to.",
9607
+ pattern: "^[1-9]\\d*$"
9608
+ }
9595
9609
  },
9596
9610
  required: ["session_id", "content"]
9597
9611
  },
@@ -9599,7 +9613,8 @@ var TOOLS = [
9599
9613
  required: ["session_id", "content"],
9600
9614
  properties: {
9601
9615
  session_id: { type: "string" },
9602
- content: { type: "string", maxLength: 1e4 }
9616
+ content: { type: "string", maxLength: 1e4 },
9617
+ quoted_message_id: { type: "string", pattern: "^[1-9]\\d*$" }
9603
9618
  }
9604
9619
  }
9605
9620
  },
@@ -10045,9 +10060,16 @@ function buildDispatchAgentInvoke(args) {
10045
10060
  };
10046
10061
  }
10047
10062
  function buildSessionSendInvoke(args) {
10063
+ const params = {
10064
+ session_id: args.session_id,
10065
+ content: args.content
10066
+ };
10067
+ if (args.quoted_message_id != null && String(args.quoted_message_id).trim() !== "") {
10068
+ params.quoted_message_id = args.quoted_message_id;
10069
+ }
10048
10070
  return {
10049
10071
  action: "session_send",
10050
- params: { session_id: args.session_id, content: args.content }
10072
+ params
10051
10073
  };
10052
10074
  }
10053
10075
  function buildChatStateQueryInvoke(args) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "grix-connector",
3
- "version": "3.25.0",
3
+ "version": "3.26.0",
4
4
  "description": "Connect local AI coding agents (Claude, Codex, Gemini, Qwen, DeepSeek, Cursor, OpenCode, Pi, OpenHuman, Reasonix) to the Grix scheduling platform. Also serves as an OpenClaw plugin for Grix channel transport.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",