muna 0.0.3
muna: ^0.0.3 copied to clipboard
Run AI models in Flutter. Register at https://muna.ai.
Muna for Flutter #

Run AI models in Flutter. Register at muna.ai.
Installing Muna #
Add muna to your pubspec.yaml:
dependencies:
muna: ^0.0.3
Running a Model #
First, create a Muna client, specifying your access key (create one here):
import "package:muna/muna.dart";
// 💥 Create an OpenAI client
final openai = Muna(accessKey: "<ACCESS KEY>").beta.openai;
Next, run a model:
// 🔥 Create a chat completion
final completion = await openai.chat.completions.create(
model: "@openai/gpt-oss-20b",
messages: [
Message(role: "user", content: "What is the capital of France?"),
],
acceleration: "local_gpu"
);
Before building and running your app, embed the model into your app by adding a muna block to your app's pubspec.yaml:
muna:
access_key: "<ACCESS KEY>"
predictors:
- tag: "@openai/gpt-oss-20b"
Then run the embed command in Terminal:
# Embed models for your app build
$ dart run muna:embed
Finally, run your app and use the results:
// 🚀 Use the results
print(completion.choices.first.message.content);
Useful Links #
- Check out several AI models we've compiled.
- Join our Slack community.
- Check out our docs.
- Read our blog.
- Reach out to us at hi@muna.ai.
Muna is a product of NatML Inc.