clarity-ai 6.5.4 → 6.5.6

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/CHANGELOG.md CHANGED
@@ -2,6 +2,19 @@
2
2
 
3
3
  ---
4
4
 
5
+ ## 6.5.6 (2026-06-06)
6
+
7
+ ### Fix first-request timeout — model download needs >8s
8
+ - Raised `CONNECT_TIMEOUT` from 8s to 120s so the CLI waits for model download on cold Space
9
+ - Raised `READ_TIMEOUT` to 15s for per-chunk streaming
10
+ - Fixes "Processing..." hang + 404 in Space logs when model is still loading
11
+
12
+ ## 6.5.5 (2026-06-06)
13
+
14
+ ### Fix model routing — repo prefix stripped by regex
15
+ - Fixed `MODEL_ROUTES` keys to match `Clarity-flash-weights` / `Clarity-heavy-weights` after `callAI` strips the provider AND repo prefixes
16
+ - `npm install -g clarity-ai@latest` now works out of the box
17
+
5
18
  ## 6.5.4 (2026-06-06)
6
19
 
7
20
  ### Docker SDK + Local GGUF Inference
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clarity-ai",
3
- "version": "6.5.4",
3
+ "version": "6.5.6",
4
4
  "description": "CLARITY — terminal AI agent with local GGUF inference on HF Spaces",
5
5
  "type": "module",
6
6
  "bin": {
@@ -2,12 +2,12 @@ import { getKey } from '../config/keys.js';
2
2
  import { streamResponse } from './streaming.js';
3
3
 
4
4
  const MODEL_ROUTES = {
5
- 'Universal-618/Clarity-flash-weights': [
5
+ 'Clarity-flash-weights': [
6
6
  process.env.CLARITY_INFERENCE_URL || 'https://universal-618-clarity-main.hf.space/v1/chat/completions',
7
7
  'https://universal-618-clarity-2.hf.space/v1/chat/completions',
8
8
  'https://universal-618-clarity-3.hf.space/v1/chat/completions',
9
9
  ],
10
- 'Universal-618/Clarity-heavy-weights': [
10
+ 'Clarity-heavy-weights': [
11
11
  process.env.CLARITY_INFERENCE_URL || 'https://universal-618-clarity-4.hf.space/v1/chat/completions',
12
12
  'https://universal-618-clarity-5.hf.space/v1/chat/completions',
13
13
  'https://universal-618-clarity-6.hf.space/v1/chat/completions',
@@ -1,4 +1,5 @@
1
- const READ_TIMEOUT = 8000;
1
+ const CONNECT_TIMEOUT = 120000;
2
+ const READ_TIMEOUT = 15000;
2
3
 
3
4
  function readWithTimeout(reader, timeoutMs, signal) {
4
5
  return Promise.race([
@@ -19,7 +20,7 @@ export async function* streamResponse(endpoint, body, apiKey, extraHeaders = {},
19
20
  }
20
21
  signal?.addEventListener('abort', onAbort, { once: true });
21
22
 
22
- const fetchTimeout = setTimeout(() => controller.abort(), READ_TIMEOUT);
23
+ const fetchTimeout = setTimeout(() => controller.abort(), CONNECT_TIMEOUT);
23
24
 
24
25
  try {
25
26
  const res = await fetch(endpoint, {