Potassium
The code you run on GPUs
Potassium is an open-source HTTP serving framework built for AI, sponsored by Banana.
Quickstart:
Installation
The fastest way to get up and running is to use the Banana CLI, which downloads and runs your first model.
Install the CLI with pip
Create a new project directory with
Start the dev server
Call your local API (from a separate terminal)
🎉 Congrats! You've ran a local inference on your Potassium backend, with a BERT model
Making it your own
app.py is the core of Potassium, and where you'll be adding your custom code and models.
Read more about it and Potassium here:
pageapp.pyThe banana cli
also provides these files:
requirements.txt - python package management
download.py - a script ran at build-time to download models
Dockerfile - build steps, generally can be ignored unless you know what you're doing
Deploying
Push your Potassium app to Github with the include Dockerfile. It must be at the root of the repo, for now. (monorepo support coming soon)
Click "+ New MODEL" in the banana app, select your new repo, and deploy
Next, can then call your BERT hello world model from the SDKs, using the below json as model_inputs:
And the SDK will return outputs such as:
Don't want to use Potassium? You can deploy any Docker workload onto Banana GPUs. Follow this guide to go beyond the Potassium framework and build your own Banana-compatible repo from scratch.
Last updated