@anthusai/papyrus 2.0.0-next.95 → 2.0.0-next.96
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -7,7 +7,6 @@ import {
|
|
|
7
7
|
formatUtc,
|
|
8
8
|
referenceHref,
|
|
9
9
|
routingLabel,
|
|
10
|
-
usageText,
|
|
11
10
|
type MonitoringItem,
|
|
12
11
|
type MonitoringEmailDetails,
|
|
13
12
|
type MonitoringEmailSummary,
|
|
@@ -129,7 +128,6 @@ function EmailSubmissions({ items, detail, onOpen }: {
|
|
|
129
128
|
function Ready({ data, demo, emailDetail, onEmailOpen }: {
|
|
130
129
|
data: MonitoringOverview; demo: boolean; emailDetail: MonitoringEmailDetails | null; onEmailOpen: (id: string) => void;
|
|
131
130
|
}) {
|
|
132
|
-
const ceilings = data.usage?.ceilings ?? null;
|
|
133
131
|
const router = data.router;
|
|
134
132
|
return (
|
|
135
133
|
<>
|
|
@@ -152,15 +150,14 @@ function Ready({ data, demo, emailDetail, onEmailOpen }: {
|
|
|
152
150
|
</article>
|
|
153
151
|
|
|
154
152
|
<article className="news-desk-doctrine-card" data-monitoring-section="usage">
|
|
155
|
-
<div className="news-desk-doctrine-card__header"><div><h3>Usage</h3><span>
|
|
153
|
+
<div className="news-desk-doctrine-card__header"><div><h3>Usage</h3><span>Observed router decisions, not a Cyclotron quota (UTC days)</span></div></div>
|
|
156
154
|
{data.usage ? (
|
|
157
155
|
<>
|
|
158
156
|
<dl className="news-desk-monitoring__usage">
|
|
159
|
-
<div><dt>Decisions today ({data.usage.day})</dt><dd>{
|
|
160
|
-
<div><dt>Decisions in
|
|
161
|
-
{ceilings?.items !== undefined ? <div><dt>Items judged (ceiling)</dt><dd>{usageText(data.usage.decisionsTotal, ceilings.items)}</dd></div> : null}
|
|
157
|
+
<div><dt>Decisions today ({data.usage.day})</dt><dd>{data.usage.historyComplete ? data.usage.decisionsToday : `At least ${data.usage.decisionsToday}`}</dd></div>
|
|
158
|
+
<div><dt>Decisions in inspected history</dt><dd>{data.usage.historyComplete ? data.usage.decisionsTotal : `At least ${data.usage.decisionsTotal}`}</dd></div>
|
|
162
159
|
</dl>
|
|
163
|
-
{
|
|
160
|
+
{!data.usage.historyComplete ? <p className="news-desk-delegation-note">Counts are lower bounds from a bounded history read.</p> : null}
|
|
164
161
|
</>
|
|
165
162
|
) : <p>No usage recorded yet.</p>}
|
|
166
163
|
</article>
|
|
@@ -15,7 +15,7 @@ export const FIXTURE_MONITORING_OVERVIEW: MonitoringOverview = {
|
|
|
15
15
|
routerRuns: [{ runId: "q2", startedAt: "2026-10-21T02:37:00.000000Z", mode: "live", status: "stopped", stoppedBy: "request_ceiling_reached",
|
|
16
16
|
counts: { examined: 3, decided: 1, delivered: 1, deliveryFailed: 1, routed: 1 }, errorCount: 0 }],
|
|
17
17
|
router: { mode: "live", feedback: true, enabled: true, maxItemsPerRun: 5 },
|
|
18
|
-
usage: { day: "2026-10-21", decisionsToday: 2, decisionsTotal: 3,
|
|
18
|
+
usage: { day: "2026-10-21", decisionsToday: 2, decisionsTotal: 3, historyComplete: true },
|
|
19
19
|
hiddenNotRelevant: 1,
|
|
20
20
|
items: [
|
|
21
21
|
{ sourceId: "104", revision: 1, title: "Fresh Show HN", url: "https://example.org/104", discussionUrl: "https://news.ycombinator.com/item?id=104",
|
|
@@ -91,7 +91,7 @@ export type MonitoringOverview = {
|
|
|
91
91
|
day: string;
|
|
92
92
|
decisionsToday: number;
|
|
93
93
|
decisionsTotal: number;
|
|
94
|
-
|
|
94
|
+
historyComplete: boolean;
|
|
95
95
|
} | null;
|
|
96
96
|
items: MonitoringItem[];
|
|
97
97
|
emailSubmissions?: MonitoringEmailSummary[];
|
|
@@ -129,10 +129,6 @@ export function confidenceText(confidence: number | null): string {
|
|
|
129
129
|
return confidence === null ? "confidence not reported" : `${Math.round(confidence * 100)}% confidence`;
|
|
130
130
|
}
|
|
131
131
|
|
|
132
|
-
export function usageText(used: number, ceiling: number | undefined): string {
|
|
133
|
-
return ceiling === undefined ? `${used} used, no ceiling set` : `${used} of ${ceiling}`;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
132
|
export function everyText(seconds: number | null): string {
|
|
137
133
|
if (!seconds) return "on a schedule";
|
|
138
134
|
return seconds % 3600 === 0 ? `every ${seconds / 3600} h` : seconds % 60 === 0 ? `every ${seconds / 60} min` : `every ${seconds} s`;
|
package/package.json
CHANGED
package/routes.manifest.json
CHANGED