Cross-platform Mycroft

Hello everyone,

For the past few months, I have been working on a project that might interest some of you. I am currently trying to make Mycroft cross-platform. Mycroft, initially designed for Linux, is not suited for other operating systems due to several dependencies that are unique to Linux.

I have already made some modifications to address certain aspects of this problem. For example, Padatious normally uses Fann2, which, from what I understand, is not available on Windows. I tried to compile it on Windows without success. After extensive research and consulting with various AIs, I decided to adapt this component by replacing Fann2 with scikit-learn. It seems to work, but there are still some errors to fix. Additionally, the version of Padatious necessary for Mycroft on Windows is padatious-phoenix, which is available via pip.

Another aspect is the file system, particularly regarding configuration files and logs. Mycroft has files scattered in different locations on the system, some even in the Linux root directory, which is obviously not compatible with Windows. I decided to centralize them in dedicated subdirectories within mycroft-core/Mycroft/Config. The same goes for the logs.

Another challenge with the original version of Mycroft for porting to Windows is the use of Bash scripts, which are incompatible with Windows. Therefore, I created temporary Python scripts to replace these Bash scripts. There is still a lot of work to be done, but it is a good start.

I searched online for Windows-adapted versions of Mycroft without success. The only option I found is installing it on the Linux subsystem for Windows. My approach is different: I want Mycroft to function natively on Windows. The goal is to make Mycroft accessible to everyone with simplified configuration and use, and eventually to integrate a graphical interface if desired by users.

I am not a developer; I work on this project in my free time with the help of various AIs that create the scripts for me and provide advice. You can check out my GitHub repository at: http://github.com/MycroftPhoenix. There is still a lot to do, but I believe much has been accomplished already. The repository needs cleaning as it contains many test scripts. If you decide to try it out, I would appreciate your feedback, suggestions, and advice. If you want to participate, everyone is welcome.

Thank you all!

2 Likes

I know @mikejgray recently got Neon and OVOS running in Mac OS; Windows would be very different, but might have some similar issues to overcome.

Non-Linux support hasn’t really been a priority but I love to see broader platform support :slight_smile: !

2 Likes

True, although Windows-native support will be another story altogether. Mac OS is a fully POSIX-compatible OS so all it took was removing any Linux-specific components in favor of general components. With an entirely different kernel in Windows, there would be quite a bit more work to do, including writing some new plugins. Not impossible though, and much less work than it was a year ago!

Glad to hear the work is happening for Mycroft on Windows but please do check out OVOS and Neon on Windows! You may find much of the work you had to do for Mycroft is already done.

2 Likes

OVOS can run on Windows via WSL2, the ovos-installer supports it.

2 Likes

Yeah, but OP mentioned he wants something native, not via WSL2

2 Likes

Thank you for your feedback. Yes, I do want to port Mycroft natively to Windows because not everyone is comfortable with Linux, so with the Linux Subsystem for Windows, I want everyone to be able to enjoy Mycroft as well. Additionally, I believe Mycroft on Windows can lead to faster development for Mycroft and its derivatives because, as you already know, Windows is the most popular platform, so a large number of developers can contribute to it. This version, Mycroft Phoenix, if I manage to make it functional and stable, and multi-platform, if its environment remains heterogeneous, can benefit both projects on Linux, Windows, and Mac OS, on x86 64 or ARM processors, all will benefit from improvements from everyone.

Sounds like a great goal! You may want to give OVOS a try, as it already has stable compatibility with Linux and Mac, and almost all its components are plugins so it’s relatively easy to swap out things that are not compatible with Windows. Making the last portions of the codebase OS-agnostic and writing a few Windows-specific plugins is all that would really need to be done, although I’m not sure how large a task the first part of that could be.

Of course you’re more than welcome to keep working on the original Mycroft codebase, but something to keep in mind - OVOS (and Neon) have already spent a couple of years squashing bugs and refactoring portions to make it more flexible and stable. OVOS is fully compatible with Mycroft skills (although the last version that maintains compatibility is likely to be released this year) and most of those skills have been ported over to be future-proof, received bugfixes, and received significant feature enhancements.

Best of luck and please let us know about your progress!

1 Like

I am going to install both versions of Mycroft, Ovos and Neon, on my computer in two different Conda environments. This will allow me to determine if I prefer to continue with my current path or work on one of the two proposed versions. Testing these two different versions of Mycroft will certainly help me find solutions and inspire me.

Regarding skill compatibility, have Ovos and Neon maintained the same compatibility? Personally, I believe everyone should work together to maintain a minimum level of compatibility. If a new skill system is to be created, all versions should adopt it to avoid the mistakes made by different Linux distributions, which often worked in parallel without maintaining coherence or compatibility. This led hardware manufacturers to not provide real support for Linux.

If we all work in the same direction, it will be beneficial for users. Regardless of the chosen version, the same skills will be available. Also, if possible, skills should be created 100% in Python to ensure cross-platform support. Dependencies in C can be a barrier for certain CPU architectures and operating systems.

Another aspect of Mycroft I have considered is implementing communication functions between devices, whether between Mycroft devices of all versions or between PCs (Windows, Linux, and macOS, even though the latter is technically not a PC). This would allow functions inspired by Alexa, such as sending messages between devices and playing music on groups of devices from different audio sources, including DLNA servers.

I also want to, if possible, port Mycroft to Termux. If the original version of Mycroft is too heavy, I might try to adapt the Mycroft-Dinkum version.

Finally, is anyone working on a native Android version?

I wish you luck, this is no small undertaking.

not to discourage you, but all the individual tasks you want to handle are not easy even for a single experienced developer, i REALLY doubt ChatGPT will get you far, but hey, prove me wrong!

1 Like

I agree and the intent is to continue supporting the same skills/plugins in Neon and OVOS. Mainly, the Neon services add support and backwards-compat with our server implementations (i.e. https://iris.neonaiservices.com)

I believe in practice this is true with the only exception being the Pandora skill from Mycroft days, though I can’t say for sure. Based on the installation/skill management tools we have and are working on, skills should generally be pure Python, but it is worth considering that not all Python packages are cross-platform.

My take on this is that it would be simpler to have a single central instance of the voice assistant (in my case Neon) and a bunch of client devices that connect and offload processing to the one central “Hub”. I’ve started on this in the neon-nodes project; I have some demos in this forum thread.

I don’t believe so. There have been Android projects, but mostly they are client apps that connect back to a core instance running on some other system.

2 Likes

Maybe you should make a poll (questionnaire) before setting off to a such a big endeavor.

In my personal opinion, running privacy oriented software on Windows is an oxymoron.
What I’m trying to say is, that there is probably a very small percentage of privacy oriented Microsoft users who avoid Linux.
Users who are unaware of any other OS then Windows are already using Alexa and never heard of Mycroft :slight_smile:
Probably Android would be a better choice of the platform, as there are some distributions like LineageOS that are stripped of Google…

3 Likes

That’s a good thought! @vanja1 if @Steve_Chretien or you want an admin assist with posting a poll, I am happy to help. It’s not difficult to make a post that is a poll, but it may be set up to require an admin or “leader” level user to create one. I cannot recall how things are set up right now. In any case, I’m happy to help and happy to “pin” such a poll so it gets more attention, if you two would like to put some thought into what would be wise to ask. :slight_smile:

A little demo video: ovos-windows.mp4 - Google Drive

took the liberty of uploading this on youtube also

2 Likes

I agree with you that Android would be the perfect platform. A lot of people use Android devices, and having a standalone version of Mycroft on Android would be great. But I wonder, is the current skill system compatible? Another concern of mine is that I’m not a programmer; I use AI to write scripts on demand. I’m learning Python little by little, but with attention deficit disorder, it’s not exactly easy. My concentration is very limited. I would say my strength is my imagination. I imagine all kinds of concepts that could be really cool but are rather complicated to realize. As for Mycroft on Windows, I think people might be interested. Not everyone has the necessary knowledge to build a smart speaker. Most Windows users are… users. Cortana has never really been successful, but there was no Cortana speaker. With Mycroft, it is possible to build a smart speaker, and I think there is material available to facilitate the task. I also believe that if Mycroft is ported to Windows, it can attract a new community of developers to join the project, developers who only work on Windows, and who knows, maybe a C language adaptation could emerge. Whether I manage to get my version of Mycroft to work or work on another version, I believe Mycroft needs to be ported to Windows. I looked online, and several users have asked when the Windows version will be available, which means there is interest. Making Mycroft natively available on Windows can attract new users. Personally, I think Mycroft on the Linux subsystem for Windows is impractical. It’s an operating system within an operating system, which consumes more system resources. Additionally, I’ve had issues with the Linux subsystem for Windows and lost content. Linux isn’t made to integrate with Windows. I was an IT technician for years, but not everyone has that knowledge, so even if users had access to it from Windows, it would bring a lot of problems to regular users.

Hi Mikejgray,

Small update regarding progress: it’s moving slowly. I haven’t yet found the reason why Mycroft doesn’t respond to me. I haven’t adapted speech synthesis and recognition to Windows yet, so I’m using the CLI. But I managed to have ChatGPT create a script that uses Narrator’s speech synthesis. Previously, I only had access to the speech synthesis available on older versions of Windows, which doesn’t sound better than Microsoft Agent’s speech synthesis on Windows XP. I can’t get the Windows speech synthesis to work from the test script on the Linux subsystem for Windows, so that’s another reason to use it natively rather than through a workaround platform. It’s great news that you managed to get OVOS running natively on Windows. I’m glad I inspired the test of OVOS on Windows, which was a success. Bringing OVOS to Windows opens up new development partnership opportunities. It’s important to keep the project homogeneous, ensuring that the modifications made to make it compatible with Windows are configurable so that a single version is compatible across platforms.

I will install OVOS on Windows and fix the version of Padatious that I modified to test distinctive skills, and also try to add Narrator’s speech synthesis. As I wrote to NeonClary, which was actually a response to several people, my strength is mostly my imagination, my ability to envision concepts. For example, enabling communication between different local devices for various functionalities, some inspired by Alexa, such as making announcements between devices, launching music playback on synchronized device groups, and possibly integrating OVOS, Neon, or Mycroft (all members of the same family) into Kodi to allow the same type of interaction as with Fire TV and interoperability between Fire TV and Echo devices. So many possibilities—this project is not just a voice assistant, but a multi-service platform for private and secure embedded voice intelligence. All it takes is imagination. :slight_smile:

1 Like

There’s a video of OVOS running on Windows above…no WSL

4 Likes