@nanogpt/private-mode 0.2.7 → 0.2.8

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/lib/server.js +2 -4
  2. package/package.json +1 -1
package/lib/server.js CHANGED
@@ -183,9 +183,8 @@ async function runPreflight({ apiBase, apiKey, model, req, requestBodyBytes }) {
183
183
  try {
184
184
  const data = await response.json();
185
185
  const cacheScope = typeof data?.cacheScope === 'string' ? data.cacheScope.trim() : '';
186
- const preflightTicket = typeof data?.preflightTicket === 'string' ? data.preflightTicket.trim() : '';
187
- if (/^[a-f0-9]{64}$/i.test(cacheScope) && preflightTicket) {
188
- return { ok: true, cacheScope, preflightTicket };
186
+ if (/^[a-f0-9]{64}$/i.test(cacheScope)) {
187
+ return { ok: true, cacheScope };
189
188
  }
190
189
  } catch {}
191
190
 
@@ -313,7 +312,6 @@ async function handleChatCompletion({ apiBase, apiKey, secureState, req, res, co
313
312
  'x-nanogpt-private-model': model.id,
314
313
  'x-nanogpt-private-stream': privateStreamRequested ? 'true' : 'false',
315
314
  'x-nanogpt-private-cache-scope': buildPrivateModeCacheScopeProof(preflight.cacheScope),
316
- 'x-nanogpt-private-preflight-ticket': preflight.preflightTicket,
317
315
  'x-query-source': 'api',
318
316
  ...copyLocalHeaders(req),
319
317
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nanogpt/private-mode",
3
- "version": "0.2.7",
3
+ "version": "0.2.8",
4
4
  "description": "OpenAI-compatible localhost proxy for NanoGPT Private Mode.",
5
5
  "type": "module",
6
6
  "publishConfig": {