Skip to content

Commit

Permalink
Merge pull request #158 from OpenVoiceOS/release-1.3.1a1
Browse files Browse the repository at this point in the history
Release 1.3.1a1
  • Loading branch information
JarbasAl authored Dec 29, 2024
2 parents f06819d + 241fd13 commit 1159005
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 14 deletions.
6 changes: 3 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Changelog

## [1.3.0a1](https://github.com/OpenVoiceOS/ovos-bus-client/tree/1.3.0a1) (2024-12-28)
## [1.3.1a1](https://github.com/OpenVoiceOS/ovos-bus-client/tree/1.3.1a1) (2024-12-29)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-bus-client/compare/1.2.0...1.3.0a1)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-bus-client/compare/1.3.0...1.3.1a1)

**Merged pull requests:**

- feat:hivemind-plugin-manager [\#155](https://github.com/OpenVoiceOS/ovos-bus-client/pull/155) ([JarbasAl](https://github.com/JarbasAl))
- fix: missing hivemind entrypoint in setup.py [\#157](https://github.com/OpenVoiceOS/ovos-bus-client/pull/157) ([JarbasAl](https://github.com/JarbasAl))



Expand Down
24 changes: 17 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,37 @@

This module is a simple interface for the OVOS messagebus and can be used to connect to OVOS, send messages and react to messages sent by the OpenVoiceOS system.

---

## MycroftBusClient()
## 📡 HiveMind Integration

This project includes a native [hivemind-plugin-manager](https://github.com/JarbasHiveMind/hivemind-plugin-manager) integration, providing seamless interoperability with the HiveMind ecosystem.

- **Agent Protocol**: Provides `hivemind-ovos-agent-plugin` allowing to connect satellites to OVOS

---

## 🐍 Python Usage

### MycroftBusClient()

The `MycroftBusClient()` object can be setup to connect to any host and port as well as any endpont on that host. this makes it quite versitile and will work on the main bus as well as on a gui bus. If no arguments are provided it will try to connect to a local instance of OVOS on the default endpoint and port.

> NOTE: we kept the original pre-fork class name for compatibility reasons
## Message()
### Message()

The `Message` object is a representation of the messagebus message, this will always contain a message type but can also contain data and context. Data is usually real information while the context typically contain information on where the message originated or who the intended recipient is.

```python
Message('MESSAGE_TYPE', data={'meaning': 42}, context={'origin': 'A.Dent'})
```

## Examples
### Examples

Below are some a couple of simple cases for sending a message on the bus as well
as reacting to messages on the bus
Below are some a couple of simple cases for sending a message on the bus as well as reacting to messages on the bus

### Sending a message on the bus.
#### Sending a message on the bus.

```python
from ovos_bus_client import MessageBusClient, Message
Expand All @@ -35,7 +45,7 @@ print('Sending speak message...')
client.emit(Message('speak', data={'utterance': 'Hello World'}))
```

### Catching a message on the messagebus
#### Catching a message on the messagebus

```python
from ovos_bus_client import MessageBusClient, Message
Expand Down
4 changes: 2 additions & 2 deletions ovos_bus_client/version.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# START_VERSION_BLOCK
VERSION_MAJOR = 1
VERSION_MINOR = 3
VERSION_BUILD = 0
VERSION_ALPHA = 0
VERSION_BUILD = 1
VERSION_ALPHA = 1
# END_VERSION_BLOCK
6 changes: 4 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ def required(requirements_file):


def get_version():
""" Find the version of ovos-core"""
version = None
""" Find the version of the package"""
version_file = os.path.join(BASEDIR, 'ovos_bus_client', 'version.py')
major, minor, build, alpha = (None, None, None, None)
with open(version_file) as f:
Expand All @@ -45,6 +44,8 @@ def get_version():
with open(os.path.join(BASEDIR, "README.md"), "r") as f:
long_description = f.read()

PLUGIN_ENTRY_POINT = 'hivemind-ovos-agent-plugin=ovos_bus_client.hpm:OVOSProtocol'

setup(
name='ovos-bus-client',
version=get_version(),
Expand Down Expand Up @@ -72,6 +73,7 @@ def get_version():
'Programming Language :: Python :: 3',
],
entry_points={
'hivemind.agent.protocol': PLUGIN_ENTRY_POINT,
'console_scripts': [
'ovos-listen=ovos_bus_client.scripts:ovos_listen',
'ovos-speak=ovos_bus_client.scripts:ovos_speak',
Expand Down

0 comments on commit 1159005

Please sign in to comment.