Skip to main content

Load YAML-defined components directly from GitHub repositories.

Project description

Swarmauri Logo

PyPI - Downloads Hits PyPI - Python Version PyPI - License PyPI - swarmauri_tool_githubloader


Swarmauri Tool GithubLoader

Load YAML-defined components directly from GitHub repositories.

Installation

pip install swarmauri_tool_githubloader

Usage

from swarmauri_tool_githubloader import GithubLoadedTool

# Load a tool from GitHub
tool = GithubLoadedTool(
    owner="myorg",
    repo="myrepo",
    path="tools/addition.yaml",
)

# Use like any other tool
result = tool(x=1, y=2)

Options

Customize how the loader fetches your component:

  • branch – Branch to read from (defaults to "master").
  • commit_ref – Specific commit SHA; overrides branch when provided.
  • token – GitHub token for private repositories.
  • use_cache – Set to False to reload the component on every call.

Advanced examples

Fetch from a branch and pin a commit:

tool = GithubLoadedTool(
    owner="myorg",
    repo="myrepo",
    path="tools/addition.yaml",
    branch="develop",
    commit_ref="0123456789abcdef",
)

Load from a private repository with caching disabled:

import os

tool = GithubLoadedTool(
    owner="myorg",
    repo="private-repo",
    path="tools/addition.yaml",
    token=os.environ["GITHUB_TOKEN"],
    use_cache=False,
)

Want to help?

If you want to contribute to swarmauri-sdk, read up on our guidelines for contributing that will help you get started.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

swarmauri_tool_githubloader-0.9.0.dev35.tar.gz (7.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file swarmauri_tool_githubloader-0.9.0.dev35.tar.gz.

File metadata

  • Download URL: swarmauri_tool_githubloader-0.9.0.dev35.tar.gz
  • Upload date:
  • Size: 7.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for swarmauri_tool_githubloader-0.9.0.dev35.tar.gz
Algorithm Hash digest
SHA256 7f1f36d4f9f3704c310d410c59cfd64a09c2fc6d37daa566f95999c2842dc799
MD5 98410071f98a96ea06f5022a93d7e51e
BLAKE2b-256 87dde1ddf188cf3846a2d3df5ce4c2635a8f8eafc5751ed819cb5eb23b5fd0d0

See more details on using hashes here.

File details

Details for the file swarmauri_tool_githubloader-0.9.0.dev35-py3-none-any.whl.

File metadata

  • Download URL: swarmauri_tool_githubloader-0.9.0.dev35-py3-none-any.whl
  • Upload date:
  • Size: 8.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for swarmauri_tool_githubloader-0.9.0.dev35-py3-none-any.whl
Algorithm Hash digest
SHA256 2a24d2ac75ee1e14f0365f514df0db3d44ed9d5e5534b2e6a80a7097a116881b
MD5 98054380c4bb4b840e26b012d62d16e6
BLAKE2b-256 4b546364126c5aedffa735adf6b2e267fdb76d2a0ee19599a1fbc020d4e92b1b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page