Commit Graph
6 Commits
Author SHA1 Message Date
adamfandClaude Opus 5.5 af50e6c8ab Add a job leads inbox that finds and scores postings
Test and deploy / test (push) Successful in 1m55s
Test and deploy / deploy (push) Successful in 59s
The tracker recorded applications but could not find jobs. A new
pipeline (services/job_leads.go, job_sources.go) polls a watch list of
sources on a timer or on request, files unseen postings as leads, marks
which pass a keyword and location pre-filter, and has Claude score those
against a single search profile through a fourth internal Python route,
/internal/jobs/score.

Sources are Greenhouse, Lever and Ashby company boards (public JSON) and
Adzuna and Reed keyword searches (API keys). The two search fetchers are
written from the providers' documentation and tested only against stubs.

Leads are their own table, not a job status, and are not soft deleted:
the (source_kind, external_id) index is the dedup, so a dismissed lead
has to remain a row. A lead reaches the tracker only by promotion, which
goes through UpsertJobApplication. That upsert moves from the capture
handler into services so promotion and the fetcher can share it; the
capture endpoint's behaviour is unchanged.

/cv/leads is the page: inbox, watch list and profile form. The timer is
off unless JOB_LEADS_ENABLED=true and never runs at start-up, so a
deploy spends no Claude calls.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-12 15:03:46 +01:00
adamfandClaude Opus 5.5 71344a1f8d Declare GraphQL auth in the schema and drop the Go Claude client
Authorisation: @admin and @signedIn schema directives replace the 25
hand-copied resolver checks. A test fails if a mutation has neither and
is not on the public allow-list, so a new mutation cannot ship unguarded.

IDs: uint model IDs bind through graphql.UintID, removing the ten
int(obj.ID) resolvers.

Job status is a GraphQL enum, tied to services.statusOrder by a test.
Input is strict, so the mutations no longer coerce an unknown status to
"applied"; output is lenient so one legacy row cannot fail the list.

deleteJobApplication and deleteJobAppReference now error on a missing id
like the other deletes.

The rowing reader, the job extractor and now the email classifier reach
the Python service through one services.CallPython helper. The email
pipeline's prompt and fence stripping moved to Python, and
anthropic-sdk-go is gone from go.mod.

Fix the auth test fixture, whose 11-byte secret had been panicking the
services test package since InitAuth began requiring 32 bytes. Add a
test that keeps the python service's compose environment list in step
with the env registry.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-12 14:39:19 +01:00
adamfandClaude Opus 5.5 b8670246a8 Add browser job capture to the job tracker
Deploy with Docker Compose / deploy (push) Successful in 1m31s
A Violentmonkey userscript, served by the site and installed from /cv/jobs,
adds the posting open in the browser (LinkedIn, an ATS, any company page) to
the tracker. Claude reads the title, company and location off the page text.

- Three token-guarded REST routes under /api/jobs/capture (status, extract,
  upsert). They take a bearer token, JOB_CAPTURE_TOKEN, because the auth
  cookies are SameSite=Lax and never sent from another origin. An unset token
  switches the routes off.
- The upsert matches on a canonical posting URL, then (company, job title),
  so a capture and the email pipeline do not make two rows for one job.
- The Claude call is a new internal Python route, /internal/jobs/extract,
  alongside the rowing reader; the client and fence stripping they share move
  to python/app/claude.py.
- New "saved" status ranked below "applied", and a description column holding
  the posting text, shown per row on the tracker.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-12 13:33:28 +01:00
adamfandClaude Opus 5 64df70e5d2 Document codebase: comments, per-area READMEs, deployment guide
Readability pass across all four areas of the stack. Comments explain why
rather than what, concentrated at the points where behaviour is non-obvious:
concurrency, caching, auth, scraping and nginx templating.

Backend: doc comments on every exported declaration across handlers,
services, models and resolvers. Resolver commentary lives inside function
bodies so gqlgen does not strip it on regeneration; schema files use #
comments rather than description blocks so introspection output is
unchanged. Extracted the duplicated auth-cookie blocks into helpers.

Frontend: header comments on every component, store and view, including
STATUS: notes marking which of the parallel/legacy views are still live.
Documented the non-reactive animation-state pattern, the homeData hub and
the WebSocket stale-socket guard. Removed a few dead imports and named the
reconnect-backoff and poll-interval constants.

Python: module and function docstrings covering the Travelodge scraping
contract, the deadline threading, the two-executor concurrency and the
NDJSON streaming protocol.

Infra: header blocks on every compose file, nginx template, Dockerfile and
entrypoint, covering the config selection, envsubst allow-lists, rate-limit
semantics and volume persistence. Hoisted the duplicated envsubst variable
list in nginx/entrypoint.sh.

New: backend/README.md, python/README.md, DEPLOYMENT.md, .env.example,
backend/graph/doc.go. Refreshed vue/README.md. Corrected CLAUDE.md, which
stated a 24h access token where main.go sets 7 days.

No behaviour change. go build/vet, vite build, py_compile and docker
compose config all pass.

Co-Authored-By: Claude Opus 5 <[email protected]>
2026-09-16 15:57:48 +01:00
adamfandClaude Opus 4.6 b96b7d7a93 Split schema.graphql and schema.resolvers.go into per-domain files
Deploy with Docker Compose / deploy (push) Successful in 3m36s
Move Query/Mutation field declarations from the monolithic schema.graphql
into each domain's .graphql file using extend type, so gqlgen places
resolvers in the matching *.resolvers.go files. Extract helper functions
into *_helpers.go files to prevent gqlgen from commenting them out.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
2026-04-15 18:57:23 +01:00
adamfandClaude Sonnet 4.6 8f3c369ed8 Add job application tracker (admin-only)
Deploy with Docker Compose / deploy (push) Has been cancelled
Full CRUD GraphQL API for tracking job applications with status workflow.
Frontend component in CV view, hidden from print. Login now redirects to
intended route after auth via query param.

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
2026-04-13 09:51:31 +01:00