@melaya/runner 1.0.29 → 1.0.30

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.
@@ -117,38 +117,35 @@ export async function connect(opts) {
117
117
  // Surface bootstrap progress to the FE so the launching
118
118
  // animation reflects the real state instead of staying on a
119
119
  // generic spinner during the 1-2 min first-time install.
120
+ // FLAT shape — server reads payload.run_id at top level
121
+ // (runnerNamespace.ts:202). My earlier nested {runId, payload:{}}
122
+ // shape was silently dropped by `if (!runId) return`.
120
123
  socket.emit("runner:event", {
121
- runId: payload.runId,
122
- payload: {
123
- event_type: "pipeline_phase",
124
- run_id: payload.runId,
125
- project: payload.project,
126
- step: 1,
127
- total: 5,
128
- label: `venv: ${msg}`,
129
- status: "started",
130
- },
124
+ run_id: payload.runId,
125
+ event_type: "pipeline_phase",
126
+ project: payload.project,
127
+ step: 1,
128
+ total: 5,
129
+ label: `venv: ${msg}`,
130
+ status: "started",
131
131
  });
132
132
  });
133
133
  if (!envResult.ok) {
134
134
  console.log(chalk.red(` ✗ python venv bootstrap failed: ${envResult.reason}`));
135
135
  socket.emit("runner:event", {
136
- runId: payload.runId,
137
- payload: {
138
- event_type: "agent_message",
139
- run_id: payload.runId,
140
- project: payload.project,
141
- replyId: `venv-${payload.runId}`,
142
- replyName: "Runner",
143
- replyRole: "system",
144
- msg: {
145
- id: `venv-${payload.runId}`,
146
- name: "Runner",
147
- role: "system",
148
- content: [{ type: "text", text: `Python env bootstrap failed: ${envResult.reason}` }],
149
- metadata: {},
150
- timestamp: new Date().toISOString(),
151
- },
136
+ run_id: payload.runId,
137
+ event_type: "agent_message",
138
+ project: payload.project,
139
+ replyId: `venv-${payload.runId}`,
140
+ replyName: "Runner",
141
+ replyRole: "system",
142
+ msg: {
143
+ id: `venv-${payload.runId}`,
144
+ name: "Runner",
145
+ role: "system",
146
+ content: [{ type: "text", text: `Python env bootstrap failed: ${envResult.reason}` }],
147
+ metadata: {},
148
+ timestamp: new Date().toISOString(),
152
149
  },
153
150
  });
154
151
  socket.emit("runner:runComplete", { runId: payload.runId, status: "failed" });
@@ -178,20 +175,17 @@ export async function connect(opts) {
178
175
  const { preflightModel } = await import("./modelLoader.js");
179
176
  const onPreflightProgress = (msg) => {
180
177
  console.log(chalk.gray(` [model] ${msg}`));
181
- // Surface to the FE via a pipeline_phase event so the launching
182
- // animation reflects "Loading qwen3-vl-8b…" instead of staying
183
- // on a generic spinner.
178
+ // Flat shape server reads payload.run_id at top level
179
+ // (runnerNamespace.ts:202). Earlier nested {runId, payload:{}}
180
+ // was silently dropped by `if (!runId) return`.
184
181
  socket.emit("runner:event", {
185
- runId: payload.runId,
186
- payload: {
187
- event_type: "pipeline_phase",
188
- run_id: payload.runId,
189
- project: payload.project,
190
- step: 1,
191
- total: 5,
192
- label: msg,
193
- status: "started",
194
- },
182
+ run_id: payload.runId,
183
+ event_type: "pipeline_phase",
184
+ project: payload.project,
185
+ step: 1,
186
+ total: 5,
187
+ label: msg,
188
+ status: "started",
195
189
  });
196
190
  };
197
191
  const preflight = await preflightModel(payload.configJson, onPreflightProgress);
@@ -199,22 +193,19 @@ export async function connect(opts) {
199
193
  const detail = `${preflight.reason ?? "unknown"}${preflight.hint ? ` — ${preflight.hint}` : ""}`;
200
194
  console.log(chalk.red(` ✗ model preflight failed: ${detail}`));
201
195
  socket.emit("runner:event", {
202
- runId: payload.runId,
203
- payload: {
204
- event_type: "agent_message",
205
- run_id: payload.runId,
206
- project: payload.project,
207
- replyId: `preflight-${payload.runId}`,
208
- replyName: "Runner",
209
- replyRole: "system",
210
- msg: {
211
- id: `preflight-${payload.runId}`,
212
- name: "Runner",
213
- role: "system",
214
- content: [{ type: "text", text: `Model preflight failed: ${detail}` }],
215
- metadata: {},
216
- timestamp: new Date().toISOString(),
217
- },
196
+ run_id: payload.runId,
197
+ event_type: "agent_message",
198
+ project: payload.project,
199
+ replyId: `preflight-${payload.runId}`,
200
+ replyName: "Runner",
201
+ replyRole: "system",
202
+ msg: {
203
+ id: `preflight-${payload.runId}`,
204
+ name: "Runner",
205
+ role: "system",
206
+ content: [{ type: "text", text: `Model preflight failed: ${detail}` }],
207
+ metadata: {},
208
+ timestamp: new Date().toISOString(),
218
209
  },
219
210
  });
220
211
  socket.emit("runner:runComplete", { runId: payload.runId, status: "failed" });
package/dist/pythonEnv.js CHANGED
@@ -69,6 +69,7 @@ const PIP_DEPS = [
69
69
  "openpyxl",
70
70
  "python-docx",
71
71
  "python-pptx",
72
+ "ddgs", // duckduckgo search rebrand — shared.tools.core imports DDGS
72
73
  ];
73
74
  export function venvPython() {
74
75
  return platform() === "win32"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@melaya/runner",
3
- "version": "1.0.29",
3
+ "version": "1.0.30",
4
4
  "description": "Run Melaya AI pipelines locally with your own LM Studio or Ollama models",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,