@kwirthmagnify/kwirth-common-ai 0.5.55 → 0.5.56

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/back.d.ts CHANGED
@@ -79,10 +79,20 @@ export interface IMetricsCapability {
79
79
  /** Muestras de metricas que el core mantiene en memoria. */
80
80
  samples: unknown[];
81
81
  }
82
+ /**
83
+ * Un elemento del buffer de eventos del core: el tipo de cambio y el objeto tal y como vino de la API.
84
+ * `obj` se deja generico a proposito —ahi caben Events de kube y objetos de cualquier kind— pero tipado
85
+ * como objeto, no como `any`: quien lo lea tiene que mirar el `kind` antes de creerse nada.
86
+ */
87
+ export interface IClusterEvent {
88
+ /** ADDED | MODIFIED | DELETED para cambios de objeto; los Event de kube tambien viajan aqui. */
89
+ type?: string;
90
+ obj?: Record<string, any>;
91
+ }
82
92
  /** Eventos recientes del cluster (`ECapability.EVENTS`). */
83
93
  export interface IEventsCapability {
84
- /** Buffer de eventos ({type, obj}) que el core va acumulando. */
85
- recent: unknown[];
94
+ /** Buffer que el core va acumulando. El mas reciente, al final. */
95
+ recent: IClusterEvent[];
86
96
  }
87
97
  /** Credenciales de repositorios fuente (`ECapability.REPOS`). */
88
98
  export interface IReposCapability {
package/dist/back.js CHANGED
@@ -459,7 +459,7 @@ const buildToolHost = (requires, context) => {
459
459
  if (requires.includes(index_1.ECapability.METRICS))
460
460
  host.metrics = { samples: (_a = context.clusterMetrics) !== null && _a !== void 0 ? _a : [] };
461
461
  if (requires.includes(index_1.ECapability.EVENTS))
462
- host.events = { recent: (_b = context.clusterEvents) !== null && _b !== void 0 ? _b : [] };
462
+ host.events = { recent: ((_b = context.clusterEvents) !== null && _b !== void 0 ? _b : []) };
463
463
  if (requires.includes(index_1.ECapability.REPOS))
464
464
  host.repos = { creds: (_c = context.sourceRepos) !== null && _c !== void 0 ? _c : [] };
465
465
  return host;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kwirthmagnify/kwirth-common-ai",
3
- "version": "0.5.55",
3
+ "version": "0.5.56",
4
4
  "description": "Shared AI/LLM types and utilities for Kwirth AI plugins",
5
5
  "scripts": {
6
6
  "build": "del .\\dist\\* /s /q 2>nul & tsc",