Index artifacts when they're created, not at batch boundaries.
Pattern
If downstream logic depends on artifacts being queryable, index immediately at write time.
DO
Index handoffs in PostToolUse Write hook (immediately after creation)
Use --file flag for fast single-file indexing
Trigger indexing from the same event that creates the artifact
DON'T
Wait for SessionEnd to batch-index
Rely on cron/scheduled jobs for time-sensitive data
Assume data will be available "soon enough"
Source Sessions
a541f08a: "Index at artifact creation time, not at SessionEnd"
1c21e6c8: "If downstream logic depends on artifacts, index at the moment they're created"
1---2name: index-at-creation3description: Index at Creation Time4---56# Index at Creation Time78Index artifacts when they're created, not at batch boundaries.910## Pattern1112If downstream logic depends on artifacts being queryable, index immediately at write time.1314## DO15- Index handoffs in PostToolUse Write hook (immediately after creation)16- Use `--file` flag for fast single-file indexing17- Trigger indexing from the same event that creates the artifact1819## DON'T20- Wait for SessionEnd to batch-index21- Rely on cron/scheduled jobs for time-sensitive data22- Assume data will be available "soon enough"2324## Source Sessions25- a541f08a: "Index at artifact creation time, not at SessionEnd"26- 1c21e6c8: "If downstream logic depends on artifacts, index at the moment they're created"
Run npx skillmds@latest add vibeeval/index-at-creation in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
Index at Creation Time It is listed under Coding & Dev Tools on SkillMD.
This skill has not completed SkillMD's automated safety review yet. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
vibeeval (@vibeeval) published this skill. Their other Agent Skills are listed on their SkillMD profile.