Katkat

Build Reliable Employee-Operations and Expense Intelligence Systems

RipplingSoftware Engineer · Onsite

Last updated

A multi-part system-design interview covering tagged event aggregation, driver-pay accounting, employee offboarding, and an LLM-backed expense assistant. Candidates must distinguish approximate dashboards from exact billing and design reliable workflows across failing dependencies.

Build Reliable Employee-Operations and Expense Intelligence Systems

Design four connected capabilities: a tagged event counter for dashboards and billing, a driver-pay ledger, an employee-termination orchestrator across external systems, and an LLM-backed expense assistant over employee and reimbursement records.

Constraints & Assumptions

  • Mobile clients can upload a large offline backlog; events may be late or duplicated and cannot be silently lost.
  • Dashboards tolerate tens of minutes of freshness delay, but monthly billing must reconcile exactly.
  • Some termination actions are parallelizable, some have prerequisites, and some cannot be safely repeated.
  • The assistant must enforce company and employee data boundaries before model access.

Clarifying Questions to Ask

  • Which event fields form the billing identity and which are mutable tags?
  • Does a pay-rate change affect only future work or also unsettled historical work?
  • Which termination systems support idempotency, webhooks, or compensating actions?

Part 1 — Event counter

Design ingestion, deduplication, tagged aggregation, dashboard serving, and exact monthly billing for mobile and web SDK events.

What This Part Should Cover

  • Durable acceptance and idempotency
  • Event-time windows and late-data policy
  • A reconciled billing ledger separate from approximate dashboards

Part 2 — Driver pay

Model drivers, rate history, completed jobs, overlapping time spans, total accrued cost, and paid versus unpaid amounts without rewriting history.

What This Part Should Cover

  • Immutable work records and effective-dated rates
  • Overlap and duplicate semantics
  • Accrual, payment, and reconciliation APIs

Part 3 — Termination workflow

Orchestrate seven to ten dependent revocation and payout actions, minimize completion time, and resume automatically after interruption.

What This Part Should Cover

  • A persisted DAG or saga state machine
  • Idempotency and compensation per step
  • Priority, retry, webhook, and operator escalation behavior

Part 4 — Expense assistant

Turn a natural-language expense question into safe structured operations over two large JSON-backed datasets, support aggregates and streaming, and explain when to use deterministic tools versus an agent.

What This Part Should Cover

  • Tenant-scoped parsing and authorization
  • Typed query plans and aggregate correctness
  • Streaming UX without leaking unvalidated partial results

Hints

Hint 1

Separate approximate serving from exact ledgers: Dashboards can use compacted aggregates, but payroll, billing, and access revocation need durable state, explicit identities, and replayable evidence.

Follow-up questions

  • How would a 100-fold event increase change the architecture?
  • How would you prove that a termination workflow is complete?