Files
osmedeus/test/testdata/workflows/events/dedupe-receiver.yaml
T
j3ssie 1403d20a4d feat: add LLM step executor with vision and tool support, event workflow system, and inheritance
- Add LLM executor supporting OpenAI vision, tool calling, embeddings, and structured outputs
- Introduce event emitter/receiver workflows with deduplication and filtering (generate_event functions)
- Add workflow extends/override system enabling inheritance chains and step merge modes
- Update function naming to snake_case across all testdata (fileExists→file_exists, etc.)
- Add comprehensive test fixtures for linter, events, CDN, step dependencies, and extends workflows
2026-01-20 18:23:57 +08:00

57 lines
1.3 KiB
YAML

# Deduplicated Event Receiver Workflow
# This workflow demonstrates event deduplication to prevent processing duplicates
name: dedupe-receiver
kind: module
description: Workflow with event deduplication to avoid processing duplicates
tags: event,receiver,dedupe,example
trigger:
# Deduplicate events by URL within a 5 minute window
- name: on-new-url-dedupe
on: event
event:
topic: "crawler.url"
filters:
- "event.data_type == 'url'"
dedupe_key: "{{event.data.url}}"
dedupe_window: "5m"
input:
type: event_data
field: "value"
name: target
enabled: true
# Deduplicate by composite key (source + target)
- name: on-asset-composite-dedupe
on: event
event:
topic: "discovery.asset"
dedupe_key: "{{event.source}}-{{event.data.value}}"
dedupe_window: "1h"
input:
type: event_data
field: "value"
name: target
enabled: true
params:
- name: target
required: true
steps:
- name: log-unique
type: function
functions:
- 'print_blue("Processing unique event for: {{target}}")'
- name: process-unique
type: bash
command: |
echo "Unique target: {{target}}"
echo "{{target}}" >> {{Output}}/unique-targets.txt
- name: log-done
type: function
functions:
- 'print_green("Processed unique: {{target}}")'