Skip to content

fix: restore lost lib files and fix package compatibility - #1

Merged
Das-rebel merged 1 commit into
mainfrom
add-a3m-router
Jul 16, 2026
Merged

fix: restore lost lib files and fix package compatibility#1
Das-rebel merged 1 commit into
mainfrom
add-a3m-router

Conversation

@Das-rebel

Copy link
Copy Markdown
Owner

Summary

Restores lost source files and fixes package compatibility issues that were causing CI failures.

Root Cause

During a HEAD is now at aa5e43a fix: restore lost lib files and fix package compatibility operation, several source files in were accidentally deleted. The CI was then failing because:

  1. had a JSON syntax error (missing closing brace)
  2. Missing , , ,
  3. Missing and

Changes

  • Restore lost files from commit :

    • — A3M router integration
    • — environment config
    • — parallel ensemble executor
    • — query presets & cost tracking
  • Fix package.json JSON syntax error

  • Fix API compatibility with :

    • now takes not an object
    • uses instead of
  • Fix TypeScript errors:

    • : loyalty variable scope issue
    • : possibly undefined check
  • Add missing config files:

    • — SvelteKit adapter config
    • — test configuration

Verification

All CI checks pass locally:

  • ✅ bun test v1.3.14 (0d9b296a) — 1 test passes

quay-ai-factory@0.1.0 check
svelte-kit sync && svelte-check --tsconfig ./tsconfig.json

Loading svelte-check in workspace: /Users/Subho/quay
Getting Svelte diagnostics...

/Users/Subho/quay/src/routes/marketing/+page.svelte:552:11
Warn: A form label must be associated with a control
https://svelte.dev/e/a11y_label_has_associated_control (svelte)


Platforms

/Users/Subho/quay/src/routes/marketing/+page.svelte:654:11
Warn: A form label must be associated with a control
https://svelte.dev/e/a11y_label_has_associated_control (svelte)


Sources

====================================
svelte-check found 0 errors and 2 warnings in 1 file — 0 errors

quay-ai-factory@0.1.0 build
vite build

vite v8.1.3 building ssr environment for production...
�[2K
transforming...✓ 157 modules transformed.
rendering chunks...
vite v8.1.3 building client environment for production...
�[2K
transforming...✓ 161 modules transformed.
rendering chunks...
computing gzip size...
.svelte-kit/output/client/_app/version.json 0.02 kB │ gzip: 0.04 kB
.svelte-kit/output/client/.vite/manifest.json 3.13 kB │ gzip: 0.61 kB
.svelte-kit/output/client/_app/immutable/assets/0.Czu7XWWu.css 0.60 kB │ gzip: 0.37 kB
.svelte-kit/output/client/_app/immutable/assets/2.BWQ5upQ4.css 10.80 kB │ gzip: 2.21 kB
.svelte-kit/output/client/_app/immutable/assets/3.kvwUUNH7.css 12.75 kB │ gzip: 2.70 kB
.svelte-kit/output/client/_app/immutable/chunks/kFiZjIw8.js 0.02 kB │ gzip: 0.04 kB
.svelte-kit/output/client/_app/immutable/chunks/xihTtKlq.js 0.06 kB │ gzip: 0.08 kB
.svelte-kit/output/client/_app/immutable/entry/start.zKDLheJW.js 0.07 kB │ gzip: 0.08 kB
.svelte-kit/output/client/_app/immutable/nodes/0.BiN5aWJL.js 0.17 kB │ gzip: 0.15 kB
.svelte-kit/output/client/_app/immutable/nodes/1.Bo1VmNEc.js 0.62 kB │ gzip: 0.35 kB
.svelte-kit/output/client/_app/immutable/chunks/DYl5dUZ5.js 1.27 kB │ gzip: 0.70 kB
.svelte-kit/output/client/_app/immutable/chunks/Bjy-W4x2.js 1.36 kB │ gzip: 0.65 kB
.svelte-kit/output/client/_app/immutable/entry/app.BXwSJrzD.js 3.02 kB │ gzip: 1.36 kB
.svelte-kit/output/client/_app/immutable/nodes/2.3aWwVjxb.js 19.73 kB │ gzip: 6.41 kB
.svelte-kit/output/client/_app/immutable/nodes/3.D9oXig-g.js 25.75 kB │ gzip: 6.29 kB
.svelte-kit/output/client/_app/immutable/chunks/PVVbv1Wd.js 26.70 kB │ gzip: 10.33 kB
.svelte-kit/output/client/_app/immutable/chunks/Yw0KAbRT.js 47.45 kB │ gzip: 18.30 kB

✓ built in 170ms
computing gzip size...
.svelte-kit/output/server/.vite/manifest.json 5.17 kB │ gzip: 0.75 kB
.svelte-kit/output/server/_app/immutable/assets/_layout.Czu7XWWu.css 0.60 kB │ gzip: 0.37 kB
.svelte-kit/output/server/_app/immutable/assets/_page.BWQ5upQ4.css 10.80 kB │ gzip: 2.21 kB
.svelte-kit/output/server/_app/immutable/assets/_page.kvwUUNH7.css 12.75 kB │ gzip: 2.70 kB
.svelte-kit/output/server/chunks/index-server2.js 0.03 kB │ gzip: 0.05 kB
.svelte-kit/output/server/env.js 0.22 kB │ gzip: 0.14 kB
.svelte-kit/output/server/entries/pages/_layout.svelte.js 0.23 kB │ gzip: 0.18 kB
.svelte-kit/output/server/chunks/env.js 0.28 kB │ gzip: 0.17 kB
.svelte-kit/output/server/internal.js 0.40 kB │ gzip: 0.19 kB
.svelte-kit/output/server/entries/endpoints/api/marketing/performance/_server.ts.js 0.80 kB │ gzip: 0.44 kB
.svelte-kit/output/server/entries/endpoints/api/marketing/analyze/_server.ts.js 0.99 kB │ gzip: 0.51 kB
.svelte-kit/output/server/entries/endpoints/api/marketing/signals/_server.ts.js 1.03 kB │ gzip: 0.53 kB
.svelte-kit/output/server/entries/endpoints/api/marketing/creatives/_server.ts.js 1.10 kB │ gzip: 0.55 kB
.svelte-kit/output/server/entries/endpoints/api/marketing/campaign/_server.ts.js 1.11 kB │ gzip: 0.58 kB
.svelte-kit/output/server/chunks/internal.js 1.24 kB │ gzip: 0.51 kB
.svelte-kit/output/server/entries/pages/marketing/_page.svelte.js 2.97 kB │ gzip: 1.04 kB
.svelte-kit/output/server/chunks/index-server.js 4.54 kB │ gzip: 1.68 kB
.svelte-kit/output/server/entries/fallbacks/error.svelte.js 5.19 kB │ gzip: 1.99 kB
.svelte-kit/output/server/chunks/mcp.js 5.51 kB │ gzip: 1.88 kB
.svelte-kit/output/server/chunks/shared.js 10.57 kB │ gzip: 3.38 kB
.svelte-kit/output/server/chunks/exports.js 11.31 kB │ gzip: 3.52 kB
.svelte-kit/output/server/entries/pages/_page.svelte.js 11.63 kB │ gzip: 3.32 kB
.svelte-kit/output/server/chunks/internal2.js 20.66 kB │ gzip: 6.39 kB
.svelte-kit/output/server/chunks/utils.js 31.86 kB │ gzip: 9.37 kB
.svelte-kit/output/server/remote-entry.js 54.47 kB │ gzip: 12.01 kB
.svelte-kit/output/server/index.js 123.80 kB │ gzip: 31.43 kB
.svelte-kit/output/server/chunks/server.js 129.81 kB │ gzip: 33.66 kB

✓ built in 1.54s

Run npm run preview to preview your production build locally.

Using @sveltejs/adapter-auto
Could not detect a supported production environment. See https://svelte.dev/docs/kit/adapters to learn how to configure your app to run on the platform of your choosing
✔ done — builds successfully

  • ✅ Dev server starts correctly
  • ✅ API server starts correctly

Note

Only 2 accessibility warnings remain (non-blocking):

  • in marketing page (labels for chip groups)

- Restore lost lib files from commit 563a6a9 (lost during git reset):
  - src/lib/a3m.ts (A3M router integration)
  - src/lib/config.ts (environment config)
  - src/lib/ensemble.ts (parallel ensemble executor)
  - src/lib/routing.ts (query presets & cost tracking)

- Fix package.json JSON syntax error (missing closing brace)

- Fix a3m.ts to use current adaptive-memory-multi-model-router API:
  - routeQuery takes (prompt, models, budget) not object
  - CostTracker uses monthly_limit instead of budget/onBudgetAlert
  - Re-export estimateTokens for ensemble compatibility

- Fix ensemble.ts: loyalty variable scope issue
- Fix routing.ts: budgetCap undefined check

- Add svelte.config.js and vitest.config.ts for proper test/build config

- All tests pass, build succeeds
@Das-rebel
Das-rebel merged commit cc1cc1d into main Jul 16, 2026
2 of 3 checks passed
@Das-rebel
Das-rebel deleted the add-a3m-router branch July 16, 2026 21:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant