symfonic.evals.effects¶
effects ¶
Side-effect evidence fixtures for replay and retry evaluations.
EffectReceipt
dataclass
¶
Whether this attempt applied the effect or found it already applied.
SideEffectCount
dataclass
¶
SideEffectCount(ledger: SideEffectLedger, attempts: int, effects: int, duplicates: int, name: str = 'side_effect_count')
Assert attempted, applied and duplicate counts without exposing keys.
SideEffectLedger ¶
In-process fixture proving a tool honors a business idempotency key.
This is evaluation infrastructure, not a production durability mechanism.
A deployed tool should use its transactional database or durable command
ledger with the same apply_once contract. The fixture deliberately
counts attempts separately from applied effects, so a replay cannot pass
merely because the second request disappeared before reaching the tool.
Source code in src/symfonic/evals/effects.py
apply_once
async
¶
Apply operation at most once for key within this fixture.