Passkey Security Risk & Adaptive Authentication Engine with Vercel AI SDK
GovTech Singapore's transition to passkeys requires intelligent risk-based authentication triggers during user sessions. Build a dynamic authentication policy engine using the Vercel AI SDK to evaluate session context and detect credential misuse. Achieve real-time step-up security decisions with low latency.
What you are building
Build an adaptive authentication security evaluation pipeline using the Vercel AI SDK in TypeScript.
How work is evaluated
Evaluates risk decision accuracy and execution response latency on edge runtimes.
Datasets
Public datasets, plus the private datasets you have access to.
How submissions are scored
high_risk_stepup_check
Verifies that high-risk telemetry forces hardware passkey re-auth.
This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.
latency_ms
Time to return authentication decision. • target: 150 • range: 0-1000
This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.
Learning goals
Utilize Vercel AI SDK `generateObject` for structured security policy outputs
Process login session telemetry (device fingerprint, IP velocity, geo-anomaly)
Determine dynamic challenge requirements (Passkey challenge vs multi-factor challenge)
Implement edge-compatible streaming response hooks for authentication state updates
Resources
Synthetic user authentication telemetry logs containing normal and anomaly access patterns.
Challenge setup
Evaluates risk decision accuracy and execution response latency on edge runtimes.
Challenge input
JSON telemetry object
AI SDK
Assigned framework for TypeScript AI applications.
Evaluated output
JSON authentication decision
- Verifies that high-risk telemetry forces hardware passkey re-auth.
- Time to return authentication decision. • target: 150 • range: 0-1000
- Benchmark: ZeroTrust-Auth-Bench
- Latency Ms target: 150
- 1 public reference case
- JavaScript execution harness
- javascript sandbox (unavailable on Versalist)
Shows the first task, up to three tools, and up to three evidence items.
View technical recipe
Configured tools
- Vercel AI SDK · Required
- Credo AI · Optional
- CodeRabbit · Optional
- Vercel AI SDK · Required
Evaluation contract
- high_risk_stepup_check · Weight 1
- latency_ms · Weight 1
Metrics
- latency_ms · Target 150
Benchmarks
- ZeroTrust-Auth-Bench
- security
Reference cases
- 1 public reference case
Workflow tasks
- Task 1
Input: JSON telemetry object
Output: JSON authentication decision
Execution harness: JavaScript
Evaluation tools
- AI SDK · Agent Framework
Recipe freeze marker
No recipe freeze time is recorded.