Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes to add category for powerboostlet #19

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 2 additions & 0 deletions examples/imageCaptioning.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ async function run() {
// detect visualization framework
Boostlet.init();

Boostlet.category = "LLM Models"

const requestData = await request();
console.log(requestData);

Expand Down
4 changes: 2 additions & 2 deletions examples/melanoma.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ async function run() {
// detect visualization framework
Boostlet.init();

getImage();

Boostlet.category = "Machine Learning"

getImage();
}


Expand Down
2 changes: 2 additions & 0 deletions examples/plotly.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ function run() {
// detect visualization framework
Boostlet.init();

Boostlet.category = "Data Visualization"

all_pixels = Boostlet.get_image().data;

// load Plotly.js library and start plotting in the onload callback
Expand Down
2 changes: 2 additions & 0 deletions examples/segmentanything.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ function run() {
// detect visualization framework
Boostlet.init();

Boostlet.category = "Machine Learning"

// load ONNX.js
Boostlet.load_script('https://cdn.jsdelivr.net/npm/onnxruntime-web/dist/ort.min.js');

Expand Down
3 changes: 3 additions & 0 deletions examples/sobel.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
script = document.createElement("script");
script.type = "text/javascript";
script.src = "https://boostlet.org/dist/boostlet.min.js";
// script.src = "http://localhost:5500/dist/boostlet.min.js";

script.onload = run;
document.head.appendChild(script);
Expand All @@ -12,6 +13,8 @@ function run() {
// detect visualization framework
Boostlet.init();

Boostlet.category = "Filters"

image = Boostlet.get_image();

kernel = [
Expand Down
2 changes: 2 additions & 0 deletions examples/trako.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ async function run() {
// detect visualization framework
Boostlet.init();

Boostlet.category = "Filters"

// using the XTK TRAKO FILE READER
libs = ["https://bostongfx.github.io/TRAKO/WEB/js/xtk.js",
"https://bostongfx.github.io/TRAKO/WEB/js/draco/draco_decoder.js",
Expand Down
6 changes: 4 additions & 2 deletions examples/webllm.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
script = document.createElement("script");
script.type = "text/javascript";
//script.src = "https://boostlet.org/dist/boostlet.min.js";
script.src = "https://boostlet.org/dist/boostlet.min.js";
// script.src = "http://localhost:5500/dist/boostlet.min.js";
script.src = "https://gaiborjosue.github.io/boostlet/dist/boostlet.min.js";
// script.src = "https://gaiborjosue.github.io/boostlet/dist/boostlet.min.js";

script.onload = run;
document.head.appendChild(script);
Expand All @@ -12,6 +12,8 @@ async function run() {
// detect visualization framework
Boostlet.init();

Boostlet.category = "LLM Models"

const script = document.createElement("script");
script.type = "module";
script.src = "https://mpsych.github.io/cdn/web-llm/web-llm-cdn.js";
Expand Down
4 changes: 3 additions & 1 deletion src/boostlet.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ export class Boostlet {

this.framework = null;

this.category = null;
}

/**
Expand Down Expand Up @@ -44,6 +45,7 @@ export class Boostlet {

}


}

/**
Expand Down Expand Up @@ -138,5 +140,5 @@ export class Boostlet {
return Util.hint(message, duration);

}

}