prompt_receipt
prompt_receipt
¶
Per-attempt prompt receipt: what reached the model, by source, as hashes and sizes.
A PromptReceipt answers "which injected files, how many bytes, which
hash" for one assembled prompt without keeping any prompt text. It is built
where the prompt is assembled (PromptRenderer.render), carried to the
conductor on SheetAttemptResult.prompt_receipt and stored on
SheetState.prompt_receipt (GH #546).
Token counts are estimates from marianne.core.tokens.estimate_tokens (a
character heuristic), never a tokenizer result.
Classes¶
PromptReceiptSource
¶
Bases: BaseModel
One source that contributed (or was refused) bytes to a sheet's prompt.
PromptReceipt
¶
Bases: BaseModel
What one attempt's assembled prompt was made of. Never holds prompt text.
Functions:¶
sha256_label
¶
build_receipt
¶
Build a receipt from the assembled prompt and the sources recorded for it.