Skip to content

Add repo scaffolding and natural-language-to-SQL example - #1

Merged
thomasblc merged 2 commits into
mainfrom
add-nl-to-sql-example
Jun 17, 2026
Merged

thomasblc merged 2 commits into
mainfrom
add-nl-to-sql-example

Conversation

@costin-busioc

Copy link
Copy Markdown
Contributor
  • Root files: .gitignore, LICENSE, README.md
  • qvac-natural-language-to-sql: Electron app that turns plain-English questions into local SQL via the QVAC SDK (Qwen3 4B) over an in-memory SQLite (sql.js) bank dataset.

- Root files: .gitignore, LICENSE, README.md
- qvac-natural-language-to-sql: Electron app that turns plain-English questions into local SQL via the QVAC SDK (Qwen3 4B) over an in-memory SQLite (sql.js) bank dataset.
@costin-busioc
costin-busioc requested a review from thomasblc June 17, 2026 09:52
@github-advanced-security

Copy link
Copy Markdown

You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool.

What Enabling Code Scanning Means:

  • The 'Security' tab will display more code scanning analysis results (e.g., for the default branch).
  • Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results.
  • You will be able to see the analysis results for the pull request's branch on this overview once the scans have completed and the checks have passed.

For more information about GitHub Code Scanning, check out the documentation.

Comment thread qvac-natural-language-to-sql/renderer/index.html Fixed
The renderer loaded sql.js, React, React-DOM, and @babel/standalone from
CDNs at runtime, contradicting the "100% on-device, nothing leaves the
machine" claim and breaking the app offline.

- Vendor sql.js WASM and the production React/React-DOM builds into
  renderer/vendor/ via scripts/build.js; wire window.QVAC_LOCAL_WASM and
  drop the Cloudflare fallback in db.js.
- Pre-transpile JSX to plain JS at build time (classic runtime) and drop
  the in-browser Babel; index.html no longer loads any remote script.
- Add build/prestart npm scripts so `npm start` always builds first;
  gitignore the generated renderer/vendor/, app.js, components.js.
- Make sql.js a regular dependency (exact 1.14.1), pin @qvac/sdk exact
  (0.12.2), and add React/Babel as build-time devDependencies.
- Update README/RECIPE to describe the offline-by-default build.

Result: zero network requests at runtime except the one-time model
download through the SDK.

@thomasblc thomasblc left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. The fully-offline pass addresses the earlier CDN concern cleanly: sql.js WASM + production React/React-DOM are vendored into renderer/vendor/ and the JSX is pre-transpiled via scripts/build.js (run automatically by prestart), so the renderer loads zero CDN scripts and never runs Babel at runtime. QVAC_LOCAL_WASM is wired so the WASM resolves locally. SDK usage matches the official shipped quickstart (dynamic ESM import, modelType llm, completion -> result.text, unloadModel on quit), @qvac/sdk is pinned exactly to 0.12.2, sql.js is a real dependency, and the read-only guard + schema-only prompt match the recipe's privacy claims. Verified statically (build chain + tree); only network call left is the one-time model download. Nice work.

@thomasblc
thomasblc merged commit 0d82802 into main Jun 17, 2026
2 checks passed
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.

3 participants