@ariacompute/engine-ts 1.21.0 → 1.22.0

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/README.md CHANGED
@@ -20,7 +20,7 @@ Aria model name (e.g. `gemma-4-e2b-it_q4`). A value containing `/` or already on
20
20
  disk is loaded directly; otherwise the SDK downloads it from the regional public
21
21
  hub (same as `aria-engine download`: `.com` → Hugging Face, `.cn` → ModelScope;
22
22
  `site` defaults to `https://ariacompute.com`) into `~/.ariacompute/models/{model}`
23
- and then loads it. Dashboard is not used. A Dashboard `sk-` / `bfvk-` token is
23
+ and then loads it. Dashboard is not used. A Dashboard `sk-` / `sk-bf-` token is
24
24
  ignored for hub auth. Token is optional for public models. A valid cached bundle
25
25
  is reused without re-downloading.
26
26
 
package/dist/index.d.ts CHANGED
@@ -27,7 +27,7 @@ export interface CompleteResult {
27
27
  generation?: Generation;
28
28
  }
29
29
  export interface OpenOptions {
30
- /** Legacy generic hub token. Dashboard sk-/bfvk- keys are ignored. */
30
+ /** Legacy generic hub token. Dashboard sk-/sk-bf- keys are ignored. */
31
31
  token?: string;
32
32
  /** Hugging Face hub token (`.com`). Same field as `aria-engine setup` `hf_token`. */
33
33
  hfToken?: string;
@@ -44,7 +44,7 @@ export declare const CN_SITE = "https://ariacompute.cn";
44
44
  export declare const CN_UPGRADE = "https://gitee.com/ariacompute";
45
45
  export interface SetupConfig {
46
46
  router: string;
47
- /** sk-aria_ or bfvk-; router associates by prefix */
47
+ /** sk-aria_ or sk-bf-; router associates by prefix */
48
48
  router_api_key: string;
49
49
  site_url: string;
50
50
  upgrade_url: string;
package/dist/index.js CHANGED
@@ -101,9 +101,9 @@ function validateRouterApiKey(key) {
101
101
  const t = (key || "").trim();
102
102
  if (!t)
103
103
  return;
104
- if (t.startsWith("sk-aria_") || t.startsWith("bfvk-"))
104
+ if (t.startsWith("sk-aria_") || t.startsWith("sk-bf-"))
105
105
  return;
106
- throw new Error("router_api_key must start with sk-aria_ or bfvk-");
106
+ throw new Error("router_api_key must start with sk-aria_ or sk-bf-");
107
107
  }
108
108
  function applySetup(existing, updates) {
109
109
  const out = { ...existing };
@@ -182,7 +182,7 @@ function hubBearer(token) {
182
182
  if (!t)
183
183
  return undefined;
184
184
  const low = t.toLowerCase();
185
- if (low.startsWith("sk-") || low.startsWith("bfvk-"))
185
+ if (low.startsWith("sk-"))
186
186
  return undefined;
187
187
  return t;
188
188
  }
@@ -302,7 +302,7 @@ async function fetchHubFile(source, model, file, dest, token, required) {
302
302
  last = e;
303
303
  if (e instanceof HubHttpError && (e.status === 401 || e.status === 403)) {
304
304
  const field = source === "modelscope" ? "modelscope_api_token" : "hf_token";
305
- throw new Error(`auth failed HTTP ${e.status}; set ${field} via aria-engine setup (do not pass a Dashboard sk-/bfvk- key as the hub token)`);
305
+ throw new Error(`auth failed HTTP ${e.status}; set ${field} via aria-engine setup (do not pass a Dashboard sk-/sk-bf- key as the hub token)`);
306
306
  }
307
307
  }
308
308
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ariacompute/engine-ts",
3
- "version": "1.21.0",
3
+ "version": "1.22.0",
4
4
  "description": "TypeScript/Node SDK for Aria Engine",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",