llm-connect/workplans/LLM-WP-0010-text-to-image-rendering.md
tegwick c0b7e54ed1
Some checks are pending
CI Smoke / container-smoke (push) Waiting to run
CI Smoke / host-smoke (push) Waiting to run
Render a hall portrait only for the entry about to be published
render-hall requires --entry and no longer walks the corpus. image plan
without --entry stays an inventory. LLM-WP-0010 records that existing seats
are historic and that the cooldown publisher comes later.

Assistant: grok
Assistant-Session: 01a11ab6-1534-7d63-8606-662b92a80ed6
2026-10-08 16:57:26 +02:00

3.4 KiB

id type title domain repo status flavor owner topic_slug created updated related state_hub_workstream_id
LLM-WP-0010 workplan Text-to-image rendering for square portraits agents llm-connect finished implementation grok text-to-image-rendering 2026-10-08 2026-10-08
message:ae2b441f-7c38-4cb5-8572-47791cb52456
205485de-a74d-57bd-8f84-e91b8623adeb

LLM-WP-0010 — Text-to-image rendering for square portraits

Founder-approved request from fluid-telegram (2026-10-08) for Hall of Helix portraits. This workplan adds the facility and the one-entry publish command. It does not backfill the hall, and it does not publish posts.

Library, OpenRouter client, and spend gate

id: LLM-WP-0010-T01
status: done
priority: high
state_hub_task_id: "f7f5b10e-f78e-53b0-ba0e-a52d91b701c8"

llm_connect.images renders one square image of at least 1024 pixels and returns bytes plus a receipt: provider, model, SHA-256 prompt digest, and cost. A per-call or batch cap requires a quote and refuses before the provider call. OpenRouter POST /api/v1/images is the only client. The model is required. The API key is resolved the same way as the chat adapter and is not copied onto the receipt. Contract: contracts/functional/images.md.

CLI

id: LLM-WP-0010-T02
status: done
priority: high
state_hub_task_id: "7532cca3-2198-52ae-9891-2e95d97d76b0"

llm-connect image render writes --output or a JSONL --batch of prompt / output_path lines. Receipts go to stdout. Exit 2 stops a batch on a cap. Existing files are not replaced unless --force.

HTTP

id: LLM-WP-0010-T03
status: done
priority: high
state_hub_task_id: "7b824e20-7ebf-591b-84e5-eea8154ca778"

POST /images is registered only when python -m llm_connect.server is started with --image-model, --image-max-cost-usd, and --image-quote-usd. The response is the receipt plus base64 bytes. /execute is unchanged. The process-lifetime batch cap is shared by concurrent requests.

One entry at publication

id: LLM-WP-0010-T04
status: done
priority: medium
state_hub_task_id: "e69a1f53-a1d5-540e-a926-0f2a32ae4f54"

The hall command renders the single entry named by --entry. A paid call still needs a key OpenRouter accepts. On 2026-10-08 the environment key was rejected with HTTP 401, so no portrait file was written. Reply to fluid-telegram used this workplan id.

2026-10-08 decision: use the intelligence-radar OpenRouter tree in llm_connect.image_selection. A hall visual that does not ask for vector output, editing, readable text, or a brand system is general / Efficient.

Portraits are rendered on demand, for the one entry about to be published:

llm-connect image render-hall --hall <hall-of-helix> --entry entries/<file>.md

The command writes that file under visuals/, stores a receipt under visuals/receipts/, and uncomments the portrait line. It does not change status, and it refuses to run without --entry. There is no corpus backfill.

Seats already in the hall when publishing starts are historic. Their posts carry a remark that the seat is historic content, so a quiet period can republish the record without pretending it is news. Seats written after that practice starts wait a short cooldown of some minutes, then publish; the portrait is rendered at that moment if it is still missing. The cooldown publisher is later work and is not this library.