Skip to main content

Add your description here

Project description

English | 中文

Installation

  1. Install package:
uv pip install hero-core hero-tools 
  1. Quickly Start
from hero import Hero, Model, Tool
from hero_tools import crewl_web, download_file


default_model = Model(
    model_name="deepseek",
    model_url="https://api.example.com/v1",
    model_api_key="api-key",
)

hero = Hero(
    name="hero",
    model=default_model,
)

tool = Tool()

@hero.tool("add")
def add_func(a, b):
    """
    <desc>Addition calculator</desc>
    <params>
        <a type="number">addend a</a>
        <b type="number">addend b</b>
    </params>
    <example>
        {
            "tool": "add",
            "params": {
                "a": 1, 
                "b": 2
            }
        }
    </example>
    """
    return a + b

hero.add_tool(crewl_web, download_file, add_func)

hero.run(question="some question")

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

hero_core-0.1.1.tar.gz (75.1 kB view details)

Uploaded Source

Built Distribution

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

hero_core-0.1.1-py3-none-any.whl (92.3 kB view details)

Uploaded Python 3

File details

Details for the file hero_core-0.1.1.tar.gz.

File metadata

  • Download URL: hero_core-0.1.1.tar.gz
  • Upload date:
  • Size: 75.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for hero_core-0.1.1.tar.gz
Algorithm Hash digest
SHA256 aaaeec4bc8d4a2339b065ebcb7f5f388f764fe25782e99d78ddfea35ae314be0
MD5 3cafcd292dd37d1783b8fac77d559a58
BLAKE2b-256 a62a1facda0a2475858df54c5a655b39186cff7bf044c906b532187dd8023e0d

See more details on using hashes here.

File details

Details for the file hero_core-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: hero_core-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 92.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for hero_core-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a204158f9b568e5934c5914cc9ad89b73f5e03731f902e96df11dfc309d54228
MD5 d2757e454ad4846f8f4cf2cbb9a2af9a
BLAKE2b-256 046ef5063c698f3e326c2bc743ad9519c92db40d4848ab5aa48a2ceed766550d

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