Skip to content

Phi-3 Mini demo#52

Merged
fdwr merged 8 commits intomicrosoft:mainfrom
ibelem:phi-3-demo
Nov 12, 2024
Merged

Phi-3 Mini demo#52
fdwr merged 8 commits intomicrosoft:mainfrom
ibelem:phi-3-demo

Conversation

@ibelem
Copy link
Contributor

@ibelem ibelem commented Nov 7, 2024

Add Phi-3 Mini demo:

Some changes needed in next PRs

@fdwr @Honry PTAL

@ibelem
Copy link
Contributor Author

ibelem commented Nov 7, 2024

@fdwr Please try https://ibelem.github.io/webnn-developer-preview/demos/phi-3-mini/ with latest Chrome Canary 132.0.6831.0 or newer, and let us know your feedback. Thanks!

Copy link
Collaborator

@fdwr fdwr left a comment

Choose a reason for hiding this comment

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

Thanks Belem! 🙌

FYI @yassermkhan one of the new WebNN demos.


log(`Phi-3 Mini model size: ${Math.round(model_size / 1024 / 1024)} MB`);
this.ml_context = await navigator.ml.createContext({ deviceType: "gpu" });
const session_options = {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
const session_options = {
const sessionOptions = {

This file has a weird mix of camelCase and snake_case?

const session_options = ...
...
let progressBarLabel ...

}
}

async initialize_feed() {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
async initialize_feed() {
async initializeFeed() {

@ibelem
Copy link
Contributor Author

ibelem commented Nov 12, 2024

@fdwr The UI of this project are mostly camelCase, but the llm file generated by guschmue originally was snake_case, e.g. model inputs for model overrides, transformers.js tokens. Is that possible to keep them?

@fdwr
Copy link
Collaborator

fdwr commented Nov 12, 2024

Is that possible to keep them?

Let's keep them for now so we can get the demo out sooner. 🐍🙈

Please test the demo ... using Chrome Canary (version 132.0.6831.0 or later) before merging the PR.

👍 Given @Adele101 successfully ran it locally, I will merge it now.

@fdwr fdwr merged commit fb30528 into microsoft:main Nov 12, 2024
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.

2 participants