wabee


Namewabee JSON
Version 0.2.6 PyPI version JSON
download
home_pageNone
SummaryWabee AI Software Development Kit
upload_time2025-01-07 00:58:00
maintainerDevelopers
docs_urlNone
authorDevelopers
requires_python<3.12,>=3.10
licenseApache License V2
keywords wabee wabee ai ai agents generative ai llm agents
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ![PyPI - Downloads](https://img.shields.io/pypi/dm/wabee)
![PyPI - Format](https://img.shields.io/pypi/format/wabee)
![PyPI - Implementation](https://img.shields.io/pypi/implementation/wabee)
![PyPI - License](https://img.shields.io/pypi/l/wabee)
![PyPI - Status](https://img.shields.io/pypi/status/wabee)
![PyPI - Version](https://img.shields.io/pypi/v/wabee)
![PyPI - Wheel](https://img.shields.io/pypi/wheel/wabee)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/wabee)

![Wabee AI](https://wabee-public-assets.s3.amazonaws.com/images/wabee-small-box-white.png)

# Wabee SDK

**wabee-sdk** is a Python module for development of modules and extensions for the Wabee agentic AI platform.

## Installation

```bash
pip install wabee
```

## Command Line Interface (CLI)

The Wabee SDK includes a powerful CLI tool to streamline the development of Wabee agent tools.

### Creating a New Tool

Create a new tool using the interactive CLI:

```bash
wabee tools create
```

This command will prompt you for:
- Tool name
- Tool type (simple or complete)
- Tool description
- Initial version

#### Tool Types

1. **Simple Tool**: 
   - Ideal for straightforward, single-function tools
   - Uses the `@simple_tool` decorator
   - Less boilerplate code
   - Perfect for quick implementations

2. **Complete Tool**:
   - Full class implementation
   - More control over tool behavior
   - Better for complex tools with multiple operations
   - Includes error handling infrastructure

### Building Tool Containers

Build a tool into a container image:

```bash
wabee tools build <tool_directory> [options]
```

Options:
- `--image`: Specify custom image name (default: toolname:latest)

Example:
```bash
wabee tools build ./my-tool
```

## Tool Project Structure

When you create a new tool, the following structure is generated:

```
my_tool/
├── my_tool_tool.py      # Main tool implementation
├── requirements.txt     # Python dependencies
├── server.py           # gRPC server implementation
└── toolspec.yaml       # Tool specification and metadata
```

## RPC Server

Each built tool runs as a gRPC server that exposes a standardized interface for tool execution. The server:

- Listens on port 50051 by default (configurable via WABEE_GRPC_PORT)
- Automatically handles input validation using your Pydantic schemas
- Provides standardized error handling and reporting
- Supports streaming responses for long-running operations

When you build a tool with `wabee tools build`, the resulting container image includes:
- Your tool implementation
- All dependencies
- A pre-configured gRPC server
- Generated protocol buffers for type-safe communication

You can run the built container with:
```bash
docker run -p 50051:50051 mytool:latest
```

### toolspec.yaml

The tool specification file contains metadata about your tool:

```yaml
tool:
  name: MyTool
  description: Your tool description
  version: 0.1.0
  entrypoint: my_tool_tool.py
```

### Requirements

- Python >=3.11,<3.12
- Docker (for building containers)
- Internet connection (for downloading S2I builder)

## Development Examples

### Simple Tool Example

```python
from pydantic import BaseModel
from wabee.tools.simple_tool import simple_tool

class MyToolInput(BaseModel):
    message: str

@simple_tool(schema=MyToolInput)
async def my_tool(input_data: MyToolInput) -> str:
    return f"Processed: {input_data.message}"
```

### Complete Tool Example

```python
from typing import Optional, Type
from pydantic import BaseModel
from wabee.tools.base_tool import BaseTool
from wabee.tools.tool_error import ToolError

class MyToolInput(BaseModel):
    message: str

class MyTool(BaseTool):
    args_schema: Type[BaseModel] = MyToolInput

    async def execute(self, input_data: MyToolInput) -> tuple[Optional[str], Optional[ToolError]]:
        try:
            result = f"Processed: {input_data.message}"
            return result, None
        except Exception as e:
            return None, ToolError(type="EXECUTION_ERROR", message=str(e))
```

## Contributing

Suggestions are welcome! Please feel free to submit bug reports or feedbacks as a Github issues.

## Links

- Website: https://wabee.ai/
- Documentation: https://documentation.wabee.ai
- GitHub: https://github.com/wabee-ai/wabee-sdk


            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "wabee",
    "maintainer": "Developers",
    "docs_url": null,
    "requires_python": "<3.12,>=3.10",
    "maintainer_email": "developers@wabee.ai",
    "keywords": "wabee, wabee ai, ai agents, generative ai, llm agents",
    "author": "Developers",
    "author_email": "developers@wabee.ai",
    "download_url": "https://files.pythonhosted.org/packages/8e/95/a6e2272b5a9dbc67cea82488f6b50849312c8b08096c8d1a403f16f692d8/wabee-0.2.6.tar.gz",
    "platform": null,
    "description": "![PyPI - Downloads](https://img.shields.io/pypi/dm/wabee)\n![PyPI - Format](https://img.shields.io/pypi/format/wabee)\n![PyPI - Implementation](https://img.shields.io/pypi/implementation/wabee)\n![PyPI - License](https://img.shields.io/pypi/l/wabee)\n![PyPI - Status](https://img.shields.io/pypi/status/wabee)\n![PyPI - Version](https://img.shields.io/pypi/v/wabee)\n![PyPI - Wheel](https://img.shields.io/pypi/wheel/wabee)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/wabee)\n\n![Wabee AI](https://wabee-public-assets.s3.amazonaws.com/images/wabee-small-box-white.png)\n\n# Wabee SDK\n\n**wabee-sdk** is a Python module for development of modules and extensions for the Wabee agentic AI platform.\n\n## Installation\n\n```bash\npip install wabee\n```\n\n## Command Line Interface (CLI)\n\nThe Wabee SDK includes a powerful CLI tool to streamline the development of Wabee agent tools.\n\n### Creating a New Tool\n\nCreate a new tool using the interactive CLI:\n\n```bash\nwabee tools create\n```\n\nThis command will prompt you for:\n- Tool name\n- Tool type (simple or complete)\n- Tool description\n- Initial version\n\n#### Tool Types\n\n1. **Simple Tool**: \n   - Ideal for straightforward, single-function tools\n   - Uses the `@simple_tool` decorator\n   - Less boilerplate code\n   - Perfect for quick implementations\n\n2. **Complete Tool**:\n   - Full class implementation\n   - More control over tool behavior\n   - Better for complex tools with multiple operations\n   - Includes error handling infrastructure\n\n### Building Tool Containers\n\nBuild a tool into a container image:\n\n```bash\nwabee tools build <tool_directory> [options]\n```\n\nOptions:\n- `--image`: Specify custom image name (default: toolname:latest)\n\nExample:\n```bash\nwabee tools build ./my-tool\n```\n\n## Tool Project Structure\n\nWhen you create a new tool, the following structure is generated:\n\n```\nmy_tool/\n\u251c\u2500\u2500 my_tool_tool.py      # Main tool implementation\n\u251c\u2500\u2500 requirements.txt     # Python dependencies\n\u251c\u2500\u2500 server.py           # gRPC server implementation\n\u2514\u2500\u2500 toolspec.yaml       # Tool specification and metadata\n```\n\n## RPC Server\n\nEach built tool runs as a gRPC server that exposes a standardized interface for tool execution. The server:\n\n- Listens on port 50051 by default (configurable via WABEE_GRPC_PORT)\n- Automatically handles input validation using your Pydantic schemas\n- Provides standardized error handling and reporting\n- Supports streaming responses for long-running operations\n\nWhen you build a tool with `wabee tools build`, the resulting container image includes:\n- Your tool implementation\n- All dependencies\n- A pre-configured gRPC server\n- Generated protocol buffers for type-safe communication\n\nYou can run the built container with:\n```bash\ndocker run -p 50051:50051 mytool:latest\n```\n\n### toolspec.yaml\n\nThe tool specification file contains metadata about your tool:\n\n```yaml\ntool:\n  name: MyTool\n  description: Your tool description\n  version: 0.1.0\n  entrypoint: my_tool_tool.py\n```\n\n### Requirements\n\n- Python >=3.11,<3.12\n- Docker (for building containers)\n- Internet connection (for downloading S2I builder)\n\n## Development Examples\n\n### Simple Tool Example\n\n```python\nfrom pydantic import BaseModel\nfrom wabee.tools.simple_tool import simple_tool\n\nclass MyToolInput(BaseModel):\n    message: str\n\n@simple_tool(schema=MyToolInput)\nasync def my_tool(input_data: MyToolInput) -> str:\n    return f\"Processed: {input_data.message}\"\n```\n\n### Complete Tool Example\n\n```python\nfrom typing import Optional, Type\nfrom pydantic import BaseModel\nfrom wabee.tools.base_tool import BaseTool\nfrom wabee.tools.tool_error import ToolError\n\nclass MyToolInput(BaseModel):\n    message: str\n\nclass MyTool(BaseTool):\n    args_schema: Type[BaseModel] = MyToolInput\n\n    async def execute(self, input_data: MyToolInput) -> tuple[Optional[str], Optional[ToolError]]:\n        try:\n            result = f\"Processed: {input_data.message}\"\n            return result, None\n        except Exception as e:\n            return None, ToolError(type=\"EXECUTION_ERROR\", message=str(e))\n```\n\n## Contributing\n\nSuggestions are welcome! Please feel free to submit bug reports or feedbacks as a Github issues.\n\n## Links\n\n- Website: https://wabee.ai/\n- Documentation: https://documentation.wabee.ai\n- GitHub: https://github.com/wabee-ai/wabee-sdk\n\n",
    "bugtrack_url": null,
    "license": "Apache License V2",
    "summary": "Wabee AI Software Development Kit",
    "version": "0.2.6",
    "project_urls": null,
    "split_keywords": [
        "wabee",
        " wabee ai",
        " ai agents",
        " generative ai",
        " llm agents"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a183a459e81ebe06c44663712e0f72d46228ac60df766851b3a2e225e85efac0",
                "md5": "c587d2abbc75610b118cd54d1e3fabac",
                "sha256": "a45b7f207f6a743f525498bd825f8455aecbfb5ac97afb90b97c04006ce67bfc"
            },
            "downloads": -1,
            "filename": "wabee-0.2.6-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "c587d2abbc75610b118cd54d1e3fabac",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<3.12,>=3.10",
            "size": 28724,
            "upload_time": "2025-01-07T00:57:59",
            "upload_time_iso_8601": "2025-01-07T00:57:59.100610Z",
            "url": "https://files.pythonhosted.org/packages/a1/83/a459e81ebe06c44663712e0f72d46228ac60df766851b3a2e225e85efac0/wabee-0.2.6-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "8e95a6e2272b5a9dbc67cea82488f6b50849312c8b08096c8d1a403f16f692d8",
                "md5": "b9192e7cba045f5b934a31791fbb774e",
                "sha256": "388165658003be157a7319cc31ef28b4c490b06d22627981c5aed2bf27c922f1"
            },
            "downloads": -1,
            "filename": "wabee-0.2.6.tar.gz",
            "has_sig": false,
            "md5_digest": "b9192e7cba045f5b934a31791fbb774e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<3.12,>=3.10",
            "size": 23969,
            "upload_time": "2025-01-07T00:58:00",
            "upload_time_iso_8601": "2025-01-07T00:58:00.412409Z",
            "url": "https://files.pythonhosted.org/packages/8e/95/a6e2272b5a9dbc67cea82488f6b50849312c8b08096c8d1a403f16f692d8/wabee-0.2.6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-01-07 00:58:00",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "wabee"
}
        
Elapsed time: 0.97786s