Skip to content

Commit

Permalink
[CLEANUP]
Browse files Browse the repository at this point in the history
  • Loading branch information
Your Name committed Oct 9, 2024
1 parent 2ccb246 commit ee240d7
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 70 deletions.
3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "swarms-cloud"
version = "0.4.0"
version = "0.4.1"
description = "Swarms Cloud - Pytorch"
license = "MIT"
authors = ["Kye Gomez <[email protected]>"]
Expand Down Expand Up @@ -51,6 +51,7 @@ hf_transfer = "*"
swarms = "*"
rich = "*"
asyncio = "*"
pulumi = "*"

[tool.poetry.scripts]
swarms-cloud = "swarms_cloud.cli.main:main"
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ huggingface-hub
optimum
auto-gptq
whisperx
pulumi
shortuuid
hf_transfer
swarms
Expand Down
4 changes: 4 additions & 0 deletions swarms_cloud/cli/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ def show_help():
"""
)

# [bold white]add-agent[/bold white] : Add an agent to the marketplace under your name. Must have a Dockerfile + your agent.yaml to publish. Learn more Here: https://docs.swarms.world/en/latest/swarms_cloud/vision/


# Fetch API key from platform
def get_api_key():
Expand Down Expand Up @@ -113,6 +115,8 @@ def main():
check_login()
elif args.command == "read-docs":
redirect_to_docs()
# elif args.command == "add-agent":
# deploy_agent()
else:
console.print("[bold red]Unknown command! Type 'help' for usage.[/bold red]")

Expand Down
Empty file.
13 changes: 7 additions & 6 deletions swarms_cloud/structs/deploy_gcp.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
from typing import Any, Dict

import click
import pulumi
import yaml
from loguru import logger
import pulumi
from pulumi_gcp import cloudrun

# Configure logging
Expand Down Expand Up @@ -71,10 +71,11 @@ def build_and_push_docker_image(
"--dockerfile-path", default="./Dockerfile", help="Path to the Dockerfile"
)
@click.option("--yaml-path", default="./agent.yaml", help="Path to the agent YAML file")
def deploy_agent(
project_id: str, region: str, dockerfile_path: str, yaml_path: str
) -> None:
def deploy_agent(dockerfile_path: str, yaml_path: str) -> None:
try:
project_id = os.getenv("GCP_PROJECT_ID")
region = os.getenv("GCP_REGION")

# Step 1: Validate existence of Dockerfile and agent.yaml
if not check_file_exists(dockerfile_path):
logger.error("Dockerfile is missing, exiting.")
Expand Down Expand Up @@ -140,5 +141,5 @@ def deploy_agent(
raise


if __name__ == "__main__":
deploy_agent()
# if __name__ == "__main__":
# deploy_agent()
62 changes: 0 additions & 62 deletions swarms_cloud/utils/Untitled-1.py

This file was deleted.

5 changes: 4 additions & 1 deletion swarms_cloud/utils/cleanup_terminal.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
import warnings

# Suppress all warnings

# Suppress specific warnings

# Suppress specific warnings (if you want to keep this)
def cleanup_logs():
warnings.filterwarnings("ignore")
warnings.filterwarnings(
"ignore", category=UserWarning, module="pydantic._internal._fields"
)
Expand Down

0 comments on commit ee240d7

Please sign in to comment.