Skip to main content

SDK and CLI for building Horizon Desk AI Plugins

Project description

horizondesk SDK

This SDK provides the official interface for building plugins for Horizon Desk. It allows developers to extend OmniAgent's capabilities with custom tools and connect external AI workers.

Installation

pip install horizondesk

Quick Start: Create your first plugin

1. Initialize

Run the following command to scaffold a new plugin project:

horizondesk init MyAmazingPlugin

2. Define a Tool

Edit main.py to create your own tools:

from horizondesk import BaseTool, HorizonPlugin

class WeatherTool(BaseTool):
    def __init__(self):
        super().__init__("GetWeather", "Gets current weather for a city. Input: 'city'.")

    def execute(self, city=None, payload=None):
        return f"It is 22°C and sunny in {city}."

def register_tools(agent):
    plugin = HorizonPlugin("MyAmazingPlugin")
    plugin.add_tool(WeatherTool())
    plugin.register_all(agent)

3. Run the Workshop

Launch the high-fidelity GUI Workshop to test your plugin:

horizondesk run horizon_plugin.raf

Security & Privacy

  • SecretStorage: Always use SecretStorage.get_secret("KEY") to access API keys. Do not hardcode them.
  • Redaction: Use SecretStorage.redact_pii(text) before sending data to external workers.
  • Auditing: All plugin tools are visible to the user and subject to manual intervention (Alt+F7).

Connecting External Agents

To link your own AI worker, create a tool that performs a secure HTTP request to your backend:

import requests
from horizondesk import BaseTool, SecretStorage

class ExternalBrainBridge(BaseTool):
    def __init__(self):
        super().__init__("AskMyBot", "Consults my specialized AI model.")

    def execute(self, **kwargs):
        api_key = SecretStorage.get_secret("MY_BOT_API_KEY")
        response = requests.post("https://my-api.com/v1/chat", json=kwargs, headers={"Auth": api_key})
        return response.json().get("reply")

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

horizondesk-1.1.0.tar.gz (12.5 kB view details)

Uploaded Source

Built Distribution

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

horizondesk-1.1.0-py3-none-any.whl (12.9 kB view details)

Uploaded Python 3

File details

Details for the file horizondesk-1.1.0.tar.gz.

File metadata

  • Download URL: horizondesk-1.1.0.tar.gz
  • Upload date:
  • Size: 12.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.9

File hashes

Hashes for horizondesk-1.1.0.tar.gz
Algorithm Hash digest
SHA256 e0e7bd6ba394836543709e29d47783e1828de0d68cf30e9358d756f422e11fa4
MD5 050f5dc5970441f1b1f39357be25495c
BLAKE2b-256 d716b42ec863c5978abaf33d3f3e5aea3aae50aad1a96d9d8bbfaa27458190ff

See more details on using hashes here.

File details

Details for the file horizondesk-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: horizondesk-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 12.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.9

File hashes

Hashes for horizondesk-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 57cc78c6d7a926759f99e0bdcee284d6163a8d1933d10f89a13c52b2009a3ea9
MD5 9038e403f7c61c4e243b93ea0252e978
BLAKE2b-256 a4cbe45bee41aeecb068ce43f9cdc791a496ee776137b1e1fa4b6aef1a073bf1

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