File size: 1,016 Bytes
f9fe65c
 
976647c
 
f9fe65c
4faf71e
 
56dbb44
1c2c273
4faf71e
 
 
bb63f68
4faf71e
 
 
 
 
 
 
976647c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
---
license: mit
library_name: unity-sentis
pipeline_tag: text-to-audio
---

# MusicGen music generation for Unity Sentis format
This is the [Meta MusicGen](https://huggingface.co/spaces/facebook/MusicGen) model validated for Unity Sentis. This model creates up to 30 seconds of music in the style given by a text prompt.
For example, you could use it to generate original music tracks for your games.

## How to run this model
* Put the `sentis` and `json` files in the `Assets/StreamingAssets` folder
* Install `com.unity.sentis` version `1.3.0-pre.3` and `com.unity.nuget.newtonsoft-json` packages.
* Put the c# script on the Main Camera
* Put an AudioSource on the Main Camera
* Change the prompt in the script file
* Change the number of seconds in the script file
* Press play and check for results in the console window

## Info
This model is a bit slow at the moment. Please use our [discussion forum](https://discussions.unity.com/c/ai-beta/sentis) to discuss this model or suggest improvements to the code.