# `Agentic.Loop.Stages.WorkspaceSnapshot`

Gathers workspace context and injects it into the conversation.

Only active on the first pipeline pass (`ctx.turns_used == 0`). Sits before
ContextGuard in every pipeline that includes it.

Responsibilities:
- Gather workspace context: git branch/status/recent commits, file tree,
  instruction files, project config
- Inject a structured workspace context message into `ctx.messages`
- Check `ctx.callbacks[:on_workspace_snapshot]` — if provided, use the host's
  snapshot; otherwise gather automatically
- On subsequent passes, no-ops (the snapshot is already in messages)

---

*Consult [api-reference.md](api-reference.md) for complete listing*
