Skip to content

social/feedback-bridge

social/feedback-bridge — turn engagement data into roster suggestions.

Category: social
Source: workflows/social/feedback_bridge.py

FieldTypeDefaultDescription
baseline_thresholdinteger5000Views threshold for formula ‘win’. Default = plan 073’s failure floor (5k).
cohortstring"default"Cohort to evaluate (e.g. ‘validation-cohort-1’).
posts_log_pathstring""Path to the TSV posts log. Empty = ~/.fabric/posts.tsv.
regenerateobjectWhen set, this run is a regeneration. Workflows may read direction / keep / extra_instructions to modulate prompts; the engine persists parent_run_id and parent_variant_index as run lineage columns.
roster_pathstring""Optional path to the cohort’s roster YAML. When set, untouched topics from the roster’s topics_pool are included in the rank with max_views=None so the operator can see what hasn’t been tried yet.
snapshots_pathstring""Path to the JSONL snapshot history produced by research/viral-gate-status. Empty = ~/.fabric/post-engagement-snapshots.jsonl.
suggestions_pathstring""Path to the suggestion JSONL (append-only). Empty = ~/.fabric/roster-suggestions.jsonl.
variantsinteger1Number of independent variant executions (1–10). When > 1, the engine runs the workflow N times with different sampling, producing N outputs.
window_daysinteger14Days from posted_at within which engagement counts. Mirrors viral-gate.
FieldTypeDefaultDescription
cohortstringrequired
formula_weightsany[]
kindobjectVariant card shape: video / carousel / image / text. Surfaced on the per-variant entry of the run-output API and used by gallery UIs to pick the right layout.
posts_evaluatedinteger0
posts_log_pathstringrequired
posts_with_metricsinteger0
rationalestring""
snapshots_pathstringrequired
suggested_atstringrequired
suggestions_pathstringrequired
topic_rankany[]
load_inputs → compute_suggestion → finalize
TaskDescription
load_inputsResolve paths, load the posts log + snapshot history.
compute_suggestionBuild the suggestion + persist it to the JSONL log.
finalizeShape the aggregate output.

Save the YAML below as my-run.yaml, edit the values, and run with the CLI or POST it to the API. Required fields are uncommented; optional knobs are documented above the input: block — copy any line under input: and uncomment to set.

workflow: social/feedback-bridge
# Optional fields — copy any line(s) under `input:` and uncomment to set:
# Views threshold for formula 'win'. Default = plan 073's failure floor (5k).
# [min=1]
# baseline_threshold: 5000
#
# Cohort to evaluate (e.g. 'validation-cohort-1').
# cohort: default
#
# Path to the TSV posts log. Empty = ~/.fabric/posts.tsv.
# posts_log_path: ""
#
# Optional path to the cohort's roster YAML. When set, untouched topics from the roster's topics_pool are included in the rank with max_views=None so the operator can see what hasn't been tried yet.
# roster_path: ""
#
# Path to the JSONL snapshot history produced by research/viral-gate-status. Empty = ~/.fabric/post-engagement-snapshots.jsonl.
# snapshots_path: ""
#
# Path to the suggestion JSONL (append-only). Empty = ~/.fabric/roster-suggestions.jsonl.
# suggestions_path: ""
#
# Days from posted_at within which engagement counts. Mirrors viral-gate.
# [min=1, max=365]
# window_days: 14
#
input: {}

Run it locally:

Terminal window
fab-workflow --from-file my-run.yaml

Or submit over the wire — the same file is the request body:

Terminal window
curl -X POST 'https://gofabric.dev/v1/workflows/runs?name=social/feedback-bridge' \
-H 'Authorization: Bearer fab_xxx' \
-H 'content-type: application/yaml' \
--data-binary @my-run.yaml

Every workflow also accepts the universal WorkflowInput fields — variants (1–10 fan-out) and regenerate (creative-direction hints with run lineage). See Run-specs (YAML / TOML / JSON) for the full top-level shape (metadata, priority, bundle, parent, etc.).