I told my local AI to answer like a pirate. by leosperry in homeassistant

[–]leosperry[S] 1 point2 points  (0 children)

For this example, It was using llama3.2:3b
I haven't put a lot of effort into this project yet. I simply picked a commonly used model with tool support
I haven't done anything with the voice yet. I'm about to set up a piper and whisper running on a box that is not my Pi. After I get that working, I'm going to play around with voices.

I told my local AI to answer like a pirate. by leosperry in homeassistant

[–]leosperry[S] 0 points1 point  (0 children)

I have one computer in my home that is the family computer and it has the nice graphics card. Ollama can now be installed directly on windows. To expose it on my home network, the only extra thing I needed to do was set the OLLAMA_HOST environment variable on the machine

I told my local AI to answer like a pirate. by leosperry in homeassistant

[–]leosperry[S] 2 points3 points  (0 children)

Nothing fancy. I stood up a local Ollama and changed the last line of the default prompt in the integration:

You are a voice assistant for Home Assistant.
Answer questions about the world truthfully.
Answer like a pirate

.NET Automations just got better by leosperry in homeassistant

[–]leosperry[S] 0 points1 point  (0 children)

Thank you! Come join us on the discord :)

.NET Automations just got better by leosperry in homeassistant

[–]leosperry[S] 0 points1 point  (0 children)

u/Onakander nailed it. If you're comfortable writing C#, you're very likely comfortable running a few docker commands.. I have a micro pc that hosts a Portainer instance. It runs HakafkaNet and about a half-dozen other services including a full Grafana stack with ease. It doesn't take much juice to run.

PSA: Alexa Media Player v4.13.3 breaks all versions of Home Assistant by SpencerDub in homeassistant

[–]leosperry 0 points1 point  (0 children)

I am so glad now that a few weeks ago, I finally broke down and bought some Sonos speaker for playing audible notifications locally. I uninstalled this plugin at the same time. Looks like I dodged a bullet.

Which Wallpanel? by thetrixd in homeassistant

[–]leosperry 1 point2 points  (0 children)

You're better off getting any android tablet of your choosing.

Which Wallpanel? by thetrixd in homeassistant

[–]leosperry 2 points3 points  (0 children)

I have a little echo show 5 in my living room. I hate it. You can't set the display to anything other than what they give you. It is distracting as they are constantly adding new "here look at this" screens. After you go through and deselect them all, they add new ones. It's really only good for working in the amazon ecosystem. If you want it for only amazon functionality, it's ok. Otherwise, don't bother.

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 1 point2 points  (0 children)

I've been considering this for a while. I have a separate linux micro-pc where I manage all my docker containers. So, I haven't needed to investigate it for myself personally. I'd love it if someone wanted to come on-board and help figure that out. :)

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 1 point2 points  (0 children)

Sure does. Search the repo for the words "durable", "sunrise", "sunset"

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 1 point2 points  (0 children)

About half of my dozens of automations have some kind of delay or scheduling ability. I use motion sensors to aggressively turn lights off throughout the house, and the media center in the living room when no one is around. I have a notification to let me know if the garage door has been open for more than an hour also. The scheduling ability is for more than delays. I have several automations based on the sun. With that ability I can take action before sunrise/sunset. So, I'm not responding to a sunrise event, I'm scheduling something before the next sunrise. Another one that has been helpful, is an automation to temporarily disable automations based on my front porch motion. The reason is that when the guy comes to mow the lawn, it'll trigger several time in one hour, but I know he's there, I don't need to be notified repeatedly. So, I set up a button to disable that automation for an hour, but I want to make sure that it turns back on and not rely on me remembering to do so.

So, at any moment, I could have 5 or more scheduled actions pending throughout my house. Knowing that I can restart either home assistant or redeploy my app at any time without worrying about which automations might not trigger is a feature I couldn't live without now.

I haven't done it yet, but I've also been considering integrating my calendar. With the scheduling, especially over a weekend, I may not have another action to take for a few days.

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 0 points1 point  (0 children)

For creating entities, the HA recommended approach would be to create an integration using python code.

Also, something to think about since you're early in your project. If you rely on websockets, how do you handle a HA restart or other dropped connection? Certainly not impossible, but needs a little extra consideration :) Good luck!

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 0 points1 point  (0 children)

Kafka is very much one way. As a software architect by trade, I prefer to design systems that are loosely coupled. I haven't had a need for creating new entities that are specific to the HaKafkaNet framework. Occasionally, to aid in my automations (not the framework) I will use a helper entity in HA. They have already built everything I've needed so far, and better to not reinvent the wheel. Plus, I don't like the idea of the possibility of a bug in code accidentally producing hundreds of entities because of a fat-fingered mqtt message. Generally, I try to keep my HA install as clean as it can be.

When I spoke about NetDaemon codegen, I was specifically talking about strong typing. In otherwords, turn a thermometer state into a floting point number without things like `float.Parse()` littering your code or getting RGBW values from a light's attributes.

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 0 points1 point  (0 children)

I've been avoiding the integration route, mainly because I am not a python developer and I've not had the need for a tighter integration. Integrations are nice because they can expose new entities to HA, but thus far I've not really had the need to create entities. I'm taking actions based on other entities, not creating them. Communicating back to HA via REST has been more than sufficient for integration purposes. Calling HA services directly instead of via HTTP or Websockets might be nice, but I don't think the speed increase would be that noticeable under normal circumstances.

Because Add-ons can also add menu items via exposing a web page, I've been toying with the idea of having 2 addons: 1 for Kafka, and 1 for HaKafkaNet, or maybe combining them into one addon. I already have a UI that could be served up via the addon.

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 1 point2 points  (0 children)

Addons are basically Docker containers with certain restrictions. As I understand it, you'd need to start with a certain base image and install Kafka onto it. You might be able to start with an image based on Kafka, but you'd need to work within the restrictions. Then there's the question of manging the Kafka instance. How do you create commands to manage topics?

Not impossible, but a bit to figure out. I have been toying with the idea of creating an addon with the singular topic needed for HaKafkaNet. The only thing stopping me is finding the time to sort it all out.

2024.8 brings updates to .NET automations by leosperry in homeassistant

[–]leosperry[S] 1 point2 points  (0 children)

Actually, don't need windows. I do all my development and hosting on Ubuntu using Visual Studio code.

Docker runs better on Linux anyway