mirror of
https://github.com/prdlk/jobyssey.git
synced 2026-11-02 13:12:49 +00:00
feat(worker): add weekly job scrape worker with portal integrations, scoring, and Twenty CRM sync
This commit is contained in:
1 parent
f9daa06aa1
commit
f0190dba41
22 files changed
+2706
No files matched your search
@@ -0,0 +1,40 @@
|
||||
{
|
||||
"$schema": "./node_modules/wrangler/config-schema.json",
|
||||
"name": "jobyssey-scrape",
|
||||
"main": "src/index.ts",
|
||||
"compatibility_date": "2026-09-21",
|
||||
"compatibility_flags": ["nodejs_compat"],
|
||||
"observability": { "enabled": true, "head_sampling_rate": 1 },
|
||||
// Scoring is one Claude call per posting; CPU is mostly JSON + HTML parsing.
|
||||
"limits": { "cpu_ms": 300000 },
|
||||
// Profile + rubric + queries are bundled as text so the Worker scores against
|
||||
// the same files /rank reads locally. scripts/bundle-profile.ts copies them
|
||||
// into src/profile/ before every deploy; `wrangler deploy` is the sync.
|
||||
"rules": [{ "type": "Text", "globs": ["**/*.md"], "fallthrough": true }],
|
||||
"workflows": [
|
||||
{
|
||||
"name": "weekly-scrape",
|
||||
"binding": "WEEKLY_SCRAPE",
|
||||
"class_name": "WeeklyScrape",
|
||||
// Cloudflare cron: weekdays are 1=SUN..7=SAT, so name the day. 13:00 UTC = 09:00 EDT / 08:00 EST.
|
||||
"schedules": ["0 13 * * MON"]
|
||||
}
|
||||
],
|
||||
"d1_databases": [
|
||||
{
|
||||
"binding": "POSTINGS",
|
||||
"database_name": "jobyssey-postings",
|
||||
"database_id": "c1df7f34-ed2b-4c74-b6af-10ef15c2db5d"
|
||||
}
|
||||
],
|
||||
"browser": { "binding": "BROWSER" },
|
||||
"vars": {
|
||||
"TWENTY_BASE_URL": "https://crm.prad.nu",
|
||||
"TWENTY_ASSIGNEE_ID": "6fa482f3-cebd-4bfa-a096-d454697afc54",
|
||||
"AI_GATEWAY_URL": "https://gateway.ai.cloudflare.com/v1/54c3f12c7eb138d1c426bcdbddb9d6fe/jobyssey/anthropic",
|
||||
"SCORING_MODEL": "claude-sonnet-4-5",
|
||||
// Hard cap on Claude calls per run; the rest of the pool is reported, not scored.
|
||||
"MAX_SCORED_PER_RUN": "100"
|
||||
}
|
||||
// Secrets (wrangler secret put): TWENTY_API_KEY, ANTHROPIC_API_KEY, RUN_TOKEN
|
||||
}
|
||||
Reference in new issue
Block a user