Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
2e5c5dc
Merge pull request #1 from protosphinx/claude/dhamaka-llm-prompt-dHacl
protosphinx Apr 11, 2026
7a0ad5c
Work through the pending punch list from the Dhamaka scaffold
protosphinx Apr 11, 2026
de73cf2
Build the real Rust inference runtime and wire it end-to-end
protosphinx Apr 11, 2026
639892a
Document the test suite in the README
protosphinx Apr 11, 2026
9533cd3
Animated SVG banner for the README title
protosphinx Apr 11, 2026
18b3ac6
Prepare v0.1.0: changelog, staging script, release workflow
protosphinx Apr 11, 2026
1fb671c
Add docs/GOALS.md: the north-star document for the pivot
protosphinx Apr 11, 2026
6f5fd2a
Pivot to SmartField: reflex layer for every input field on the web
protosphinx Apr 11, 2026
028e47c
Expand scope: Dhamaka is a local AI capability layer, not just a refl…
protosphinx Apr 11, 2026
c04ca5a
Rename project to Locus + add the manifesto
protosphinx Apr 11, 2026
27a0151
Revert the Locus rename: name stays Dhamaka
protosphinx Apr 11, 2026
a39031f
Ship demo site: formula editor + build script + GitHub Pages workflow
protosphinx Apr 11, 2026
c8e7d1a
Add Jekyll GitHub Pages deployment workflow
protosphinx Apr 11, 2026
ad7d4c0
Create w
protosphinx Apr 11, 2026
c2377e4
pages: self-provision the Pages site on first deploy
protosphinx Apr 11, 2026
b8e0668
pages: remove conflicting Jekyll + CI template workflows
protosphinx Apr 11, 2026
66d4176
Option B: real LLM via Transformers.js, kill hardcoded spellcheck
protosphinx Apr 11, 2026
f5b110a
Fix spellcheck: distilBERT fill-mask, not LaMini instruction prompting
protosphinx Apr 12, 2026
2a0e704
Spellcheck UX: tighter suggestion filter, try-list, honest gibberish …
protosphinx Apr 12, 2026
dc981c4
Fix cache-busting: propagate ?v=SHA through every relative .js import
protosphinx Apr 12, 2026
5f37dd6
Add Playwright e2e tests, benchmarks, GitHub Pages deploy, and update…
protosphinx Apr 13, 2026
0a0a9c6
Fix spellcheck: add rules-based fast path for instant common misspell…
protosphinx Apr 13, 2026
5a1066e
Fix broken GitHub Pages deploy: import maps used absolute paths that 404
protosphinx Apr 13, 2026
38ca87f
Fix spellcheck model false positives: quality gate, KNOWN_WORDS, edit…
protosphinx Apr 13, 2026
d0a2a49
Fix city autofill: Newport→New York bug and stale field data
protosphinx Apr 13, 2026
ab6ed5e
Make autofill fields editable, expand gazetteer with 15 more US cities
protosphinx Apr 13, 2026
5d4f02b
Wire up on-device LLM for city-to-state: any city in the world
protosphinx Apr 13, 2026
b573093
Expand gazetteer from 115 to 721 cities: instant lookup for any major…
protosphinx Apr 13, 2026
00c10c2
Remove LLM from autofill demo: gazetteer-only for speed and correctness
protosphinx Apr 13, 2026
7d2f141
Add US Tax Calculator: sales tax + federal income tax tasks
sagarm85 Apr 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 84 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
name: ci

on:
push:
branches: [main]
pull_request:

jobs:
rust:
name: rust crate
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: install rust toolchain
run: |
rustup update stable
rustup default stable
rustup target add wasm32-unknown-unknown

- name: cargo test (native)
run: cargo test --manifest-path crates/dhamaka-runtime/Cargo.toml

- name: build wasm
run: crates/dhamaka-runtime/build.sh

- name: upload wasm artifact
uses: actions/upload-artifact@v4
with:
name: dhamaka-runtime-wasm
path: packages/hub/public/runtime/dhamaka-runtime.wasm
if-no-files-found: error

js:
name: js (node ${{ matrix.node }})
runs-on: ubuntu-latest
needs: rust
strategy:
fail-fast: false
matrix:
node: ["20", "22"]
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}

- name: download wasm artifact
uses: actions/download-artifact@v4
with:
name: dhamaka-runtime-wasm
path: packages/hub/public/runtime

- name: syntax check
run: |
find packages -name '*.js' -not -path '*/node_modules/*' \
| xargs -n1 node --check

- name: run tests
run: npm test

- name: smoke test dev server
run: |
node packages/playground/server.js &
SERVER_PID=$!
sleep 2
for url in \
"http://localhost:5174/" \
"http://localhost:5174/hub.js" \
"http://localhost:5174/manifest.json" \
"http://localhost:5174/runtime/dhamaka-runtime.wasm" \
"http://localhost:5173/" \
"http://localhost:5173/sdk/index.js" \
"http://localhost:5173/runtime/index.js"; do
code=$(curl -s -o /dev/null -w "%{http_code}" "$url")
if [ "$code" != "200" ]; then
echo "FAIL: $url returned $code"
kill $SERVER_PID 2>/dev/null || true
exit 1
fi
echo "OK: $url"
done
kill $SERVER_PID 2>/dev/null || true
57 changes: 57 additions & 0 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: pages

on:
push:
branches: [main]
paths:
- "packages/**"
- "crates/**"
- "docs/**"
- ".github/workflows/pages.yml"
workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: pages
cancel-in-progress: true

jobs:
build-and-deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deploy.outputs.page_url }}
steps:
- uses: actions/checkout@v4

- name: configure pages
uses: actions/configure-pages@v5

- name: install rust toolchain
run: |
rustup update stable
rustup default stable
rustup target add wasm32-unknown-unknown

- name: build wasm
run: crates/dhamaka-runtime/build.sh

- uses: actions/setup-node@v4
with:
node-version: "22"

- name: assemble site
run: node packages/playground/build-site.mjs

- name: upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: packages/playground/_site

- name: deploy to github pages
id: deploy
uses: actions/deploy-pages@v4
109 changes: 109 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
name: release

on:
push:
tags:
- "v*"

permissions:
contents: write # needed to create the GitHub release + upload assets

jobs:
release:
name: build, test, stage, and release ${{ github.ref_name }}
runs-on: ubuntu-latest
env:
# Hoisting NPM_TOKEN to job level so the conditional `if` checks in
# the publish steps below can actually read it.
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
steps:
- uses: actions/checkout@v4

# ─── Rust toolchain + wasm build ────────────────────────────────────
- name: install rust toolchain
run: |
rustup update stable
rustup default stable
rustup target add wasm32-unknown-unknown

- name: cargo test (native)
run: cargo test --manifest-path crates/dhamaka-runtime/Cargo.toml

- name: build wasm
run: crates/dhamaka-runtime/build.sh

# ─── Node toolchain + JS tests ──────────────────────────────────────
- uses: actions/setup-node@v4
with:
node-version: "22"
registry-url: "https://registry.npmjs.org"

- name: run js tests
run: npm test

# ─── Stage the publishable package ──────────────────────────────────
- name: stage publish
run: node scripts/prepare-publish.mjs

- name: inspect staged package
run: |
cd packages/sdk/_staging
npm pack --dry-run
npm pack
ls -lh *.tgz

# ─── Verify the tag matches the package version ─────────────────────
- name: verify tag matches package version
run: |
TAG="${GITHUB_REF_NAME#v}"
PKG=$(node -p "require('./packages/sdk/_staging/package.json').version")
if [ "$TAG" != "$PKG" ]; then
echo "FAIL: tag $TAG does not match package version $PKG"
exit 1
fi
echo "OK: tag $TAG matches package version $PKG"

# ─── Publish to npm (only if NPM_TOKEN is set) ──────────────────────
- name: publish to npm
if: env.NPM_TOKEN != ''
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
cd packages/sdk/_staging
npm publish --access public --provenance

- name: skip npm publish (no NPM_TOKEN)
if: env.NPM_TOKEN == ''
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
echo "NPM_TOKEN not set — skipping npm publish."
echo "To enable automated publishing: Settings → Secrets → Actions → new secret 'NPM_TOKEN'."

# ─── Create the GitHub release with the wasm + tarball attached ─────
- name: extract release notes from changelog
id: notes
run: |
VERSION="${GITHUB_REF_NAME#v}"
# Everything between "## [VERSION]" and the next "## [" header.
awk -v ver="$VERSION" '
$0 ~ "^## \\[" ver "\\]" { found = 1; next }
found && $0 ~ "^## \\[" { exit }
found { print }
' CHANGELOG.md > release_notes.md
if [ ! -s release_notes.md ]; then
echo "no changelog entry for $VERSION, using tag message" > release_notes.md
fi
echo "notes_file=release_notes.md" >> $GITHUB_OUTPUT

- name: create github release
uses: softprops/action-gh-release@v2
with:
name: Dhamaka ${{ github.ref_name }}
body_path: ${{ steps.notes.outputs.notes_file }}
draft: false
prerelease: ${{ contains(github.ref_name, '-') }}
files: |
packages/sdk/_staging/dhamaka-*.tgz
packages/hub/public/runtime/dhamaka-runtime.wasm
19 changes: 19 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,27 @@ build/
.env
.env.local
coverage/
package-lock.json
*.wasm.map
models/*.bin
models/*.onnx
models/*.gguf
!models/manifest.json

# Rust build output. The compiled .wasm is staged into
# packages/hub/public/runtime/ by build.sh and *is* committed so users
# without a Rust toolchain can run the dev stack. The target/ dir is not.
crates/*/target/
Cargo.lock

# npm publish staging directory, rebuilt from scratch by
# scripts/prepare-publish.mjs on every release.
packages/sdk/_staging/
packages/sdk/*.tgz

# GitHub Pages build output, rebuilt from scratch by
# packages/playground/build-site.mjs on every deploy.
packages/playground/_site/

# Playwright
test-results/
Loading