@rackbops/docket-types 0.22.0 → 0.24.0
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.
- package/README.md +56 -0
- package/dist/index.d.ts +4 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/research-answer.d.ts +138 -7
- package/dist/research-answer.d.ts.map +1 -1
- package/dist/research-answer.js +167 -12
- package/dist/research-answer.js.map +1 -1
- package/dist/research-social.d.ts +108 -0
- package/dist/research-social.d.ts.map +1 -0
- package/dist/research-social.js +320 -0
- package/dist/research-social.js.map +1 -0
- package/dist/research.d.ts +28 -0
- package/dist/research.d.ts.map +1 -1
- package/dist/research.js +55 -16
- package/dist/research.js.map +1 -1
- package/dist/social-links.d.ts +30 -0
- package/dist/social-links.d.ts.map +1 -0
- package/dist/social-links.js +129 -0
- package/dist/social-links.js.map +1 -0
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -193,6 +193,62 @@ The tracker's task types, built on `@rackbops/docket-core`'s contract. Shipped s
|
|
|
193
193
|
of a full answer revises one that invents categories where the source defines them, or skips
|
|
194
194
|
an empty one.
|
|
195
195
|
|
|
196
|
+
**Social platforms** (0.23.0, docket#107; `docs/social-sources.md` has the matrix and roshne's
|
|
197
|
+
decisions): a `web` first pass may search YouTube, TikTok, Instagram and Bluesky for what
|
|
198
|
+
people say, through the tools it already has -- `firecrawl_scrape` with a typed `alexandria`
|
|
199
|
+
body (Firecrawl's `youtube-com` provider: `videos/search_videos`, `video_transcript`,
|
|
200
|
+
`video_comments`; its `oriane` provider, an index of public posts: `tiktok/posts-search`,
|
|
201
|
+
`instagram/posts-search`) and WebFetch on Bluesky's public `searchPosts` -- so no new tool, key
|
|
202
|
+
or runner change, and the prompt is the only control over which provider a run calls and how
|
|
203
|
+
often (`socialLines`), as it is for `proxy: "basic"`. The request's `social` says when: `auto`
|
|
204
|
+
(the default, and what an absent value means) searches when the question asks what people
|
|
205
|
+
recommend, think or experienced; `none` never; a list of `youtube`, `tiktok`, `instagram`,
|
|
206
|
+
`bluesky` (or `yt`, `insta`, `ig`, `bsky`) always searches those. `parseSocial` reads it and
|
|
207
|
+
answers null for anything else (`reddit`, `x`, a typo), so a host refuses it at intake; at run
|
|
208
|
+
time an unreadable value is `auto`. `since` (an instant) bounds the posts: older ones are left
|
|
209
|
+
out, undated ones may be used, marked. The run spends about 120 Firecrawl credits at most
|
|
210
|
+
(`SOCIAL_MAX_CREDITS`: 4 youtube-com calls, searches and reads together; 2 oriane calls at the
|
|
211
|
+
default detail; 2 Bluesky fetches), follows a `continuation` once, spreads its reads across
|
|
212
|
+
channels, and gets 20 turns (`SOCIAL_MAX_TURNS`) in place of 15; the 1 USD cap, the reviewer's
|
|
213
|
+
caps and the tool lists are unchanged. A run on gathered pages (a `sent` request, a second
|
|
214
|
+
pass) searches no platform: it cannot open pages.
|
|
215
|
+
|
|
216
|
+
A finding from a post cites the post's own page and carries `platform`, `publishedAt` (the
|
|
217
|
+
instant; "about <date>" worked out from a relative time; "undated") and `evidence` (`read`:
|
|
218
|
+
the transcript, the comments or the post was opened; `snippet`: a caption or a search result
|
|
219
|
+
only); `parseAnswer` keeps them when the platform is one of `SOCIAL_PLATFORMS` and a source is
|
|
220
|
+
on it, or infers the platform when every source's host agrees, and drops them on a web page.
|
|
221
|
+
The DM shows them: `- <claim> (YouTube, about 2026-10-19, snippet only) <url>`. The answer
|
|
222
|
+
carries `coverage`, one row per platform (`searched`, `empty`, `unavailable` with which call
|
|
223
|
+
failed, or `skipped` with why) and one for Reddit, shown as one "Social:" line before the
|
|
224
|
+
reviewer's note, kept whole like the "Couldn't open:" tail (at most 500 characters). The
|
|
225
|
+
reviewer (`socialChecks`) opens post pages where they open (at most one youtube-com call, no
|
|
226
|
+
oriane call), turns an unopened `read` into `snippet`, moves stock, price and availability
|
|
227
|
+
claims resting on posts alone to `uncertain`, rewords opinions as what posters say, counts a
|
|
228
|
+
repost once, checks `coverage` and `since`, and removes a finding that follows an instruction
|
|
229
|
+
from a post. Saved findings from posts are tagged `["research", <verdict>, "social",
|
|
230
|
+
<platform>]`.
|
|
231
|
+
|
|
232
|
+
Plain code is the belt (`socialOutgoing`, on the answer that goes out, first pass and update):
|
|
233
|
+
a social post link is one post (`canonicalSocialUrl`: `youtu.be`, shorts, live and embed links
|
|
234
|
+
and tracking parameters to the watch page; Instagram reel and p links to one `/p/` page; TikTok
|
|
235
|
+
post queries dropped; hashes and tracking parameters dropped everywhere; any other URL untouched), applied in
|
|
236
|
+
`parseAnswer` so stored drafts and saved findings carry canonical links; a finding repeating an
|
|
237
|
+
earlier one (same claim, same first link) is dropped; with `since` (whole UTC days), a post
|
|
238
|
+
finding dated before it moves to `uncertain` saying when it was posted; a finding whose every source is on a social
|
|
239
|
+
platform and whose claim speaks of stock, a price or availability (whole words, or a currency
|
|
240
|
+
amount) moves to `uncertain` "(said in a post, not verified)"; and `coverage` is rebuilt
|
|
241
|
+
(`withCoverage`): every chosen platform present (`skipped`, "not reported by the run", when the
|
|
242
|
+
run left one out), Reddit always `unavailable` with `REDDIT_WHY`, the run's other rows after,
|
|
243
|
+
at most 8; `none`, and a `sent` request, drop it. `uncertain` stays within its cap of 6, the
|
|
244
|
+
run's own lines first; past it, the last line says how many more were moved.
|
|
245
|
+
|
|
246
|
+
Reddit is never a route (roshne, 2026-11-07: "if we want to do anything with Reddit, it has to
|
|
247
|
+
be done through a local PC session with me logged in"): not here, not in a host. X, Threads,
|
|
248
|
+
Pinterest, Facebook and Mastodon are not searched either; a recurring social watch is a later
|
|
249
|
+
question. The belt's price rule applies to any answer, `none` included: a web run that cites a
|
|
250
|
+
post for a price gets the same treatment.
|
|
251
|
+
|
|
196
252
|
- `scout` (category 1, E9): execute lane, `calendar` every N days at the owner's hour (the host bounds N; the tracker
|
|
197
253
|
plugin allows 1 to 30). One
|
|
198
254
|
`claude -p` Job a run (WebSearch and WebFetch; 30 turns, 1.50 USD, 10 minutes, item 61 proposed)
|
package/dist/index.d.ts
CHANGED
|
@@ -18,12 +18,14 @@ export { changedFacts, factsOf, LOOKBACK_DAYS, MAX_DISAMBIGUATE_CHARS, MAX_INCLU
|
|
|
18
18
|
export { BASELINE_RULES, type BaselineRule, DEFAULT_BASELINE, DEFAULT_DROP_PERCENT, MISSES_BEFORE_TELLING, type PriceConfig, type PriceState, price, reference, } from "./price.js";
|
|
19
19
|
export { DEFAULT_SNOOZE_MS, type ReminderConfig, reminder, snoozeUntil } from "./reminder.js";
|
|
20
20
|
export { decisionOf, isRenewalDecision, RENEWAL_DECISIONS, type RenewalConfig, type RenewalDecision, type RenewalState, renewal, } from "./renewal.js";
|
|
21
|
-
export { AUTH_RETRY_MS, deadlineOf, draftJson, MAX_CONTEXT_CHARS, MAX_QUESTION_CHARS, MAX_TRIES, MIN_SOURCES_WAIT_MS, RESEARCH_MAX_BUDGET_USD, RESEARCH_MAX_TURNS, RESEARCH_TIMEOUT_MS, REVIEW_MAX_BUDGET_USD, REVIEW_MAX_TURNS, REVIEW_TIMEOUT_MS, type ResearchConfig, type ResearchJobOptions, type ResearchOptions, type ResearchPhase, type ResearchState, research, researchJob, researchState, researchType, reviewJob, usesSentSources, } from "./research.js";
|
|
22
|
-
export { ANSWER_SCHEMA, type BlockedPage, clean, fitMessage, MAX_BLOCKED, MAX_MESSAGE_CHARS, parseAnswer, parseBlocked, parseReview, REVIEW_SCHEMA, type ResearchAnswer, type ResearchFinding, type Review, renderAnswer, renderUpdate, safeUrl, VERDICTS, type Verdict, ZWSP, } from "./research-answer.js";
|
|
21
|
+
export { AUTH_RETRY_MS, deadlineOf, draftJson, MAX_CONTEXT_CHARS, MAX_QUESTION_CHARS, MAX_TRIES, MIN_SOURCES_WAIT_MS, RESEARCH_MAX_BUDGET_USD, RESEARCH_MAX_TURNS, RESEARCH_TIMEOUT_MS, REVIEW_MAX_BUDGET_USD, REVIEW_MAX_TURNS, REVIEW_TIMEOUT_MS, type ResearchConfig, type ResearchJobOptions, type ResearchOptions, type ResearchPhase, type ResearchState, research, researchJob, researchState, researchType, reviewJob, sinceOf, usesSentSources, } from "./research.js";
|
|
22
|
+
export { ANSWER_SCHEMA, type BlockedPage, COVERAGE_STATUSES, type Coverage, type CoverageStatus, clean, coverageLine, findingLine, fitMessage, MAX_BLOCKED, MAX_COVERAGE, MAX_COVERAGE_LINE_CHARS, MAX_MESSAGE_CHARS, MAX_PUBLISHED_CHARS, MAX_UNCERTAIN, MAX_UNCERTAIN_CHARS, parseAnswer, parseBlocked, parseCoverage, parseReview, REVIEW_SCHEMA, type ResearchAnswer, type ResearchFinding, type Review, renderAnswer, renderUpdate, safeUrl, sameClaim, VERDICTS, type Verdict, ZWSP, } from "./research-answer.js";
|
|
23
|
+
export { BLUESKY_SEARCH_URL, NOT_REPORTED, parseSocial, postDate, REDDIT_WHY, SAID_IN_POST, SOCIAL_AUTO, SOCIAL_BLUESKY_CALLS, SOCIAL_MAX_CREDITS, SOCIAL_MAX_TURNS, SOCIAL_ORIANE_CALLS, SOCIAL_YOUTUBE_CALLS, type SocialChoice, socialChecks, socialChoice, socialLines, socialOutgoing, socialPlatforms, withCoverage, } from "./research-social.js";
|
|
23
24
|
export { BARRED_SITES, blockedKey, GATHERED_ALLOWED_TOOLS, GATHERED_DENIED_TOOLS, type GatheredPage, gatheredPages, MAX_GATHERED_CHARS, MAX_GATHERED_PAGES, MAX_PAGE_CHARS, MAX_PAGE_TITLE_CHARS, MIN_PAGE_CHARS, NOT_OPENED_WHY, pagesBlock, pagesJson, type ReadSources, SENT_DISALLOWED_TOOLS, SOURCES_DEADLINE_MARGIN_MINUTES, SOURCES_DEADLINE_MARGIN_MS, SOURCES_WAIT_DAYS, SOURCES_WAIT_MS, sourcesExpiry, uniqueBlocked, WEB_DISALLOWED_TOOLS, withBarredSites, } from "./research-sources.js";
|
|
24
25
|
export { BGG_CATEGORIES, bggCategoryUrl, FIRECRAWL_TOOLS, WEB_ALLOWED_TOOLS, } from "./research-web.js";
|
|
25
26
|
export { RETRIED, type Retry, retryOutcome } from "./retry.js";
|
|
26
27
|
export { itemKey, LENS_TEXT, LENSES, type Lens, lensOf, MAX_FOR_CHARS, MAX_INTEREST_CHARS, MAX_INTERESTS, MAX_ITEMS, MAX_SCOUT_NOTES, MAX_SHOWN, MIN_ITEMS, PROMPT_SHOWN, parseScout, renderScout, SCOUT_MAX_BUDGET_USD, SCOUT_MAX_TURNS, SCOUT_SCHEMA, SCOUT_TIMEOUT_MS, type ScoutConfig, type ScoutItem, type ScoutState, type ShownItem, scout, scoutJob, scoutState, } from "./scout.js";
|
|
28
|
+
export { canonicalSocialUrl, isSocialPlatform, platformName, platformOf, SOCIAL_PLATFORMS, type SocialPlatform, } from "./social-links.js";
|
|
27
29
|
export { BGG_ATTRIBUTION, BGG_HOST, BGG_SPACING_MS, type BggOptions, bggSource, bggThingUrl, MAX_SCANNED, parseBggThingId, parseMarketplace, } from "./want-bgg.js";
|
|
28
30
|
export { DETAIL_CHARS, EBAY_ATTRIBUTION, EBAY_CURRENCY, EBAY_ITEM_ID, EBAY_ITEM_PATH, EBAY_LIMIT, EBAY_MARKETPLACE, EBAY_SEARCH_PATH, type EbayBrowse, type EbayRequest, type EbaySearch, ebayItemRequest, ebayRequest, ebaySource, parseEbayAnswer, parseEbayItem, } from "./want-ebay.js";
|
|
29
31
|
export { matchesWords, minorUnits, parseShopifyAnswer, SHOPIFY_ATTRIBUTION, SHOPIFY_CAPABILITY, SHOPIFY_COUNTRY, SHOPIFY_CREDITS, SHOPIFY_CURRENCY, SHOPIFY_LIMIT, SHOPIFY_PROVIDER, type ShopifyRequest, type ShopifyScrape, type ShopifySearch, searchWords, shopifyQuery, shopifyRequest, shopifySource, } from "./want-shopify.js";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,QAAQ,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E,eAAO,MAAM,UAAU,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,OAAO,CAAC,CAAC,CAUjE,CAAA"}
|
package/dist/index.js
CHANGED
|
@@ -25,12 +25,14 @@ export { changedFacts, factsOf, LOOKBACK_DAYS, MAX_DISAMBIGUATE_CHARS, MAX_INCLU
|
|
|
25
25
|
export { BASELINE_RULES, DEFAULT_BASELINE, DEFAULT_DROP_PERCENT, MISSES_BEFORE_TELLING, price, reference, } from "./price.js";
|
|
26
26
|
export { DEFAULT_SNOOZE_MS, reminder, snoozeUntil } from "./reminder.js";
|
|
27
27
|
export { decisionOf, isRenewalDecision, RENEWAL_DECISIONS, renewal, } from "./renewal.js";
|
|
28
|
-
export { AUTH_RETRY_MS, deadlineOf, draftJson, MAX_CONTEXT_CHARS, MAX_QUESTION_CHARS, MAX_TRIES, MIN_SOURCES_WAIT_MS, RESEARCH_MAX_BUDGET_USD, RESEARCH_MAX_TURNS, RESEARCH_TIMEOUT_MS, REVIEW_MAX_BUDGET_USD, REVIEW_MAX_TURNS, REVIEW_TIMEOUT_MS, research, researchJob, researchState, researchType, reviewJob, usesSentSources, } from "./research.js";
|
|
29
|
-
export { ANSWER_SCHEMA, clean, fitMessage, MAX_BLOCKED, MAX_MESSAGE_CHARS, parseAnswer, parseBlocked, parseReview, REVIEW_SCHEMA, renderAnswer, renderUpdate, safeUrl, VERDICTS, ZWSP, } from "./research-answer.js";
|
|
28
|
+
export { AUTH_RETRY_MS, deadlineOf, draftJson, MAX_CONTEXT_CHARS, MAX_QUESTION_CHARS, MAX_TRIES, MIN_SOURCES_WAIT_MS, RESEARCH_MAX_BUDGET_USD, RESEARCH_MAX_TURNS, RESEARCH_TIMEOUT_MS, REVIEW_MAX_BUDGET_USD, REVIEW_MAX_TURNS, REVIEW_TIMEOUT_MS, research, researchJob, researchState, researchType, reviewJob, sinceOf, usesSentSources, } from "./research.js";
|
|
29
|
+
export { ANSWER_SCHEMA, COVERAGE_STATUSES, clean, coverageLine, findingLine, fitMessage, MAX_BLOCKED, MAX_COVERAGE, MAX_COVERAGE_LINE_CHARS, MAX_MESSAGE_CHARS, MAX_PUBLISHED_CHARS, MAX_UNCERTAIN, MAX_UNCERTAIN_CHARS, parseAnswer, parseBlocked, parseCoverage, parseReview, REVIEW_SCHEMA, renderAnswer, renderUpdate, safeUrl, sameClaim, VERDICTS, ZWSP, } from "./research-answer.js";
|
|
30
|
+
export { BLUESKY_SEARCH_URL, NOT_REPORTED, parseSocial, postDate, REDDIT_WHY, SAID_IN_POST, SOCIAL_AUTO, SOCIAL_BLUESKY_CALLS, SOCIAL_MAX_CREDITS, SOCIAL_MAX_TURNS, SOCIAL_ORIANE_CALLS, SOCIAL_YOUTUBE_CALLS, socialChecks, socialChoice, socialLines, socialOutgoing, socialPlatforms, withCoverage, } from "./research-social.js";
|
|
30
31
|
export { BARRED_SITES, blockedKey, GATHERED_ALLOWED_TOOLS, GATHERED_DENIED_TOOLS, gatheredPages, MAX_GATHERED_CHARS, MAX_GATHERED_PAGES, MAX_PAGE_CHARS, MAX_PAGE_TITLE_CHARS, MIN_PAGE_CHARS, NOT_OPENED_WHY, pagesBlock, pagesJson, SENT_DISALLOWED_TOOLS, SOURCES_DEADLINE_MARGIN_MINUTES, SOURCES_DEADLINE_MARGIN_MS, SOURCES_WAIT_DAYS, SOURCES_WAIT_MS, sourcesExpiry, uniqueBlocked, WEB_DISALLOWED_TOOLS, withBarredSites, } from "./research-sources.js";
|
|
31
32
|
export { BGG_CATEGORIES, bggCategoryUrl, FIRECRAWL_TOOLS, WEB_ALLOWED_TOOLS, } from "./research-web.js";
|
|
32
33
|
export { RETRIED, retryOutcome } from "./retry.js";
|
|
33
34
|
export { itemKey, LENS_TEXT, LENSES, lensOf, MAX_FOR_CHARS, MAX_INTEREST_CHARS, MAX_INTERESTS, MAX_ITEMS, MAX_SCOUT_NOTES, MAX_SHOWN, MIN_ITEMS, PROMPT_SHOWN, parseScout, renderScout, SCOUT_MAX_BUDGET_USD, SCOUT_MAX_TURNS, SCOUT_SCHEMA, SCOUT_TIMEOUT_MS, scout, scoutJob, scoutState, } from "./scout.js";
|
|
35
|
+
export { canonicalSocialUrl, isSocialPlatform, platformName, platformOf, SOCIAL_PLATFORMS, } from "./social-links.js";
|
|
34
36
|
export { BGG_ATTRIBUTION, BGG_HOST, BGG_SPACING_MS, bggSource, bggThingUrl, MAX_SCANNED, parseBggThingId, parseMarketplace, } from "./want-bgg.js";
|
|
35
37
|
export { DETAIL_CHARS, EBAY_ATTRIBUTION, EBAY_CURRENCY, EBAY_ITEM_ID, EBAY_ITEM_PATH, EBAY_LIMIT, EBAY_MARKETPLACE, EBAY_SEARCH_PATH, ebayItemRequest, ebayRequest, ebaySource, parseEbayAnswer, parseEbayItem, } from "./want-ebay.js";
|
|
36
38
|
export { matchesWords, minorUnits, parseShopifyAnswer, SHOPIFY_ATTRIBUTION, SHOPIFY_CAPABILITY, SHOPIFY_COUNTRY, SHOPIFY_CREDITS, SHOPIFY_CURRENCY, SHOPIFY_LIMIT, SHOPIFY_PROVIDER, searchWords, shopifyQuery, shopifyRequest, shopifySource, } from "./want-shopify.js";
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAA;AAChC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAA;AAClC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AACtC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACxC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAA;AAClC,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,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O,EACL,SAAS,EACT,IAAI,EACJ,eAAe,EACf,aAAa,EACb,UAAU,EACV,KAAK,EACL,UAAU,EACV,aAAa,EACb,cAAc,EACd,WAAW,EACX,YAAY,EACZ,WAAW,EACX,eAAe,EACf,YAAY,EACZ,cAAc,EACd,IAAI,EACJ,QAAQ,EAER,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,UAAU,EACV,WAAW,EAGX,MAAM,EACN,YAAY,EACZ,SAAS,EACT,YAAY,GACb,MAAM,eAAe,CAAA;AAEtB;;;GAGG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,UAAU;IACV,SAAS;IACT,OAAO;IACP,UAAU;IACV,OAAO;IACP,UAAU;IACV,WAAW;IACX,MAAM;CACE,CAAA;AAIV,2FAA2F;AAC3F,MAAM,UAAU,QAAQ,CAAC,KAAa;IACpC,OAAQ,QAA8B,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAA;AACxD,CAAC;AAED,2EAA2E;AAC3E,MAAM,CAAC,MAAM,UAAU,GAAgD,MAAM,CAAC,MAAM,CAAC;IACnF,QAAQ,EAAE,QAA6B;IACvC,OAAO,EAAE,OAA4B;IACrC,KAAK,EAAE,KAA0B;IACjC,QAAQ,EAAE,QAA6B;IACvC,KAAK,EAAE,KAA0B;IACjC,0FAA0F;IAC1F,QAAQ,EAAE,YAAY,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,CAAsB;IACjE,SAAS,EAAE,aAAa,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,CAAsB;IACnE,IAAI,EAAE,IAAyB;CAChC,CAAC,CAAA"}
|
|
@@ -6,13 +6,36 @@
|
|
|
6
6
|
* carry an instruction; the most it can do here is be quoted as text.
|
|
7
7
|
*/
|
|
8
8
|
import { clean, ZWSP } from "@rackbops/docket-core";
|
|
9
|
+
import { type SocialPlatform } from "./social-links.js";
|
|
9
10
|
/** The cleaner lives in core, so the dispatcher's own messages use it too; re-exported here. */
|
|
10
11
|
export { clean, ZWSP };
|
|
11
12
|
/** One claim and the pages it rests on. */
|
|
12
13
|
export interface ResearchFinding {
|
|
13
14
|
claim: string;
|
|
14
|
-
/**
|
|
15
|
+
/**
|
|
16
|
+
* http(s) URLs the run says it opened; a social post link as one post (`canonicalSocialUrl`,
|
|
17
|
+
* 0.23.0), so a repost counts once.
|
|
18
|
+
*/
|
|
15
19
|
sources: string[];
|
|
20
|
+
/**
|
|
21
|
+
* The platform the sources are posts on (0.23.0), as the run set it or as every source's host
|
|
22
|
+
* says; absent for a web page. The two fields below are kept only with it.
|
|
23
|
+
*/
|
|
24
|
+
platform?: SocialPlatform;
|
|
25
|
+
/** When the post was published, as the run read it: an instant, "about <date>", or "undated". */
|
|
26
|
+
publishedAt?: string;
|
|
27
|
+
/** `read`: the transcript, the comments or the post itself was opened; `snippet`: a caption or a search result only. */
|
|
28
|
+
evidence?: "read" | "snippet";
|
|
29
|
+
}
|
|
30
|
+
/** What a run did on one platform (0.23.0): the DM's "Social:" line is built from these. */
|
|
31
|
+
export declare const COVERAGE_STATUSES: readonly ["searched", "empty", "unavailable", "skipped"];
|
|
32
|
+
export type CoverageStatus = (typeof COVERAGE_STATUSES)[number];
|
|
33
|
+
export interface Coverage {
|
|
34
|
+
/** The platform's id, lower-cased: youtube, tiktok, instagram, bluesky, reddit, or another. */
|
|
35
|
+
platform: string;
|
|
36
|
+
status: CoverageStatus;
|
|
37
|
+
/** A few words: what was found, or why not. */
|
|
38
|
+
note?: string;
|
|
16
39
|
}
|
|
17
40
|
/**
|
|
18
41
|
* A page the run needed but could not open (0.9.0): refused, a 403, a CAPTCHA, a sign-in wall.
|
|
@@ -31,6 +54,11 @@ export interface ResearchAnswer {
|
|
|
31
54
|
uncertain: string[];
|
|
32
55
|
/** Pages the run needed but could not open; absent when there were none. Never rendered. */
|
|
33
56
|
blocked?: BlockedPage[];
|
|
57
|
+
/**
|
|
58
|
+
* What the run did on each social platform (0.23.0); absent when none was in scope. Rendered
|
|
59
|
+
* as the DM's "Social:" line.
|
|
60
|
+
*/
|
|
61
|
+
coverage?: Coverage[];
|
|
34
62
|
}
|
|
35
63
|
export declare const MAX_SUMMARY_CHARS = 1200;
|
|
36
64
|
export declare const MAX_CLAIM_CHARS = 400;
|
|
@@ -42,6 +70,13 @@ export declare const MAX_UNCERTAIN_CHARS = 300;
|
|
|
42
70
|
export declare const MAX_BLOCKED = 6;
|
|
43
71
|
export declare const MAX_BLOCKED_SITE_CHARS = 100;
|
|
44
72
|
export declare const MAX_BLOCKED_WHY_CHARS = 200;
|
|
73
|
+
/** A post's `publishedAt` as kept: an instant, "about 2026-10-19" or "undated" all fit. */
|
|
74
|
+
export declare const MAX_PUBLISHED_CHARS = 40;
|
|
75
|
+
export declare const MAX_COVERAGE = 8;
|
|
76
|
+
export declare const MAX_COVERAGE_PLATFORM_CHARS = 30;
|
|
77
|
+
export declare const MAX_COVERAGE_NOTE_CHARS = 120;
|
|
78
|
+
/** The DM's "Social:" line, kept whole like the "Couldn't open:" tail, so it is bounded here. */
|
|
79
|
+
export declare const MAX_COVERAGE_LINE_CHARS = 500;
|
|
45
80
|
/** Discord's DM limit is 2000 characters; the rest is headroom for the host's own framing. */
|
|
46
81
|
export declare const MAX_MESSAGE_CHARS = 1900;
|
|
47
82
|
/** The JSON schema the research run answers in: the spike's (docket-runner spike/cases.json). */
|
|
@@ -64,9 +99,23 @@ export declare const ANSWER_SCHEMA: {
|
|
|
64
99
|
readonly type: "array";
|
|
65
100
|
readonly items: {
|
|
66
101
|
readonly type: "string";
|
|
67
|
-
readonly description: "A URL you opened.";
|
|
102
|
+
readonly description: "A URL you opened; for a post marked snippet, the post's own page.";
|
|
68
103
|
};
|
|
69
104
|
};
|
|
105
|
+
readonly platform: {
|
|
106
|
+
readonly type: "string";
|
|
107
|
+
readonly enum: readonly ["youtube", "tiktok", "instagram", "bluesky"];
|
|
108
|
+
readonly description: string;
|
|
109
|
+
};
|
|
110
|
+
readonly publishedAt: {
|
|
111
|
+
readonly type: "string";
|
|
112
|
+
readonly description: string;
|
|
113
|
+
};
|
|
114
|
+
readonly evidence: {
|
|
115
|
+
readonly type: "string";
|
|
116
|
+
readonly enum: readonly ["read", "snippet"];
|
|
117
|
+
readonly description: string;
|
|
118
|
+
};
|
|
70
119
|
};
|
|
71
120
|
readonly required: readonly ["claim", "sources"];
|
|
72
121
|
};
|
|
@@ -99,6 +148,29 @@ export declare const ANSWER_SCHEMA: {
|
|
|
99
148
|
readonly required: readonly ["site", "why"];
|
|
100
149
|
};
|
|
101
150
|
};
|
|
151
|
+
readonly coverage: {
|
|
152
|
+
readonly type: "array";
|
|
153
|
+
readonly description: string;
|
|
154
|
+
readonly items: {
|
|
155
|
+
readonly type: "object";
|
|
156
|
+
readonly properties: {
|
|
157
|
+
readonly platform: {
|
|
158
|
+
readonly type: "string";
|
|
159
|
+
readonly description: "youtube, tiktok, instagram, bluesky or reddit.";
|
|
160
|
+
};
|
|
161
|
+
readonly status: {
|
|
162
|
+
readonly type: "string";
|
|
163
|
+
readonly enum: readonly ["searched", "empty", "unavailable", "skipped"];
|
|
164
|
+
readonly description: string;
|
|
165
|
+
};
|
|
166
|
+
readonly note: {
|
|
167
|
+
readonly type: "string";
|
|
168
|
+
readonly description: "A few words: what was found, or why not.";
|
|
169
|
+
};
|
|
170
|
+
};
|
|
171
|
+
readonly required: readonly ["platform", "status"];
|
|
172
|
+
};
|
|
173
|
+
};
|
|
102
174
|
};
|
|
103
175
|
readonly required: readonly ["summary", "findings", "uncertain"];
|
|
104
176
|
};
|
|
@@ -107,9 +179,19 @@ export declare function safeUrl(value: unknown): string | null;
|
|
|
107
179
|
/**
|
|
108
180
|
* The answer in `value`, capped and cleaned, or null when it is not one. A claim with no usable
|
|
109
181
|
* source is not a finding: it moves to `uncertain`, marked, since every claim a reader might act
|
|
110
|
-
* on needs a source the run opened.
|
|
182
|
+
* on needs a source the run opened. A source on a social platform is kept as one post
|
|
183
|
+
* (`canonicalSocialUrl`), so a `youtu.be` link and its watch page are one (0.23.0).
|
|
111
184
|
*/
|
|
112
185
|
export declare function parseAnswer(value: unknown): ResearchAnswer | null;
|
|
186
|
+
/**
|
|
187
|
+
* The coverage rows in `value` (0.23.0), cleaned: a lower-cased one-line platform id, a status in
|
|
188
|
+
* `COVERAGE_STATUSES`, a one-line note when given; the first row per platform, at most
|
|
189
|
+
* `MAX_COVERAGE`. A row with no platform or an unknown status is dropped; anything not a list is
|
|
190
|
+
* none.
|
|
191
|
+
*/
|
|
192
|
+
export declare function parseCoverage(value: unknown): Coverage[];
|
|
193
|
+
/** A claim as compared for repeats: case, spacing and a trailing stop do not count. */
|
|
194
|
+
export declare function sameClaim(claim: string): string;
|
|
113
195
|
/**
|
|
114
196
|
* The blocked pages in `value`, cleaned: a one-line site and reason, the URL only when `safeUrl`
|
|
115
197
|
* takes it, at most `MAX_BLOCKED`. An entry with no site is dropped; anything not a list is none.
|
|
@@ -162,9 +244,23 @@ export declare const REVIEW_SCHEMA: {
|
|
|
162
244
|
readonly type: "array";
|
|
163
245
|
readonly items: {
|
|
164
246
|
readonly type: "string";
|
|
165
|
-
readonly description: "A URL you opened.";
|
|
247
|
+
readonly description: "A URL you opened; for a post marked snippet, the post's own page.";
|
|
166
248
|
};
|
|
167
249
|
};
|
|
250
|
+
readonly platform: {
|
|
251
|
+
readonly type: "string";
|
|
252
|
+
readonly enum: readonly ["youtube", "tiktok", "instagram", "bluesky"];
|
|
253
|
+
readonly description: string;
|
|
254
|
+
};
|
|
255
|
+
readonly publishedAt: {
|
|
256
|
+
readonly type: "string";
|
|
257
|
+
readonly description: string;
|
|
258
|
+
};
|
|
259
|
+
readonly evidence: {
|
|
260
|
+
readonly type: "string";
|
|
261
|
+
readonly enum: readonly ["read", "snippet"];
|
|
262
|
+
readonly description: string;
|
|
263
|
+
};
|
|
168
264
|
};
|
|
169
265
|
readonly required: readonly ["claim", "sources"];
|
|
170
266
|
};
|
|
@@ -197,6 +293,29 @@ export declare const REVIEW_SCHEMA: {
|
|
|
197
293
|
readonly required: readonly ["site", "why"];
|
|
198
294
|
};
|
|
199
295
|
};
|
|
296
|
+
readonly coverage: {
|
|
297
|
+
readonly type: "array";
|
|
298
|
+
readonly description: string;
|
|
299
|
+
readonly items: {
|
|
300
|
+
readonly type: "object";
|
|
301
|
+
readonly properties: {
|
|
302
|
+
readonly platform: {
|
|
303
|
+
readonly type: "string";
|
|
304
|
+
readonly description: "youtube, tiktok, instagram, bluesky or reddit.";
|
|
305
|
+
};
|
|
306
|
+
readonly status: {
|
|
307
|
+
readonly type: "string";
|
|
308
|
+
readonly enum: readonly ["searched", "empty", "unavailable", "skipped"];
|
|
309
|
+
readonly description: string;
|
|
310
|
+
};
|
|
311
|
+
readonly note: {
|
|
312
|
+
readonly type: "string";
|
|
313
|
+
readonly description: "A few words: what was found, or why not.";
|
|
314
|
+
};
|
|
315
|
+
};
|
|
316
|
+
readonly required: readonly ["platform", "status"];
|
|
317
|
+
};
|
|
318
|
+
};
|
|
200
319
|
};
|
|
201
320
|
readonly required: readonly ["summary", "findings", "uncertain"];
|
|
202
321
|
readonly description: "The corrected answer, on revise only; left out on approve and reject.";
|
|
@@ -213,11 +332,23 @@ export declare const REVIEW_SCHEMA: {
|
|
|
213
332
|
export declare function parseReview(value: unknown, draft?: ResearchAnswer): Review | null;
|
|
214
333
|
/** Lines as one DM of at most `MAX_MESSAGE_CHARS`, whole lines dropped from the end. */
|
|
215
334
|
export declare function fitMessage(lines: string[]): string;
|
|
335
|
+
/**
|
|
336
|
+
* A finding's line in a DM: the claim, for a post its platform, date and "snippet only" when it
|
|
337
|
+
* was not opened (0.23.0), then its first source in <...> so Discord shows the link without an
|
|
338
|
+
* embed.
|
|
339
|
+
*/
|
|
340
|
+
export declare function findingLine(f: ResearchFinding): string;
|
|
341
|
+
/**
|
|
342
|
+
* The DM's "Social:" line (0.23.0): each platform's status, with its note in brackets, in one
|
|
343
|
+
* line of at most `MAX_COVERAGE_LINE_CHARS`.
|
|
344
|
+
*/
|
|
345
|
+
export declare function coverageLine(coverage: readonly Coverage[]): string;
|
|
216
346
|
/**
|
|
217
347
|
* The DM a reviewed answer goes out as, at most `MAX_MESSAGE_CHARS`. Every piece of it was
|
|
218
|
-
* cleaned by `parseAnswer`; the title is the owner's own and is cleaned here.
|
|
219
|
-
*
|
|
220
|
-
*
|
|
348
|
+
* cleaned by `parseAnswer`; the title is the owner's own and is cleaned here. The "Social:" line
|
|
349
|
+
* (0.23.0, when the answer has `coverage`), the reviewer's note and `tail` are kept whole, in
|
|
350
|
+
* that order: `tail`, when given, is bounded by the caller (the "couldn't open" list and the
|
|
351
|
+
* queued line, 0.9.0). Without coverage or a tail the DM is what it was before 0.9.0.
|
|
221
352
|
*/
|
|
222
353
|
export declare function renderAnswer(title: string, answer: ResearchAnswer, review: Review, tail?: string): string;
|
|
223
354
|
/** Lines fitted into at most `max` characters, whole lines dropped from the end. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"research-answer.d.ts","sourceRoot":"","sources":["../src/research-answer.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAA;
|
|
1
|
+
{"version":3,"file":"research-answer.d.ts","sourceRoot":"","sources":["../src/research-answer.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAA;AACnD,OAAO,EAML,KAAK,cAAc,EACpB,MAAM,mBAAmB,CAAA;AAE1B,gGAAgG;AAChG,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAA;AAEtB,2CAA2C;AAC3C,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,MAAM,CAAA;IACb;;;OAGG;IACH,OAAO,EAAE,MAAM,EAAE,CAAA;IACjB;;;OAGG;IACH,QAAQ,CAAC,EAAE,cAAc,CAAA;IACzB,iGAAiG;IACjG,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,wHAAwH;IACxH,QAAQ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