Files
llmgw/internal/store/migrations/postgres/0041_usage_images.sql
Ilker ManapandClaude Opus 5.5 4a4fe8fa16 Pictures are priced by the picture
auth.pricing takes per_image, charged on top of a prompt's tokens; a model
priced only per picture is not free, so a spent budget still stops it.
Each usage row keeps how many pictures were made (migration 0041), and
ctl request and the admin API's request view show them.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-09 21:48:47 +02:00

5 lines
260 B
SQL

-- Ported from the SQLite migration of the same number.
-- How many pictures a request made, for a model that makes them: what a
-- per-picture price is charged by, and what its tokens do not say.
ALTER TABLE usage ADD COLUMN images BIGINT NOT NULL DEFAULT 0;