open-agents-ai 0.186.48 → 0.186.49

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 (2) hide show
  1. package/dist/index.js +12 -17
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -8267,7 +8267,10 @@ process.on('unhandledRejection', (reason) => {
8267
8267
  try {
8268
8268
  var _cProbe = await fetch(_cApiUrl + '/v1/config', { signal: AbortSignal.timeout(2000) });
8269
8269
  _cApiAvailable = _cProbe.ok;
8270
- } catch {}
8270
+ dlog('COHERE: API probe ' + _cApiUrl + '/v1/config \u2192 ' + (_cProbe.ok ? 'OK' : 'HTTP ' + _cProbe.status));
8271
+ } catch (_cProbeErr) {
8272
+ dlog('COHERE: API probe failed: ' + (_cProbeErr.message || _cProbeErr));
8273
+ }
8271
8274
 
8272
8275
  if (_cApiAvailable) {
8273
8276
  dlog('COHERE: routing through full AgenticRunner at ' + _cApiUrl + '/v1/run');
@@ -8280,7 +8283,7 @@ process.on('unhandledRejection', (reason) => {
8280
8283
  model: _cModel,
8281
8284
  max_turns: 8,
8282
8285
  timeout_s: 90,
8283
- sandbox: 'container',
8286
+ sandbox: 'none',
8284
8287
  profile: 'cohere-mesh',
8285
8288
  }),
8286
8289
  signal: AbortSignal.timeout(120000),
@@ -8327,24 +8330,16 @@ process.on('unhandledRejection', (reason) => {
8327
8330
  dlog('COHERE: AgenticRunner error: ' + (_cRunErr.message || _cRunErr) + ' \u2014 falling back');
8328
8331
  }
8329
8332
  } else {
8330
- dlog('COHERE: OA API not available at ' + _cApiUrl + ' \u2014 using raw Ollama');
8333
+ dlog('COHERE: OA API not available at ' + _cApiUrl + ' \u2014 CANNOT process query (no raw Ollama fallback)');
8334
+ _cContent = '[COHERE error] OA API server not running on this node. Start it with: oa serve';
8331
8335
  }
8332
8336
 
8333
- // Fallback: raw Ollama /api/chat if API not available or returned empty
8337
+ // NO raw Ollama fallback \u2014 all queries MUST go through AgenticRunner
8338
+ // If /v1/run failed or API unavailable, report the error instead of
8339
+ // sending garbage responses without tools/context/system prompt.
8334
8340
  if (!_cContent) {
8335
- var _cMessages = (_cData.messages && _cData.messages.length > 0)
8336
- ? _cData.messages
8337
- : [{ role: 'user', content: _cData.query }];
8338
- dlog('COHERE fallback: raw Ollama, ' + _cMessages.length + ' msg, model=' + _cModel);
8339
- var _cResp = await fetch(_cOllamaUrl + '/api/chat', {
8340
- method: 'POST',
8341
- headers: { 'Content-Type': 'application/json' },
8342
- body: JSON.stringify({ model: _cModel, messages: _cMessages, stream: false }),
8343
- signal: AbortSignal.timeout(120000),
8344
- });
8345
- var _cResult = await _cResp.json();
8346
- _cContent = _cResult.message ? _cResult.message.content : '';
8347
- _cUsage = _cResult.eval_count ? { inputTokens: _cResult.prompt_eval_count || 0, outputTokens: _cResult.eval_count || 0 } : undefined;
8341
+ _cContent = '[COHERE error] AgenticRunner returned empty response. Check OA API server logs.';
8342
+ dlog('COHERE: no content from AgenticRunner \u2014 reporting error (no raw Ollama fallback)');
8348
8343
  }
8349
8344
 
8350
8345
  const _cLatency = Date.now() - _cStart;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "open-agents-ai",
3
- "version": "0.186.48",
3
+ "version": "0.186.49",
4
4
  "description": "AI coding agent powered by open-source models (Ollama/vLLM) — interactive TUI with agentic tool-calling loop",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",