Camera, Frigate: Intelligent AI-powered notifications

Had the same issue (Device Name: Andrés iPhone). The blueprint was struggling with the letter é. I changed the device name to andres iPhone and now it works perfectly! @valentinfrlch thanks so much for your easy to use blueprint - I love it

1 Like

Thanks for the feedback!
Obviously you shouldn’t need to change your phone’s name for this to work! I will look for an alternative solution and update the blueprint accordingly.

3 Likes

2024-11-11 23:11:27.148 ERROR (MainThread) [homeassistant.components.automation.ai_event_summary_office] Error rendering variables: UndefinedError: 'dict object' has no attribute 'payload_json'

The automation won`t pass certain conditions …

Hello,

I have the integration running with a Unifi camera in conjunction with Google AI Pro.

Is it possible to change the answers to German?

When I change something in the automation, I get the following error message even though I don’t have Frigate/MQTT enabled:

Logger: homeassistant.components.automation.ai_event_summary_llm_vision_v1_3_1
Source: components/automation/init.py:830
Integration: automation (documentation, problems)
First Occurred: 11:43:22 (1 occurrence)
Last logged: 11:43:22

Got error ‘Cannot subscribe to topic ‘frigate/events’, make sure MQTT is set up correctly’ when setting up triggers for AI Event Summary (LLM Vision v1.3.1)

thanks

In my case, the Friendly Name of my mobile is “GB-iPhone”. The Entity-Name ist gb_iphone. But the Blueprint creates the Entity-Name “gbiphone”.

Notifications not working for me.
Running Homeassistant 2024.11.1

Getting an error

Executed: November 15, 2024 at 7:00:03 PM
Error: Action notify.mobile_app_sms916b not found
Result:
choice: 0

Other notifications are working just fine and simple notification test works too.

action: notify.mobile_app_sm_s916b
data:
  message: test
  title: test

For some reason it is not working in the repeat sequence.

Also find this error in the settings > repairs

AI event summary uses an unknown actionError ⸱ Reported by Automation

The automation “AI event summary” (automation.ai_event_summary) has an unknown action: notify.mobile_app_sms916b.

This error prevents the automation from running correctly. Maybe this action is no longer available, or perhaps a typo caused it.

To fix this error, edit the automation and remove this action.

Edit:
Oh it is there up. So need to remove underscores?

Edit2: made PR, tested and works with device name SM-S916B set in companion app.

1 Like

Thank you so much for the PR!

@Bogey fixed the notification for phone entities that have a hyphen in their name. If you experienced this as well you can re-import the blueprint and it should be fixed.

1 Like

I have been playing around a bit. I have 8 cameras and getting lot of detections from movements etc and too much for analyze. Adding more conditions to filter to only objects person, car, ingore stationary could help a bit. But still there is often multiple events for single detection.

Tested also the beta feature to check first importance, but if the first event hadn’t anything interesting, it is skipped for cooldown period and not picking anything for a while.

Actually frigate already does this very well in the new review feature and most false detections should be already filtered.
And it also combines related detections to single review.
So maybe this integration could be also to attach to review events. Then have selectable severity for example we are interested only alerts. Then when triggered, show notification and its thumb. Do the video analysis for the found detection(s) and then it could be reviewed directly from the notification using notification actions.
Reviews and stats mqtt topics should have the needed information.

@valentinfrlch: Let me know if you are interested in a blueprint that works with frigates reviews instead of frigates events. I have modified your blueprint to do exactly that and it works pretty well. Happy to submit a PR if you are interested.

2 Likes

I did something like that also, not yet much tested though. Quick testing and it works. I have it my fork commit d8fecd9 if want to check it out.

Why does this happen?

The image is unavailable

Could be because it was not saved to disk and available when your phone try ti download and attach it

Could be because your phone could not access url hosting image

1 Like

Thanks to you and @Bogey. PRs are always welcome! Unfortunately I don’t have much time at the moment so it might take a while.

Hi guys,

Unfortunately, my devices have an apostrophe in their name and so the regex pattern is causing the blueprint to fail (e.g. “Dave’s iPhone 15 Pro Max”) I’m not a regex pro, so I can’t get this to work yet (I have tried changing the name of my mobile, but then a bunch of other automations fail of COURSE).

Anyway to limit this to just person detection? I’ve getting notified on all motion

Look at the reference config

objects:
  # Optional: list of objects to track from labelmap.txt (default: shown below)
  track:
    - person

Im having the same issue and I just installed everything tonight with the latest updates.

Edit: I think I may have got it working, I added a regex for an apostrophe ( ’ ) in the blueprint file.

1 Like

I installed LLM vision 1.3.1, put my openai API in, installed the blueprint and when I try to set anything up I keep getting this error.

Message malformed: Unable to determine action @ data[‘action’][0][‘choose’][0][‘sequence’][0][‘choose’][0][‘sequence’][0]

Here is the yaml of the blueprint

description: “”
alias: AI Event Summary (LLM Vision v1.3.1)
use_blueprint:
path: valentinfrlch/event_summary.yaml
input:
mode: Camera
important: false
notify_device:
- 21ed31a245660493983af055f0661d9a
camera_entities:
- camera.front_door
motion_sensors:
- binary_sensor.front_door_motion
provider: 01JDE97RA5WV1RTBGK3

Not sure what I’m doing wrong any help would be appreciated

Hello,
I installed this over the weekend and I am getting the failed to load attachment 404 error. I am running frigate (full access) on port 8555. I do have the frigate integration installed and configured correctly and everything else is working. I am able to get frigate notifications from the sgtbatten blueprint. Is there something I need to change to get this to work? The solutions I saw in the thread were pre 1.3.1, so I am sorry if I missed something. Any help would be appreciated. Thanks!!


Hi all

I’ve just installed this fantastic blueprint, but I’m having this issue

2024-11-26 20:12:25.527 ERROR (MainThread) [homeassistant.components.automation.test_ai_event_summary_llm_vision_v1_3_1] Error rendering variables: UndefinedError: 'dict object' has no attribute 'payload_json'

And this is my config, GUI and yaml

alias: TEST - AI Event Summary (LLM Vision v1.3.1)
description: ""
use_blueprint:
  path: valentinfrlch/event_summary.yaml
  input:
    mode: Frigate
    important: false
    notify_device:
      - 27f348f056567af0123402edbcf70fe5
    camera_entities:
      - camera.vialetto_3
    provider: 01JDM83JVTT9FX0DSDAPJGTE15
    detail: high
    motion_sensors: []

I’ve set Gemini as AI provider

What can I check?

Thanks