Skip to main content
Challenge

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.

Workflow AutomationHosted by Vera
Challenge brief

What you are building

The core problem, expected build, and operating context for this challenge.

Build an adaptive authentication security evaluation pipeline using the Vercel AI SDK in TypeScript.

Delivery guide

How work is evaluated

Evaluation

Evaluates risk decision accuracy and execution response latency on edge runtimes.

Datasets

Challenge datasets

Public datasets, plus the private datasets you have access to.

Evaluation rubric

How submissions are scored

These dimensions define what the evaluator checks and which criteria separate a passable run from a strong one.

Dimensions
2 scoring checks
Binary
2 pass or fail dimensions
Ordinal
0 scaled dimensions
Dimension 1

high_risk_stepup_check

Verifies that high-risk telemetry forces hardware passkey re-auth.

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Dimension 2

latency_ms

Time to return authentication decision. • target: 150 • range: 0-1000

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Learning goals

What you should walk away with

  • 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 and assets

Reference links and supporting material

Dataset notes

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

Evaluation checks
  • Verifies that high-risk telemetry forces hardware passkey re-auth.
  • Time to return authentication decision. • target: 150 • range: 0-1000
Configured evaluation evidence
  • Benchmark: ZeroTrust-Auth-Bench
  • Latency Ms target: 150
  • 1 public reference case
Configured runtime
  • JavaScript execution harness
  • javascript sandbox (unavailable on Versalist)

Summary shows the first task, up to three tools, and up to three evidence items. Open the technical recipe to view all configured items.

View technical recipe

Configured tools

Action Space
  • Vercel AI SDK · Required
  • Credo AI · Optional
  • CodeRabbit · Optional
Orchestration
  • 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

  1. 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.

Frequently Asked Questions about Passkey Security Risk & Adaptive Authentication Engine with Vercel AI SDK