26 lines
647 B
TypeScript
26 lines
647 B
TypeScript
export type SourceId = "geonet" | "parliament" | "stats-nz" | "data-govt-nz" | "treasury" | "rbnz" | "mbie-jobs-online" | "companies-office" | "nz-gazette" | "electricity-authority";
|
|
|
|
export interface SourceDefinition {
|
|
id: SourceId;
|
|
name: string;
|
|
type: "geojson" | "html" | "sitemap" | "ckan" | "rss";
|
|
url: string;
|
|
}
|
|
|
|
export interface NormalizedItem {
|
|
sourceId: SourceId;
|
|
externalId: string;
|
|
title: string;
|
|
summary: string;
|
|
url: string;
|
|
publishedAt: string | null;
|
|
topics: string[];
|
|
raw: unknown;
|
|
metrics?: Record<string, number | string | null>;
|
|
}
|
|
|
|
export interface ScoredItem {
|
|
score: number;
|
|
reasons: string[];
|
|
}
|