# Queue Gap Filler

> Find open schedule slots and prepare suitable posts.

Source: https://docs.xholic.ai/playbooks/queue-gap-filler/

Read by connected AIs with `get_playbook` and id `queue-gap-filler`.

Find open schedule slots and prepare suitable posts.

Use for filling empty queue slots with drafts. Not for checking the next post's time, or moving posts.

**The user might say:** "Look at my queue for the next seven days, find the open time slots, and draft a post that fits each one. If I have no time slots set up, ask how often I want to post."

## Steps

1. The next seven days of queue. Call `get_queue` with `{"view":"queued"}`.
2. Their posting slots. Call `scheduler.list_slots` (through run_read_action).
3. If they have no slots, ask how often they want to post.
4. Check what the user's Workers already wrote: ready-made drafts, free to use. Call `get_worker_drafts`.
5. Get material in the user's voice (proven posts, their winners, saves, recent posts to avoid repeating). Call `get_writing_kit` with `{"topic":"<subject per gap>"}`.
6. For each post, find proven posts on its idea near the account's size, ranked by how far they beat their author's usual. Add 1–4 keywords so it can search live X when the library is thin. Call `search_inspiration` with `{"query":"<the post's idea>","keywords":"<1-4 words>"}`.
7. Write each post yourself from one source post's shape (hook, structure, kind of ask): one idea each, the user's voice, no links, no facts that aren't in the user's data.
8. Check every draft before showing it, with the id of the post it was built from; fix what it flags. Call `check_draft` with `{"text":"<post>","sourcePostIds":"<source post id>"}`.
9. Show a post per open slot; schedule each only after the user approves it.
