Documentation
¶
Overview ¶
Package identity computes AI-event identity for a hook invocation.
This is a thin wrapper over DMG's `internal/device.Gather`. The only adapter logic that lives here is:
Bound the device probe with a 1-second context timeout. Hook invocations have a 15s total budget; identity must not be the thing that exhausts it.
Use the configured device ID when present, otherwise the machine ID; "unknown" when the probe budget ran out, as before (the event ingest contract for an empty device_id is unverified).
Single Gather call per Resolve — no probing twice for the two fields we need.
CustomerID is plumbed through as-is from the caller (typically read from `internal/aiagents/ingest.Snapshot`); device.Gather has no awareness of it.
Index ¶
Constants ¶
const ProbeTimeout = time.Second
ProbeTimeout is the upper bound on the device.Gather call. Tuned to leave room for enrichment + a 5s upload inside the 15s hook cap.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Info ¶
Info is the identity payload attached to every AI-agent event.
The wire field for DeviceID is `device_id`; the wire field for UserIdentity is `user_identity`. See internal/aiagents/event.