Skip to content

@grabm/abm/playback/headless / Function: inspectAgent() ​

ts
import { inspectAgent } from '@grabm/abm/playback/headless'

Usage guide · Package exports

ts
function inspectAgent(detail, minute): object;

Intended schedule and observed records remain separate in the returned detail.

Parameters ​

detail ​

AgentDetail

minute ​

number

Returns ​

object

agent ​

ts
agent: object = detail.agent;

agent.agenda ​

ts
agenda: object[];

agent.availableModes ​

ts
availableModes: string[];

agent.cohortId ​

ts
cohortId: string = idSchema;

agent.conditionedJourneys? ​

ts
optional conditionedJourneys?: object[];

agent.conditionedPresence? ​

ts
optional conditionedPresence?: object[];

agent.decisions ​

ts
decisions: object[];

agent.demographics ​

ts
demographics: Record<string, string | number | boolean | null> = demographicsSchema;

agent.entryMinute? ​

ts
optional entryMinute?: number;

agent.exitMinute? ​

ts
optional exitMinute?: number;

agent.extensions ​

ts
extensions: Record<string, JSONType>;

agent.gatewayFacilityId ​

ts
gatewayFacilityId: string | null;

agent.gatewayReturn? ​

ts
optional gatewayReturn?: object;

agent.gatewayReturn.actualExitMinute? ​

ts
optional actualExitMinute?: number;

agent.gatewayReturn.plannedExitMinute ​

ts
plannedExitMinute: number = finiteNonnegativeSchema;

agent.gatewayReturn.status ​

ts
status: "completed" | "unresolved" | "not-started";

agent.homeFacilityId ​

ts
homeFacilityId: string | null;

agent.householdId? ​

ts
optional householdId?: string;

agent.householdPassenger? ​

ts
optional householdPassenger?: boolean;

agent.id ​

ts
id: string = idSchema;

agent.modePreferences ​

ts
modePreferences: Record<string, number>;

agent.needs? ​

ts
optional needs?: object[];

agent.neighborhood? ​

ts
optional neighborhood?: object;

agent.neighborhood.journeys ​

ts
journeys: object[] = conditionedJourneysSchema;

agent.neighborhood.snapshotId ​

ts
snapshotId: string = idSchema;

agent.neighborhood.version ​

ts
version: 1;

agent.neighborhood.windows ​

ts
windows: object[];

agent.preferences ​

ts
preferences: Record<string, number> = weightVectorSchema;

agent.profileId ​

ts
profileId: string = idSchema;

agent.requiresEscort? ​

ts
optional requiresEscort?: boolean;

agent.schoolEscortPlans? ​

ts
optional schoolEscortPlans?: object[];

decisions ​

ts
decisions: object[] = detail.decisions;

elapsedDecisions ​

ts
elapsedDecisions: object[];

intendedAgenda ​

ts
intendedAgenda: object[] = detail.agent.agenda;

trips ​

ts
trips: object[] = detail.trips;

Documentation for the grABM library.