Javascript web chat example is broken locally and in demo.
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- javascript
- Domain
- web-dev
Research direction
Reproduce the phi3-mini chat example in the hosted demo and locally, then inspect llm.js at the load, initilize_feed, and generate paths (lines 113, 135, and 209) and main.js at Query and Init (lines 233 and 256). Confirm the fix by loading the model and completing a chat query in both environments without the reported backend, tensor, or run errors.
Written by the indexing model from the issue text.
Description
When trying to run the phi3-mini demo located here: https://guschmue.github.io/ort-webgpu/chat/index.html I am seeing the following errors:
TypeError: Cannot read properties of undefined (reading 'run')
at LLM.generate (llm.js:209:1)
at Query (main.js:233:1)
2025-07-27 15:07:51.676000 [W:onnxruntime:, session_state.cc:1166 VerifyEachNodeIsAssignedToAnEp] Some nodes were not assigned to the preferred execution providers which may or may not have an negative impact on performance. e.g. ORT explicitly assigns shape related ops to CPU to improve perf.
2025-07-27 15:09:42.913699 [W:onnxruntime:, session_state.cc:1168 VerifyEachNodeIsAssignedToAnEp] Rerunning with verbose output on a non-minimal build will show node assignments.
TypeError: A float16 tensor's data must be type of function Float16Array() { [native code] }
at new ze (ort.webgpu.bundle.min.mjs:6:12047)
at LLM.initilize_feed (llm.js:135:44)
at LLM.load (llm.js:118:1)
at async Init (main.js:256:1)
The sample is also broken when trying to run locally although with different errors:
Error: no available backend found. ERR: [webgpu] TypeError: r.requestAdapterInfo is not a function
at On (ort.webgpu.min.js:6:1623)
at async e.create (ort.webgpu.min.js:6:18113)
at async LLM.load (llm.js:113:1)
at async Init (main.js:256:1)
- Dominant language
- C++
- Stars
- 1.7k
- Forks
- 418
- PR merge metrics
- No merged PRs in 30d
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- No pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/onnxruntime-inference-examples
-
Replace deprecated light-server with lite-server for onnxruntime-webPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Minor: typoPossibly taken @Hashim1999164 claimed this 74 days ago. Open
Difficulty 1/5 Under an hour Newbie friendliness 72/100
microsoft/onnxruntime-inference-examples#124 · 1 reaction ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 38/100
-
Package "onnxruntime-react-native" does not contain a valid config pluginPossibly taken @reginaldalfret claimed this 32 days ago. Open
Difficulty 3/5 1-2 days Newbie friendliness 42/100
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
All issues in microsoft/onnxruntime-inference-examples
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
KhronosGroup/Vulkan-Tutorial#534 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
Maintainers usually reply within 2 days
-
bug IO
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
MrNeRF/LichtFeld-Studio#3824 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 77/100
throneproj/Throne#2043 ·
Maintainers usually reply within 2 days
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
Perchik71/Creation-Kit-Platform-Extended#267 ·
Maintainers usually reply within 1 day