openai/gpt-6-luna · storybook-mcp · all runs of payment-approval · Nov 9, 07:47
Runs from different design-system versions should not be compared.
A screenshot in each theme, as the benchmark took it.
As the agent left it; marked lines broke a rule.
import type { Meta, StoryObj } from "@storybook/react-vite";import { expect, userEvent, within } from "storybook/test";41 counted, under 9 rules. “Not counted” marks a compiler error that restates a design-system violation, “Ignored” one the agent silenced with a comment.
One row per model call, with the tools it asked for. An agent that reads the guidelines before writing shows it here; what a checker or submit_view answered is under its call.
| Step | Tools | Tokens in | Tokens out | Cost |
|---|---|---|---|---|
| 0 | docs-list | 3 | 45 | $0.0001 |
| 1 | get-storybook-story-instructions | 3 | 18 | $0.0001 |
| 2 | docs-show, docs-show, docs-show, docs-show, docs-show, list_files | 3 | 237 | $0.0004 |
As the agent left it; marked lines broke a rule.
"use client"; import { useState } from "react";import { Badge, Button, Card, CardDescription, CardHeader, CardTitle, Dialog, DialogClose, DialogContent, DialogFooter, Table, TableBody, TableCell, TableHead, TableHeader, TableRow,} from "@vektos/ds";import { css } from "styled-system/css";import data from "./fixture.json"; type Payment = (typeof data.payments)[number]; const money = new Intl.NumberFormat("en-IE", { style: "currency", currency: data.currency,}); function formatDate(value: string) { return new Intl.DateTimeFormat("en-GB", { day: "numeric", month: "short", year: "numeric", timeZone: "UTC", }).format(new Date(`${value}T00:00:00Z`));} const page = css({ minHeight: "100vh", background: "#f5f7fa", color: "#172033", padding: { base: "6", md: "12" },}); const content = css({ maxWidth: "1180px", marginInline: "auto",}); const eyebrow = css({ color: "#64748b", fontSize: "sm", fontWeight: "semibold", letterSpacing: "0.08em", textTransform: "uppercase", marginBottom: "3",}); const heading = css({ fontSize: { base: "2xl", md: "3xl" }, lineHeight: "1.15", fontWeight: "bold", letterSpacing: "-0.035em", margin: "0",}); const intro = css({ color: "#64748b", fontSize: "md", marginTop: "3", marginBottom: "0",}); const summary = css({ display: "flex", alignItems: "center", justifyContent: "space-between", gap: "4", flexWrap: "wrap", marginTop: "8", marginBottom: "4",}); const summaryLabel = css({ fontSize: "sm", color: "#64748b", margin: "0",}); const summaryCount = css({ color: "#172033", fontWeight: "semibold", marginInlineEnd: "1",}); const cardTitle = css({ fontSize: "lg", fontWeight: "semibold" });const cardDescription = css({ fontSize: "sm" }); const tableWrap = css({ overflowX: "auto", border: "1px solid #e5eaf0", borderRadius: "12px", background: "white", boxShadow: "0 4px 18px rgba(15, 23, 42, 0.04)",}); const table = css({ width: "100%", minWidth: "860px", borderCollapse: "collapse", "& th": { whiteSpace: "nowrap" }, "& td": { verticalAlign: "middle" },}); const beneficiary = css({ fontWeight: "semibold", color: "#172033" });const secondary = css({ fontSize: "xs", color: "#718096", marginTop: "1" });const iban = css({ fontSize: "sm", color: "#475569", whiteSpace: "nowrap" });const amount = css({ fontWeight: "semibold", fontVariantNumeric: "tabular-nums", whiteSpace: "nowrap" });const scheme = css({ fontSize: "xs", textTransform: "capitalize", color: "#718096", marginTop: "1" }); const dialogRows = css({ display: "grid", gap: "4", marginBlock: "2 6",}); const detail = css({ display: "flex", justifyContent: "space-between", alignItems: "baseline", gap: "4", borderBottom: "1px solid #e9edf2", paddingBottom: "3", fontSize: "sm", "& dt": { color: "#64748b" }, "& dd": { margin: "0", textAlign: "right", fontWeight: "medium", color: "#172033" },}); const total = css({ display: "flex", justifyContent: "space-between", alignItems: "baseline", gap: "4", borderRadius: "10px", background: "#f3f6fa", padding: "4", fontSize: "md", fontWeight: "semibold", "& dd": { margin: "0", fontVariantNumeric: "tabular-nums" },}); export default function PaymentsApprovalPage() { const [approvedIds, setApprovedIds] = useState<Set<string>>(() => new Set()); const [selectedPayment, setSelectedPayment] = useState<Payment | null>(null); const pendingCount = data.payments.length - approvedIds.size; const fee = selectedPayment ? data.fees[selectedPayment.scheme as keyof typeof data.fees] : 0; function approveSelectedPayment() { if (!selectedPayment) return; setApprovedIds((current) => new Set(current).add(selectedPayment.id)); setSelectedPayment(null); } return ( <main className={page}> <div className={content}> <header> <p className={eyebrow}>Treasury <span aria-hidden="true">/</span> Payments</p> <h1 className={heading}>Payments for approval</h1> <p className={intro}>Review outgoing payments and approve them before they are sent.</p> </header> <section aria-label="Payments awaiting approval"> <div className={summary}> <p className={summaryLabel}> <span className={summaryCount}>{pendingCount}</span> {pendingCount === 1 ? "payment" : "payments"} awaiting approval </p> </div> <Card> <CardHeader> <CardTitle className={cardTitle}>Outgoing payments</CardTitle> <CardDescription className={cardDescription}> Payment instructions scheduled for processing. </CardDescription> </CardHeader> <div className={tableWrap}> <Table aria-label="Company payments" className={table}> <TableHead> <TableRow> <TableHeader>Beneficiary</TableHeader> <TableHeader>IBAN</TableHeader> <TableHeader>Due date</TableHeader> <TableHeader numeric>Amount</TableHeader> <TableHeader>Status</TableHeader> <TableHeader>Action</TableHeader> </TableRow> </TableHead> <TableBody> {data.payments.map((payment) => { const isApproved = approvedIds.has(payment.id); return ( <TableRow key={payment.id}> <TableCell> <div className={beneficiary}>{payment.beneficiary}</div> <div className={secondary}>{payment.reference}</div> </TableCell> <TableCell><span className={iban}>{payment.iban}</span></TableCell> <TableCell>{formatDate(payment.dueDate)}</TableCell> <TableCell numeric><span className={amount}>{money.format(payment.amount)}</span></TableCell> <TableCell> <Badge tone={isApproved ? "success" : "warning"}> {isApproved ? "Approved" : "Pending"} </Badge> </TableCell> <TableCell> {isApproved ? ( <span className={secondary}>Ready to process</span> ) : ( <Button size="sm" variant="outline" onClick={() => setSelectedPayment(payment)} aria-label={`Approve payment to ${payment.beneficiary}`} > Approve </Button> )} </TableCell> </TableRow> ); })} </TableBody> </Table> </div> </Card> </section> <Dialog open={selectedPayment !== null} onOpenChange={(open) => { if (!open) setSelectedPayment(null); }} > {selectedPayment && ( <DialogContent title="Approve this payment?" description="Review the payment details, fee and total before confirming." > <dl className={dialogRows}> <div className={detail}> <dt>Beneficiary</dt> <dd>{selectedPayment.beneficiary}</dd> </div> <div className={detail}> <dt>IBAN</dt> <dd>{selectedPayment.iban}</dd> </div> <div className={detail}> <dt>Amount</dt> <dd>{money.format(selectedPayment.amount)}</dd> </div> <div className={detail}> <dt>Payment fee <span className={scheme}>({selectedPayment.scheme})</span></dt> <dd>{money.format(fee)}</dd> </div> <div className={total}> <dt>Total</dt> <dd>{money.format(selectedPayment.amount + fee)}</dd> </div> </dl> <DialogFooter> <DialogClose asChild> <Button variant="outline">Cancel</Button> </DialogClose> <Button onClick={approveSelectedPayment}>Confirm approval</Button> </DialogFooter> </DialogContent> )} </Dialog> </div> </main> );} | 3 |
| read_file |
| 3 |
| 51 |
| $0.0004 |
| 4 | write_file | 3 | 3,766 | $0.0020 |
| 5 | write_file | 3 | 671 | $0.0009 |
| 6 | write_file | 3 | 563 | $0.0005 |
| 7 | stories-changed | 3 | 35 | $0.0002 |
| 8 | stories-find-by-component | 3 | 86 | $0.0002 |
| 9 | docs-list | 3 | 155 | $0.0002 |
| 10 | stories-preview | 3 | 297 | $0.0004 |
| 11 | write_file | 3 | 2,951 | $0.0017 |
| 12 | stories-preview | 3 | 98 | $0.0006 |
| 13 | stop | 3 | 88 | $0.0002 |