Files
canina/scripts/content-research/daily_publisher.py
T

17 lines
908 B
Python

"""Versioned integration entrypoint; not installed in the active cron runtime.
The supplied create_new callback MUST be the existing guarded NEW publisher,
including publisher_state ownership, quota, immutable QA, backup and intent.
No article update or automatic retry path is exposed here.
"""
from consumer import digest
def run_new(consumer, run_id, research, draft_content, independent_review, create_new):
packet = consumer.prepare(run_id, research) # Persist research BEFORE drafting.
draft = draft_content(packet) # Complete fetched CEO directive, not just a keyword.
# Reviewer receives exact immutable content/directive plus digests. A valid receipt
# establishes traceability, not a machine guarantee of free-text obedience.
receipt = independent_review(packet, draft, digest(packet), digest(draft))
return consumer.publish(run_id, packet, draft, receipt, create_new)