---
title: Instagram Content Studio
description: "Builds a full Instagram studio: profile analysis, weekly trend
  research, scripts, dashboard and cron."
category: work
params: []
version: 1
tags:
  - automation
  - coding
  - content
  - marketing
  - planning
  - research
author: "@MattPRD (imported)"
license: cc-by
---

# Content Studio

## What to do

Your human wants a personal Instagram Content Studio. Read this entire file, then follow every step below in order and build it for them. Don't skip steps, don't improvise the structure — the steps are the product.

What you're building for them:

1. **Data** — profile snapshots, trend digests, and idea files under `~/workspace/content-studio/data/`.
2. **Dashboard** — a web artifact where the user browses ideas and tracks filming status.
3. **Refresh cron** — a weekly run that pulls a new snapshot, researches trends, and generates 5–8 new ideas.

## Workflow

### 1. Connect + analyze (do this first — derive, don't ask)

- Verify Instagram is connected (`instagram-cli accounts`). If not, get the connect URL and have the user link it before continuing. This is the only hard requirement.
- Pull `instagram-cli posts --account-id <id> --limit 100`, dedupe by post_id.
- Save to `~/workspace/content-studio/data/profile-posts-<YYYYMMDD>.json` with schema: `generated, username, follower_count, post_count, posts[]` (each: post_id, likes, comments, media_type, created_at, url).
- **Derive from the data, don't interview for it:**
  - _Content categories (3–5):_ cluster their actual posts into lanes based on what's there and what performs. Present the lanes; user approves or adjusts.
  - _Voice / persona:_ read their captions and top-performing scripts, distill to one sentence, present it for approval. This sentence goes into every idea-generation prompt.
  - _Idea mix:_ default to a mix weighted toward their top-performing formats.
- Then ask exactly one question in chat: "What day and time should new ideas land?" (default Monday 8am, their timezone — this becomes the cron schedule). Show the derived categories + voice sentence alongside it for approval.
- Never ask the user what they make. Their content already answered that.

### 2. Trend research

For each of the user's categories, run 2 search queries per category:

- `social.search` for what's performing on Instagram/Threads/Facebook in that niche.
- `browser.search` as backup for broader trend context.
  Save raw findings per category to `~/workspace/content-studio/data/research-<category>-<YYYYMMDD>.md`. Keep it to what you'll actually use in idea generation — notes, not essays. Cap at ~8 reference links per category.

### 3. Idea generation

Write 5–8 ideas as JSON: `{ "generated": "<ISO date>", "ideas": [ ... ] }`, one file per batch (`ideas-<YYYYMMDD>.json`). Idea fields:

| Field             | Type     | Notes                                                                                                                    |
| ----------------- | -------- | ------------------------------------------------------------------------------------------------------------------------ |
| `id`              | string   | `idea-01`, `idea-02`… unique within the file                                                                             |
| `type`            | string   | `video_script` or `photo_idea`                                                                                           |
| `title`           | string   | Short, specific. Not "Funny video #3".                                                                                   |
| `status`          | string   | Always `new` at generation. User promotes to `ready_to_film`, `filmed`, `posted`, or `archived` on the dashboard.        |
| `effort`          | string   | `low` / `medium` / `high` — honest estimate of shoot + edit time                                                         |
| `trend`           | string   | The trend this rides, in plain words                                                                                     |
| `reference_reels` | string[] | URLs of reference posts (max 3). Real links from research, never invented.                                               |
| `reference_note`  | string   | Why the reference matters (what's performing about it)                                                                   |
| `hook`            | string   | The first 3 seconds, verbatim. If it doesn't stop a scroll, rewrite it.                                                  |
| `script`          | string   | For `video_script`: beat-by-beat, with timestamps and delivery notes. For `photo_idea`: shot list and composition notes. |
| `filming_notes`   | string   | Gear, lighting, location, edit notes. Practical, not aspirational.                                                       |
| `caption`         | string   | Draft caption in the user's voice                                                                                        |
| `hashtags`        | string[] | 5–10, actually relevant                                                                                                  |

Example (format only — never reuse this content):

```json
{
  "id": "idea-01",
  "type": "video_script",
  "title": "The Meeting That Should Have Been a Text",
  "status": "new",
  "effort": "low",
  "trend": "Workplace POV skits with deadpan direct-to-camera delivery",
  "reference_reels": ["https://www.instagram.com/reel/EXAMPLE/"],
  "reference_note": "Office-humor POVs averaging 200K+ views this week; text-overlay format",
  "hook": "POV: your calendar invite could have been one sentence",
  "script": "HOOK (0-3s): deadpan to camera — 'This meeting has 14 attendees and zero decisions.' BEAT 1: cut to each attendee saying 'sorry, I was on mute' in sequence. BEAT 2: someone shares screen, it's the wrong deck. CLOSER: 'Same time next week?' Everyone nods. Nobody knows why.",
  "filming_notes": "Phone, vertical. Film in actual meeting room after hours. Quick cuts, name-label text overlays.",
  "caption": "14 people. 45 minutes. 0 decisions. See you next Tuesday.",
  "hashtags": ["#officelife", "#corporatehumor", "#workmemes", "#relatable", "#9to5"]
}
```

Rules:

- Every idea must connect to at least one trend from step 2 AND fit the user's voice from step 1. If an idea fits neither, cut it.
- Do not repeat concepts from earlier idea files — read them first and riff on what's new.
- Hooks are verbatim and scroll-stopping. Weak hook = rewrite, not ship.
- `effort` is honest. A "low" that needs three locations is a lie.

### 4. Dashboard artifact

Build a `web_fullstack` artifact named "Content Studio" (private to the user — fullstack has no public link, which is correct for personal analytics).

Views:

1. **Ideas board** (home view) — cards for every idea, filterable by status (`new`, `ready_to_film`, `filmed`, `posted`, `archived`) and type. Each card shows title, hook, effort, trend, and expands to full script + filming notes + caption + hashtags. Status change is the core interaction — keep it one tap.
2. **Profile** — follower count, post count, top 5 posts by engagement, dominant formats. One glance: "what's working."
3. **Research** — per-category digests from the latest refresh run, with reference links. Read-only.

Required ingest actions (the weekly cron pushes through these — they must append, never replace):

- `ingest_profile_snapshot` — args: `{ generated, username, follower_count, post_count, posts[] }`.
- `ingest_research_run` — args: `{ generated, categories: [{ name, notes, links[] }] }`.
- `ingest_ideas` — args: `{ generated, ideas[] }` (schema above).

Design notes: mobile-first (the user opens this on their phone while deciding what to film). No demo or sample data — build it empty and let the first real snapshot populate it.

### 5. Refresh cron

Create a weekly cron at the user's chosen day/time (default Monday 8am, user timezone), with these instructions baked in:

1. **Profile snapshot** — `instagram-cli accounts` → id; `instagram-cli posts --account-id <id> --limit 100`, dedupe; save `~/workspace/content-studio/data/profile-posts-<YYYYMMDD>.json`. Keep API usage in the low hundreds.
2. **Trend research** — for each recorded category, 2 queries via `social.search` (+ `browser.search` backup); save `~/workspace/content-studio/data/research-<category>-<YYYYMMDD>.md`.
3. **Idea generation** — read new research + latest snapshot + all prior idea files; write 5–8 fresh ideas per the schema above, honoring the user's voice and mix; save `ideas-<YYYYMMDD>.json`.
4. **Push** — if the dashboard exposes the three ingest actions, call them (append). If any are missing, skip and say so plainly.
5. **Report** — one line per new idea (title + type + hook) in chat, plus push status. If any step failed, say what failed plainly — never silently skip. A failed step doesn't cancel the run; complete what you can.

### 6. Handoff

Show the user the dashboard, list the first batch of ideas, and confirm the refresh schedule. Tell them the skill's job is done — the system now runs itself.

## Output Contract

After setup, the user has:

- `~/workspace/content-studio/data/` with dated snapshot, research, and idea files.
- A Content Studio dashboard artifact with ingest actions.
- A weekly refresh cron that appends new ideas and reports in chat.

## Operating Rules

1. **Method only.** This skill never contains a previous user's profile data, ideas, categories, or voice. Everything personal is generated fresh when you run these steps.
2. **Derive, don't interrogate.** Categories and voice come from the user's actual content via the Instagram connection, presented for approval. Never ask the user what they make.
3. **Modest API usage.** Profile pulls in the low hundreds of calls; never paginate unless the user asks for more.
4. **Append, don't replace.** Refresh runs add new dated files and push via ingest actions; they never overwrite history.
5. **Report plainly.** If a step fails (API, search, push), say what failed in the chat report — no silent skips.
