| --- |
| title: Beam App |
| emoji: 🤖 |
| colorFrom: indigo |
| colorTo: pink |
| sdk: static |
| app_file: README.md |
| pinned: false |
| --- |
| |
| # How to Use |
|
|
| Follow these steps to set up and deploy JVCGPT Model on [Beam](https://beam.cloud/) |
|
|
| --- |
|
|
| ## 1. Clone the repository |
| ```shell |
| git clone https://huggingface.co/spaces/Error410/beam-app |
| ``` |
|
|
| --- |
|
|
| ## 2. Create an Account on Beam |
| Sign up at [Beam](https://platform.beam.cloud/). |
|
|
| --- |
|
|
| ## 3. Set Up a Python Virtual Environment |
| Create and activate a Python virtual environment: |
| ```shell |
| python3 -m venv .venv && source .venv/bin/activate |
| ``` |
|
|
| --- |
|
|
| ## 4. Install Required Packages |
| Install the dependencies listed in the `requirements.txt` file: |
| ```shell |
| pip install -r requirements.txt |
| ``` |
|
|
| --- |
|
|
| ## 5. Register Your Beam API Token |
| Retrieve your API token from the [API Keys](https://platform.beam.cloud/settings/api-keys) page on the Beam dashboard. Then, configure Beam with your token: |
| ```shell |
| beam configure default --token [TOKEN] |
| ``` |
|
|
| --- |
|
|
| ## 6. Deploy Your Application on Beam |
| Deploy your application using the following command: |
| ```shell |
| beam deploy app.py:server |
| ``` |
|
|
| --- |
|
|
| ## 7. Call the Stream Endpoint |
| Make a POST request to your deployed stream endpoint: |
| ```shell |
| curl -X POST 'https://[ID].app.beam.cloud/stream' \ |
| -H 'Connection: keep-alive' \ |
| -H 'Content-Type: application/json' \ |
| -H 'Authorization: Bearer [TOKEN]' \ |
| -d '{"prompt": "", "posts_count": 5}' |
| ``` |
|
|
| --- |
|
|
| ## 8. Enjoy Your Free Trial |
| Enjoy 15 hours of free trial usage on Beam! |
|
|