@kl-c/matrixos 0.3.18 → 0.3.20

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/dist/cli/index.js CHANGED
@@ -2163,7 +2163,7 @@ var package_default;
2163
2163
  var init_package = __esm(() => {
2164
2164
  package_default = {
2165
2165
  name: "@kl-c/matrixos",
2166
- version: "0.3.18",
2166
+ version: "0.3.20",
2167
2167
  description: "MaTrixOS \u2014 Agentic OS for OpenCode. Personalizable, communicating, self-improving, resilient.",
2168
2168
  main: "./dist/index.js",
2169
2169
  types: "dist/index.d.ts",
@@ -84952,6 +84952,12 @@ class MatrixGateway {
84952
84952
  }
84953
84953
  return adapter.send(env2);
84954
84954
  }
84955
+ async sendTyping(env2) {
84956
+ const adapter = this.adapters.get(env2.channel);
84957
+ if (adapter?.sendTyping && env2.recipient?.id) {
84958
+ await adapter.sendTyping(env2.recipient.id);
84959
+ }
84960
+ }
84955
84961
  async handleInbound(env2) {
84956
84962
  if (this.seenIds.has(env2.id)) {
84957
84963
  return;
@@ -84991,6 +84997,9 @@ class MatrixGateway {
84991
84997
  return;
84992
84998
  }
84993
84999
  if (this.handler) {
85000
+ if (env2.content.type === "text") {
85001
+ this.sendTyping(env2).catch(() => {});
85002
+ }
84994
85003
  await this.handler(env2);
84995
85004
  }
84996
85005
  this.audit({
@@ -90566,6 +90575,13 @@ class TelegramAdapter {
90566
90575
  throw new TelegramSendError(`Failed to send Telegram message: ${err instanceof Error ? err.message : String(err)}`, { cause: err });
90567
90576
  }
90568
90577
  }
90578
+ async sendTyping(chatId) {
90579
+ try {
90580
+ await this.bot.api.sendChatAction(chatId, "typing");
90581
+ } catch (err) {
90582
+ console.warn(`[telegram] sendTyping failed: ${err instanceof Error ? err.message : String(err)}`);
90583
+ }
90584
+ }
90569
90585
  async editMessage(recipientId, messageId, text) {
90570
90586
  try {
90571
90587
  await this.bot.api.editMessageText(recipientId, Number(messageId), text);
@@ -177279,7 +177295,8 @@ async function run(options) {
177279
177295
  if (!(error51 instanceof Error)) {}
177280
177296
  }
177281
177297
  try {
177282
- const resolvedModel = resolveRunModel(options.model);
177298
+ const configModel = pluginConfig.agents?.[resolvedAgent]?.model;
177299
+ const resolvedModel = resolveRunModel(options.model ?? configModel);
177283
177300
  const { client: client3, cleanup: serverCleanup } = await createServerConnection({
177284
177301
  port: options.port,
177285
177302
  attach: options.attach,
@@ -2163,7 +2163,7 @@ var package_default;
2163
2163
  var init_package = __esm(() => {
2164
2164
  package_default = {
2165
2165
  name: "@kl-c/matrixos",
2166
- version: "0.3.18",
2166
+ version: "0.3.20",
2167
2167
  description: "MaTrixOS \u2014 Agentic OS for OpenCode. Personalizable, communicating, self-improving, resilient.",
2168
2168
  main: "./dist/index.js",
2169
2169
  types: "dist/index.d.ts",
@@ -85007,6 +85007,12 @@ class MatrixGateway {
85007
85007
  }
85008
85008
  return adapter.send(env2);
85009
85009
  }
85010
+ async sendTyping(env2) {
85011
+ const adapter = this.adapters.get(env2.channel);
85012
+ if (adapter?.sendTyping && env2.recipient?.id) {
85013
+ await adapter.sendTyping(env2.recipient.id);
85014
+ }
85015
+ }
85010
85016
  async handleInbound(env2) {
85011
85017
  if (this.seenIds.has(env2.id)) {
85012
85018
  return;
@@ -85046,6 +85052,9 @@ class MatrixGateway {
85046
85052
  return;
85047
85053
  }
85048
85054
  if (this.handler) {
85055
+ if (env2.content.type === "text") {
85056
+ this.sendTyping(env2).catch(() => {});
85057
+ }
85049
85058
  await this.handler(env2);
85050
85059
  }
85051
85060
  this.audit({
@@ -90621,6 +90630,13 @@ class TelegramAdapter {
90621
90630
  throw new TelegramSendError(`Failed to send Telegram message: ${err instanceof Error ? err.message : String(err)}`, { cause: err });
90622
90631
  }
90623
90632
  }
90633
+ async sendTyping(chatId) {
90634
+ try {
90635
+ await this.bot.api.sendChatAction(chatId, "typing");
90636
+ } catch (err) {
90637
+ console.warn(`[telegram] sendTyping failed: ${err instanceof Error ? err.message : String(err)}`);
90638
+ }
90639
+ }
90624
90640
  async editMessage(recipientId, messageId, text) {
90625
90641
  try {
90626
90642
  await this.bot.api.editMessageText(recipientId, Number(messageId), text);
@@ -177334,7 +177350,8 @@ async function run(options) {
177334
177350
  if (!(error51 instanceof Error)) {}
177335
177351
  }
177336
177352
  try {
177337
- const resolvedModel = resolveRunModel(options.model);
177353
+ const configModel = pluginConfig.agents?.[resolvedAgent]?.model;
177354
+ const resolvedModel = resolveRunModel(options.model ?? configModel);
177338
177355
  const { client: client3, cleanup: serverCleanup } = await createServerConnection({
177339
177356
  port: options.port,
177340
177357
  attach: options.attach,
package/dist/index.js CHANGED
@@ -368019,7 +368019,7 @@ function getCachedVersion(options = {}) {
368019
368019
  // package.json
368020
368020
  var package_default = {
368021
368021
  name: "@kl-c/matrixos",
368022
- version: "0.3.18",
368022
+ version: "0.3.20",
368023
368023
  description: "MaTrixOS \u2014 Agentic OS for OpenCode. Personalizable, communicating, self-improving, resilient.",
368024
368024
  main: "./dist/index.js",
368025
368025
  types: "dist/index.d.ts",
@@ -443311,6 +443311,12 @@ class MatrixGateway {
443311
443311
  }
443312
443312
  return adapter.send(env2);
443313
443313
  }
443314
+ async sendTyping(env2) {
443315
+ const adapter = this.adapters.get(env2.channel);
443316
+ if (adapter?.sendTyping && env2.recipient?.id) {
443317
+ await adapter.sendTyping(env2.recipient.id);
443318
+ }
443319
+ }
443314
443320
  async handleInbound(env2) {
443315
443321
  if (this.seenIds.has(env2.id)) {
443316
443322
  return;
@@ -443350,6 +443356,9 @@ class MatrixGateway {
443350
443356
  return;
443351
443357
  }
443352
443358
  if (this.handler) {
443359
+ if (env2.content.type === "text") {
443360
+ this.sendTyping(env2).catch(() => {});
443361
+ }
443353
443362
  await this.handler(env2);
443354
443363
  }
443355
443364
  this.audit({
@@ -443574,6 +443583,13 @@ class TelegramAdapter {
443574
443583
  throw new TelegramSendError(`Failed to send Telegram message: ${err instanceof Error ? err.message : String(err)}`, { cause: err });
443575
443584
  }
443576
443585
  }
443586
+ async sendTyping(chatId) {
443587
+ try {
443588
+ await this.bot.api.sendChatAction(chatId, "typing");
443589
+ } catch (err) {
443590
+ console.warn(`[telegram] sendTyping failed: ${err instanceof Error ? err.message : String(err)}`);
443591
+ }
443592
+ }
443577
443593
  async editMessage(recipientId, messageId, text) {
443578
443594
  try {
443579
443595
  await this.bot.api.editMessageText(recipientId, Number(messageId), text);
package/dist/tui.js CHANGED
@@ -20762,6 +20762,12 @@ class MatrixGateway {
20762
20762
  }
20763
20763
  return adapter.send(env2);
20764
20764
  }
20765
+ async sendTyping(env2) {
20766
+ const adapter = this.adapters.get(env2.channel);
20767
+ if (adapter?.sendTyping && env2.recipient?.id) {
20768
+ await adapter.sendTyping(env2.recipient.id);
20769
+ }
20770
+ }
20765
20771
  async handleInbound(env2) {
20766
20772
  if (this.seenIds.has(env2.id)) {
20767
20773
  return;
@@ -20801,6 +20807,9 @@ class MatrixGateway {
20801
20807
  return;
20802
20808
  }
20803
20809
  if (this.handler) {
20810
+ if (env2.content.type === "text") {
20811
+ this.sendTyping(env2).catch(() => {});
20812
+ }
20804
20813
  await this.handler(env2);
20805
20814
  }
20806
20815
  this.audit({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kl-c/matrixos",
3
- "version": "0.3.18",
3
+ "version": "0.3.20",
4
4
  "description": "MaTrixOS \u2014 Agentic OS for OpenCode. Personalizable, communicating, self-improving, resilient.",
5
5
  "main": "./dist/index.js",
6
6
  "types": "dist/index.d.ts",