Magic CLI alpha community feedback and questions

You can leave feedback and questions about the alpha test for the magic CLI here, the doc to install and test it is here: https://modul.ar/magic-alpha-doc You can raise issues or errors you're running into here: https://modul.ar/raise-magic-issue
No description
70 Replies
Pablo
Pablo2mo ago
Congrats on the release! I noticed that magic is built ontop of Pixi, what additional features are added ontop of Pixi? I'm trying to understand the difference between magic and pixi
Darin Simmons
Darin Simmons2mo ago
Suggest edit to add: profile’s $PATH (bash, zsh, fish, etc are all supported). You may need to source your shell rc or create a new shell to make sure that magic is in your $PATH. Verifying Installation You can verify magic installation
magic --version
magic --version
Forking and running MAX examples I don't know if I should assume... 🙂 But if I understand this correctly, I do not need to Modular clean and it will install in an environment on the side.
Zac Bowling
Zac Bowling2mo ago
Yeah we use Pixi along with a few other things under-the-hood to power magic to make working with MAX and Mojo a bit easier out of the box. One of the significant features is support for a new mojoproject.toml manifest format (like pyproject.toml) that will be the basis for other tools (stay tuned!). A lot of the things we are working on getting upstreamed into Pixi where it makes sense, though. What is great, however, is that the underlying packages are conda ecosystem compatible, so you can use other frontends like conda, mamba, or Pixi.
Darin Simmons
Darin Simmons2mo ago
FYI: magic --version returned 0.1.1 but magic as a command later on would not be recognized. I then source ~/.bashrc and then magic was recognized.
Zac Bowling
Zac Bowling2mo ago
Yeah on the first install it adds it to your shell but you may have to source to shell's rc file or create a new terminal/shell to get it to pick up 🙂 curl script should print that on first install but easy to miss
Darin Simmons
Darin Simmons2mo ago
that was the odd part, I did close my terminal and start a fresh one. All good, cooking up some Bert now
Pablo
Pablo2mo ago
Great! I'll definintely be checking this out. I saw in the provided document that there may be some rough edges between pixi | magic. Is it not recommended to have both installed on a system? or is it more so not installing mojo/max via pixi but rather via magic
Darin Simmons
Darin Simmons2mo ago
From the instructions "cd max Try to run a model like bert-python-torchscript. Follow the instructions in the README.md file.c cd examples/inference/bert-python-torchscript magic run run.sh " .
That README.md has a anchor link which may potentially be used. The real issue is that it has
Magic instructions
If you are using Magic, you can run the following command:

# Run the MAX Engine example
magic run run.sh
# Run the MAX Serving example
magic run deploy.sh
Magic instructions
If you are using Magic, you can run the following command:

# Run the MAX Engine example
magic run run.sh
# Run the MAX Serving example
magic run deploy.sh
Are you expecting the viewer to do the Magic MAX serving?? Not sure why the viewer goes to the README in the first place as the bert-python-torchscript is part of the max/examples/inference/bert-python-torchscript/.magic/envs/default/lib/python3.11/site-packages/transformers already.
Also, if they end up running serving magic run deploy.sh it fails for Docker(!!).
GitHub
max/examples/inference/bert-python-torchscript at max-conda · modul...
A collection of sample programs, notebooks, and tools which highlight the power of the MAX Platform - modularml/max
Zac Bowling
Zac Bowling2mo ago
having both is totally fine 🙂 they shouldn't have any conflicts. if you find any issues let us know though! ahh yeah, good catch. Yeah the docs for serving are missing some details there in general 🙂
Darin Simmons
Darin Simmons2mo ago
While my computer is downloading llama3... Out of curiousity...Does conda and subsequently magic have a local cache that will pull the model each time for each environment like pip?
Jack Clayton
Jack Clayton2mo ago
Yeah it caches to ~/.cache/modular or $XDG_CACHE_PATH/modular if you have that set
Darin Simmons
Darin Simmons2mo ago
wanders off to check magic --help to see what kind of trouble I can get into
Zac Bowling
Zac Bowling2mo ago
haha have fun. this is an early preview release so let us know if you find anything weird
ModularBot
ModularBot2mo ago
Congrats @Zac Bowling, you just advanced to level 3!
Darin Simmons
Darin Simmons2mo ago
when I run magic add open3d is there do a --no-install kind of thing or more specifically, how would I go about easily adding a requirements list to this environment? Ohhh...it hasn't exactly.... OK, but is there still a way to add it to the environment without installing?
Want results from more Discord servers?
Add your server