Files
grant-outreach-engine/apps/outreach-review
Croissant Le Doux a92b75b315 feat(review+990pf): Part XV application info — parse the preselected-only kill signal, surface how-to-apply at review
Parser captures 990-PF Part XV line 2 (OnlyContriToPreselectedInd) even
when the application group is absent. Synthesis skips preselected-only
funders and closes their previously-synthesized grant rows
(serverCloseGrantsForFunders). Match detail page gains a 'How to apply
(funder's own 990-PF, Part XV)' panel — application form, deadlines,
restrictions, red do-not-pitch banner — fed by serverGetMatchDetail.

Backfill re-parse across all 747 NH foundations: 192 are preselected-
only; 62 of 123 synthesized foundation leads were unpitchable by their
funder's own filing and are now closed, with 24,436 stale pending
matches cleaned. Post re-match: 714 easy wins across 327 orgs, every
foundation lead now backed by a funder that actually accepts
applications. 156 tests green.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-16 21:46:58 -04:00
..

@novelpad/outreach-review

Human review queue for (org, grant) matches produced by the scoring pipeline in packages/outreach-core. A reviewer sees each pending match — organization, hero grant, total score, easy-win flag — and approves or rejects it. Approved matches are picked up downstream and synced into Apollo sequences.

Auth

There is no authentication in this app, by design. It is a tiny internal tool intended to run behind:

  • Google IAP (Identity-Aware Proxy) in any hosted environment, or
  • localhost only, for local development

Do not add better-auth (or any other auth library) to this workspace. If this app ever needs to leave an IAP-fronted network, that's a deliberate follow-up decision, not something to bolt on ad hoc here.

Development

yarn dev        # react-router dev
yarn build      # react-router build
yarn start      # serve the production build
yarn typecheck  # react-router typegen && tsc --noEmit

Requires DATABASE_URL pointing at the outreach Postgres instance (see packages/outreach-core). Optional: PG_POOL_MAX, PG_CONNECTION_TIMEOUT_MS.

Data contract

This app is a thin consumer of @novelpad/outreach-core. It assumes the following exports (server-side query/action functions live under the ./server subpath, matching the packages/core convention in novelpad-desktop):

// @novelpad/outreach-core
export const schema: /* drizzle schema */;
export type NpOutreachDatabase = /* PgDatabase<..., typeof schema> */;
export interface PendingReviewMatch {
  id: string;
  orgName: string;
  heroGrantTitle: string;
  totalScore: number;
  isEasyWin: boolean;
}
export type MatchReviewDecision = 'approved' | 'rejected';

// @novelpad/outreach-core/server
export function serverListPendingReviewMatches(
  db: NpOutreachDatabase,
): Promise<PendingReviewMatch[]>;
export function serverSetMatchReview(
  db: NpOutreachDatabase,
  matchId: string,
  decision: MatchReviewDecision,
): Promise<void>;

If packages/outreach-core's matches domain (src/matches/queries, src/matches/actions) lands with different names or a different PendingReviewMatch shape, update app/db.server.ts and app/routes/_index.tsx to match rather than reshaping data client-side.