@myagentroam/agent 0.9.153 → 0.9.154

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.
@@ -1,7 +1,7 @@
1
1
  import { type Socket } from 'node:net';
2
2
  import { MarAgentError } from '../error.js';
3
3
  import type { ModelRetryState } from './contracts.js';
4
- export declare const MAX_MODEL_ATTEMPTS = 5;
4
+ export declare const MAX_MODEL_ATTEMPTS = 8;
5
5
  export declare function modelRetryMaxAttempts(state: ModelRetryState): number;
6
6
  export interface ModelHttpAttempt {
7
7
  readonly request: RequestInit;
@@ -3,11 +3,11 @@ import { connect as connectTcp } from 'node:net';
3
3
  import { connect as connectTls } from 'node:tls';
4
4
  import { Client, Socks5ProxyAgent, buildConnector, fetch as undiciFetch } from 'undici';
5
5
  import { MarAgentError } from '../error.js';
6
- export const MAX_MODEL_ATTEMPTS = 5;
6
+ export const MAX_MODEL_ATTEMPTS = 8;
7
7
  export function modelRetryMaxAttempts(state) {
8
8
  const maximum = state.maxAttempts ?? MAX_MODEL_ATTEMPTS;
9
9
  if (!Number.isInteger(maximum) || maximum < 1 || maximum > MAX_MODEL_ATTEMPTS)
10
- throw new MarAgentError('MAR_AGENT_MODEL_CONFIG_INVALID', 'Model attempts must be between 1 and 5.');
10
+ throw new MarAgentError('MAR_AGENT_MODEL_CONFIG_INVALID', `Model attempts must be between 1 and ${MAX_MODEL_ATTEMPTS}.`);
11
11
  return maximum;
12
12
  }
13
13
  const RETRYABLE_STATUS = new Set([408, 409, 429, 500, 502, 503, 504]);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@myagentroam/agent",
3
- "version": "0.9.153",
3
+ "version": "0.9.154",
4
4
  "description": "Embeddable MAR coding agent SDK and CLI.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",