0.8.0 • Published 4 years ago
@modelfoxdotdev/modelfox v0.8.0
ModelFox for JavaScript
The ModelFox JavaScript package makes it easy to make predictions with your ModelFox machine learning model from JavaScript.
Setup
Node.js
$ npm install @modelfoxdotdev/modelfoxlet modelfox = require("@modelfoxdotdev/modelfox")Deno
import modelfox from "https://js.modelfox.dev/deno"Bundler
If you are using a bundler that supports WebAssembly modules such as Webpack >= 4, you can use the package from npm.
$ npm install @modelfoxdotdev/modelfoximport modelfox from "@modelfoxdotdev/modelfox"Browser
If you are targeting a modern browser with support for ES Modules, WebAssembly, and top-level await, you can import the modelfox library from https://js.modelfox.dev.
import modelfox from "https://js.modelfox.dev"Usage
let model = new modelfox.Model("./heart_disease.modelfox")
let input = {
age: 63,
gender: "male",
// ...
}
let output = model.predict(input)For more information, read the docs.
Examples
The source for this package contains a number of examples in the examples directory. Each example has a README.md explaining how to run it.
0.8.0
4 years ago