@julioventura/opensquad 0.1.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +433 -0
- package/_opensquad/config/playwright.config.json +11 -0
- package/_opensquad/core/architect.agent.yaml +112 -0
- package/_opensquad/core/best-practices/_catalog.yaml +126 -0
- package/_opensquad/core/best-practices/blog-post.md +132 -0
- package/_opensquad/core/best-practices/blog-seo.md +127 -0
- package/_opensquad/core/best-practices/brand-resolution-checklist.md +172 -0
- package/_opensquad/core/best-practices/copywriting.md +441 -0
- package/_opensquad/core/best-practices/data-analysis.md +401 -0
- package/_opensquad/core/best-practices/email-newsletter.md +118 -0
- package/_opensquad/core/best-practices/email-sales.md +110 -0
- package/_opensquad/core/best-practices/image-design.md +348 -0
- package/_opensquad/core/best-practices/instagram-feed.md +235 -0
- package/_opensquad/core/best-practices/instagram-reels.md +112 -0
- package/_opensquad/core/best-practices/instagram-stories.md +107 -0
- package/_opensquad/core/best-practices/linkedin-article.md +116 -0
- package/_opensquad/core/best-practices/linkedin-post.md +121 -0
- package/_opensquad/core/best-practices/researching.md +349 -0
- package/_opensquad/core/best-practices/review.md +269 -0
- package/_opensquad/core/best-practices/run-recovery.md +61 -0
- package/_opensquad/core/best-practices/social-networks-publishing.md +327 -0
- package/_opensquad/core/best-practices/squad-creation-checklist.md +32 -0
- package/_opensquad/core/best-practices/strategist.md +344 -0
- package/_opensquad/core/best-practices/technical-writing.md +365 -0
- package/_opensquad/core/best-practices/twitter-post.md +105 -0
- package/_opensquad/core/best-practices/twitter-thread.md +122 -0
- package/_opensquad/core/best-practices/whatsapp-broadcast.md +107 -0
- package/_opensquad/core/best-practices/youtube-script.md +122 -0
- package/_opensquad/core/best-practices/youtube-shorts.md +112 -0
- package/_opensquad/core/defaults/youtube-video-assembly.json +84 -0
- package/_opensquad/core/prompts/build.prompt.md +613 -0
- package/_opensquad/core/prompts/design.prompt.md +606 -0
- package/_opensquad/core/prompts/discovery.prompt.md +377 -0
- package/_opensquad/core/prompts/sherlock-instagram.md +123 -0
- package/_opensquad/core/prompts/sherlock-linkedin.md +73 -0
- package/_opensquad/core/prompts/sherlock-shared.md +684 -0
- package/_opensquad/core/prompts/sherlock-twitter.md +78 -0
- package/_opensquad/core/prompts/sherlock-youtube.md +85 -0
- package/_opensquad/core/runner.pipeline.md +743 -0
- package/_opensquad/core/skills.engine.md +384 -0
- package/bin/opensquad.js +108 -0
- package/dashboard/index.html +15 -0
- package/dashboard/package-lock.json +1964 -0
- package/dashboard/package.json +28 -0
- package/dashboard/public/assets/avatars/Female1_1wave.png +0 -0
- package/dashboard/public/assets/avatars/Female1_2wave.png +0 -0
- package/dashboard/public/assets/avatars/Female1_blink.png +0 -0
- package/dashboard/public/assets/avatars/Female1_talk.png +0 -0
- package/dashboard/public/assets/avatars/Female2_1wave.png +0 -0
- package/dashboard/public/assets/avatars/Female2_2wave.png +0 -0
- package/dashboard/public/assets/avatars/Female2_blink.png +0 -0
- package/dashboard/public/assets/avatars/Female2_talk.png +0 -0
- package/dashboard/public/assets/avatars/Female3_blink.png +0 -0
- package/dashboard/public/assets/avatars/Female3_talk.png +0 -0
- package/dashboard/public/assets/avatars/Female3_wave.png +0 -0
- package/dashboard/public/assets/avatars/Female4_blink.png +0 -0
- package/dashboard/public/assets/avatars/Female4_talk.png +0 -0
- package/dashboard/public/assets/avatars/Female4_wave.png +0 -0
- package/dashboard/public/assets/avatars/Female5_blink.png +0 -0
- package/dashboard/public/assets/avatars/Female5_talk.png +0 -0
- package/dashboard/public/assets/avatars/Female5_wave.png +0 -0
- package/dashboard/public/assets/avatars/Female6_blink.png +0 -0
- package/dashboard/public/assets/avatars/Female6_talk.png +0 -0
- package/dashboard/public/assets/avatars/Female6_wave.png +0 -0
- package/dashboard/public/assets/avatars/Male1_1wave.png +0 -0
- package/dashboard/public/assets/avatars/Male1_2wave.png +0 -0
- package/dashboard/public/assets/avatars/Male1_blink.png +0 -0
- package/dashboard/public/assets/avatars/Male1_talk.png +0 -0
- package/dashboard/public/assets/avatars/Male2_1wave.png +0 -0
- package/dashboard/public/assets/avatars/Male2_2wave.png +0 -0
- package/dashboard/public/assets/avatars/Male2_blink.png +0 -0
- package/dashboard/public/assets/avatars/Male2_talk.png +0 -0
- package/dashboard/public/assets/avatars/Male3_blink.png +0 -0
- package/dashboard/public/assets/avatars/Male3_talk.png +0 -0
- package/dashboard/public/assets/avatars/Male3_wave.png +0 -0
- package/dashboard/public/assets/avatars/Male4_blink.png +0 -0
- package/dashboard/public/assets/avatars/Male4_talk.png +0 -0
- package/dashboard/public/assets/avatars/Male4_wave.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_black_down.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_black_down_coding-1.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_black_down_coding.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_black_up.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_white_down.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_white_down_coding-1.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_white_down_coding.png +0 -0
- package/dashboard/public/assets/desks/desktop_set_white_up.png +0 -0
- package/dashboard/public/assets/furniture/armchair_tan.png +0 -0
- package/dashboard/public/assets/furniture/armchair_tan_down.png +0 -0
- package/dashboard/public/assets/furniture/backpack_blue.png +0 -0
- package/dashboard/public/assets/furniture/backpack_red.png +0 -0
- package/dashboard/public/assets/furniture/blinds.png +0 -0
- package/dashboard/public/assets/furniture/blinds_large_closed_white.png +0 -0
- package/dashboard/public/assets/furniture/bookshelf.png +0 -0
- package/dashboard/public/assets/furniture/bookshelf_purple_tall.png +0 -0
- package/dashboard/public/assets/furniture/bulletin_board.png +0 -0
- package/dashboard/public/assets/furniture/clock.png +0 -0
- package/dashboard/public/assets/furniture/coffee_mug.png +0 -0
- package/dashboard/public/assets/furniture/coffee_mug_blue.png +0 -0
- package/dashboard/public/assets/furniture/coffee_table.png +0 -0
- package/dashboard/public/assets/furniture/coffeepot_right.png +0 -0
- package/dashboard/public/assets/furniture/coffeetable_black_horizontal.png +0 -0
- package/dashboard/public/assets/furniture/couch.png +0 -0
- package/dashboard/public/assets/furniture/couch_tan_down.png +0 -0
- package/dashboard/public/assets/furniture/cushion_blue.png +0 -0
- package/dashboard/public/assets/furniture/cushion_tan.png +0 -0
- package/dashboard/public/assets/furniture/desk_wood.png +0 -0
- package/dashboard/public/assets/furniture/fancy_rug.png +0 -0
- package/dashboard/public/assets/furniture/fancy_rug_wide.png +0 -0
- package/dashboard/public/assets/furniture/flowers1.png +0 -0
- package/dashboard/public/assets/furniture/flowers2.png +0 -0
- package/dashboard/public/assets/furniture/lamp_tan.png +0 -0
- package/dashboard/public/assets/furniture/lantern.png +0 -0
- package/dashboard/public/assets/furniture/monstera.png +0 -0
- package/dashboard/public/assets/furniture/monstera_small.png +0 -0
- package/dashboard/public/assets/furniture/picture_frame.png +0 -0
- package/dashboard/public/assets/furniture/plant1.png +0 -0
- package/dashboard/public/assets/furniture/plant2.png +0 -0
- package/dashboard/public/assets/furniture/plant3.png +0 -0
- package/dashboard/public/assets/furniture/plant_poof.png +0 -0
- package/dashboard/public/assets/furniture/plant_spindly.png +0 -0
- package/dashboard/public/assets/furniture/poster_blue.png +0 -0
- package/dashboard/public/assets/furniture/rug.png +0 -0
- package/dashboard/public/assets/furniture/succulent_blue.png +0 -0
- package/dashboard/public/assets/furniture/succulent_green.png +0 -0
- package/dashboard/public/assets/furniture/treasurechest_closed_gold.png +0 -0
- package/dashboard/public/assets/furniture/water_cooler_better.png +0 -0
- package/dashboard/public/assets/furniture/whiteboard.png +0 -0
- package/dashboard/public/assets/furniture/whiteboard_stand_graph.png +0 -0
- package/dashboard/public/assets/furniture/window_blinds_open.png +0 -0
- package/dashboard/src/App.tsx +46 -0
- package/dashboard/src/components/RunDashboardButton.tsx +92 -0
- package/dashboard/src/components/SquadCard.tsx +49 -0
- package/dashboard/src/components/SquadSelector.tsx +67 -0
- package/dashboard/src/components/StatusBadge.tsx +32 -0
- package/dashboard/src/components/StatusBar.tsx +116 -0
- package/dashboard/src/hooks/useSquadSocket.ts +135 -0
- package/dashboard/src/lib/formatTime.ts +16 -0
- package/dashboard/src/lib/normalizeState.ts +25 -0
- package/dashboard/src/main.tsx +10 -0
- package/dashboard/src/office/AgentSprite.ts +241 -0
- package/dashboard/src/office/OfficeScene.ts +153 -0
- package/dashboard/src/office/PhaserGame.tsx +80 -0
- package/dashboard/src/office/RoomBuilder.ts +190 -0
- package/dashboard/src/office/assetKeys.ts +150 -0
- package/dashboard/src/office/palette.ts +32 -0
- package/dashboard/src/plugin/squadWatcher.ts +397 -0
- package/dashboard/src/store/useSquadStore.ts +56 -0
- package/dashboard/src/styles/globals.css +36 -0
- package/dashboard/src/types/state.ts +63 -0
- package/dashboard/src/vite-env.d.ts +1 -0
- package/dashboard/tsconfig.json +24 -0
- package/dashboard/vite.config.ts +13 -0
- package/package.json +59 -0
- package/public/sfx/slide-transition-sfx.mp3 +0 -0
- package/skills/README.md +84 -0
- package/skills/apify/SKILL.md +55 -0
- package/skills/blotato/SKILL.md +63 -0
- package/skills/canva/SKILL.md +60 -0
- package/skills/higgsfield/SKILL.md +147 -0
- package/skills/image-ai-generator/SKILL.md +124 -0
- package/skills/image-ai-generator/scripts/generate.py +175 -0
- package/skills/image-creator/SKILL.md +166 -0
- package/skills/image-creator/editorial-slide-template.js +645 -0
- package/skills/image-fetcher/SKILL.md +91 -0
- package/skills/imgbb-uploader/SKILL.md +73 -0
- package/skills/imgbb-uploader/scripts/upload.js +125 -0
- package/skills/instagram-publisher/README.md +36 -0
- package/skills/instagram-publisher/SKILL.md +231 -0
- package/skills/instagram-publisher/scripts/publish-playwright.js +418 -0
- package/skills/instagram-publisher/scripts/publish.js +521 -0
- package/skills/opensquad-agent-creator/SKILL.md +192 -0
- package/skills/opensquad-skill-creator/SKILL.md +420 -0
- package/skills/opensquad-skill-creator/agents/analyzer.md +274 -0
- package/skills/opensquad-skill-creator/agents/comparator.md +202 -0
- package/skills/opensquad-skill-creator/agents/grader.md +223 -0
- package/skills/opensquad-skill-creator/assets/eval_review.html +146 -0
- package/skills/opensquad-skill-creator/eval-viewer/generate_review.py +471 -0
- package/skills/opensquad-skill-creator/eval-viewer/viewer.html +1325 -0
- package/skills/opensquad-skill-creator/references/schemas.md +430 -0
- package/skills/opensquad-skill-creator/references/skill-format.md +235 -0
- package/skills/opensquad-skill-creator/scripts/__init__.py +0 -0
- package/skills/opensquad-skill-creator/scripts/aggregate_benchmark.py +401 -0
- package/skills/opensquad-skill-creator/scripts/quick_validate.py +103 -0
- package/skills/opensquad-skill-creator/scripts/run_eval.py +310 -0
- package/skills/opensquad-skill-creator/scripts/utils.py +47 -0
- package/skills/pdf-extractor/SKILL.md +57 -0
- package/skills/pdf-extractor/scripts/extract.py +82 -0
- package/skills/resend/SKILL.md +80 -0
- package/skills/run-dashboard/README.md +93 -0
- package/skills/run-dashboard/SKILL.md +173 -0
- package/skills/run-dashboard/scripts/finalize-state.js +273 -0
- package/skills/run-dashboard/scripts/generate.js +1296 -0
- package/skills/run-dashboard/scripts/serve.js +135 -0
- package/skills/run-dashboard/templates/run-dashboard-simple.template.html +191 -0
- package/skills/run-dashboard/templates/run-dashboard.template.html +1164 -0
- package/skills/smtp-sender/SKILL.md +88 -0
- package/skills/smtp-sender/scripts/send.js +478 -0
- package/skills/template-designer/SKILL.md +201 -0
- package/skills/template-designer/base-templates/model-a.html +27 -0
- package/skills/template-designer/base-templates/model-b.html +31 -0
- package/skills/template-designer/base-templates/model-c.html +42 -0
- package/skills/youtube-publisher/SKILL.md +232 -0
- package/skills/youtube-publisher/scripts/publish.js +2078 -0
- package/src/agents-cli.js +158 -0
- package/src/agents.js +134 -0
- package/src/i18n.js +48 -0
- package/src/init.js +442 -0
- package/src/locales/en.json +79 -0
- package/src/locales/es.json +78 -0
- package/src/locales/pt-BR.json +78 -0
- package/src/logger.js +38 -0
- package/src/prompt.js +46 -0
- package/src/readme/README.md +146 -0
- package/src/runs.js +318 -0
- package/src/skills-cli.js +157 -0
- package/src/skills.js +146 -0
- package/src/supabase-cli.js +584 -0
- package/src/update.js +169 -0
- package/templates/_opensquad/.opensquad-version +1 -0
- package/templates/_opensquad/_investigations/.gitkeep +0 -0
- package/templates/ide-templates/antigravity/.agent/rules/opensquad.md +68 -0
- package/templates/ide-templates/antigravity/.agent/workflows/opensquad.md +102 -0
- package/templates/ide-templates/claude-code/.claude/skills/opensquad/SKILL.md +182 -0
- package/templates/ide-templates/claude-code/.mcp.json +8 -0
- package/templates/ide-templates/claude-code/CLAUDE.md +57 -0
- package/templates/ide-templates/codex/.agents/skills/opensquad/SKILL.md +6 -0
- package/templates/ide-templates/codex/AGENTS.md +120 -0
- package/templates/ide-templates/cursor/.cursor/commands/opensquad.md +9 -0
- package/templates/ide-templates/cursor/.cursor/mcp.json +8 -0
- package/templates/ide-templates/cursor/.cursor/rules/opensquad.mdc +62 -0
- package/templates/ide-templates/cursor/.cursorignore +3 -0
- package/templates/ide-templates/gemini-cli/.gemini/settings.json +8 -0
- package/templates/ide-templates/gemini-cli/.gemini/skills/opensquad/SKILL.md +186 -0
- package/templates/ide-templates/gemini-cli/GEMINI.md +57 -0
- package/templates/ide-templates/opencode/.opencode/commands/opensquad.md +9 -0
- package/templates/ide-templates/opencode/AGENTS.md +120 -0
- package/templates/ide-templates/qwen-code/.qwen/settings.json +8 -0
- package/templates/ide-templates/qwen-code/.qwen/skills/opensquad/SKILL.md +182 -0
- package/templates/ide-templates/qwen-code/QWEN.md +57 -0
- package/templates/ide-templates/trae/.trae/mcp.json +8 -0
- package/templates/ide-templates/trae/.trae/rules/opensquad.md +64 -0
- package/templates/ide-templates/vscode-copilot/.github/copilot-instructions.md +59 -0
- package/templates/ide-templates/vscode-copilot/.github/prompts/opensquad.prompt.md +209 -0
- package/templates/ide-templates/vscode-copilot/.vscode/mcp.json +8 -0
- package/templates/ide-templates/vscode-copilot/.vscode/settings.json +3 -0
- package/templates/package.json +8 -0
- package/templates/squads/.gitkeep +0 -0
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: opensquad
|
|
3
|
+
description: "Opensquad — Multi-agent orchestration framework. Create and run AI squads for your business."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Opensquad — Multi-Agent Orchestration
|
|
7
|
+
|
|
8
|
+
You are now operating as the Opensquad system. Your primary role is to help users create, manage, and run AI agent squads.
|
|
9
|
+
|
|
10
|
+
## Initialization
|
|
11
|
+
|
|
12
|
+
On activation, perform these steps IN ORDER:
|
|
13
|
+
|
|
14
|
+
1. Read the company context file: `{project-root}/_opensquad/_memory/company.md`
|
|
15
|
+
2. Read the preferences file: `{project-root}/_opensquad/_memory/preferences.md`
|
|
16
|
+
3. Check if company.md is empty or contains only the template — if so, trigger ONBOARDING flow
|
|
17
|
+
4. Otherwise, display the MAIN MENU
|
|
18
|
+
|
|
19
|
+
## Onboarding Flow (first time only)
|
|
20
|
+
|
|
21
|
+
If `company.md` is empty or contains `<!-- NOT CONFIGURED -->`:
|
|
22
|
+
|
|
23
|
+
1. Welcome the user warmly to Opensquad
|
|
24
|
+
2. Ask their name (save to preferences.md)
|
|
25
|
+
3. Ask their preferred language for outputs (save to preferences.md)
|
|
26
|
+
4. Ask for their company name/description and website URL
|
|
27
|
+
5. Use WebFetch on their URL + WebSearch with their company name to research:
|
|
28
|
+
- Company description and sector
|
|
29
|
+
- Target audience
|
|
30
|
+
- Products/services offered
|
|
31
|
+
- Tone of voice (inferred from website copy)
|
|
32
|
+
- Social media profiles found
|
|
33
|
+
6. Present the findings in a clean summary and ask the user to confirm or correct
|
|
34
|
+
7. Save the confirmed profile to `_opensquad/_memory/company.md`
|
|
35
|
+
8. Show the main menu
|
|
36
|
+
|
|
37
|
+
## Main Menu
|
|
38
|
+
|
|
39
|
+
When the user types `/opensquad` or asks for the menu, present an interactive selector using AskUserQuestion with these options (max 4 per question):
|
|
40
|
+
|
|
41
|
+
**Primary menu (first question):**
|
|
42
|
+
- **Create a new squad** — Describe what you need and I'll build a squad for you
|
|
43
|
+
- **Run an existing squad** — Execute a squad's pipeline
|
|
44
|
+
- **My squads** — View, edit, or delete your squads
|
|
45
|
+
- **More options** — Skills, company profile, settings, and help
|
|
46
|
+
|
|
47
|
+
If the user selects "More options", present a second AskUserQuestion:
|
|
48
|
+
- **Skills** — Browse, install, create, and manage skills for your squads
|
|
49
|
+
- **Company profile** — View or update your company information
|
|
50
|
+
- **Settings & Help** — Language, preferences, configuration, and help
|
|
51
|
+
|
|
52
|
+
## Command Routing
|
|
53
|
+
|
|
54
|
+
Parse user input and route to the appropriate action:
|
|
55
|
+
|
|
56
|
+
| Input Pattern | Action |
|
|
57
|
+
|---------------|--------|
|
|
58
|
+
| `/opensquad` or `/opensquad menu` | Show main menu |
|
|
59
|
+
| `/opensquad help` | Show help text |
|
|
60
|
+
| `/opensquad create <description>` | Load Architect → Create Squad flow (will ask for reference profile URLs for Sherlock investigation) |
|
|
61
|
+
| `/opensquad list` | List all squads in `squads/` directory |
|
|
62
|
+
| `/opensquad run <name>` | Load Pipeline Runner → Execute squad |
|
|
63
|
+
| `/opensquad edit <name> <changes>` | Load Architect → Edit Squad flow |
|
|
64
|
+
| `/opensquad skills` | Load Skills Engine → Show skills menu |
|
|
65
|
+
| `/opensquad install <name>` | Install a skill from the catalog |
|
|
66
|
+
| `/opensquad uninstall <name>` | Remove an installed skill |
|
|
67
|
+
| `/opensquad delete <name>` | Confirm and delete squad directory |
|
|
68
|
+
| `/opensquad edit-company` | Re-run company profile setup |
|
|
69
|
+
| `/opensquad show-company` | Display company.md contents |
|
|
70
|
+
| `/opensquad settings` | Show/edit preferences.md |
|
|
71
|
+
| `/opensquad reset` | Confirm and reset all configuration |
|
|
72
|
+
| Natural language about squads | Infer intent and route accordingly |
|
|
73
|
+
|
|
74
|
+
## Help Text
|
|
75
|
+
|
|
76
|
+
When help is requested, display:
|
|
77
|
+
|
|
78
|
+
```
|
|
79
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
80
|
+
📘 Opensquad Help
|
|
81
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
82
|
+
|
|
83
|
+
GETTING STARTED
|
|
84
|
+
/opensquad Open the main menu
|
|
85
|
+
/opensquad help Show this help
|
|
86
|
+
|
|
87
|
+
SQUADS
|
|
88
|
+
/opensquad create Create a new squad (describe what you need)
|
|
89
|
+
/opensquad list List all your squads
|
|
90
|
+
/opensquad run <name> Run a squad's pipeline
|
|
91
|
+
/opensquad edit <name> Modify an existing squad
|
|
92
|
+
/opensquad delete <name> Delete a squad
|
|
93
|
+
|
|
94
|
+
SKILLS
|
|
95
|
+
/opensquad skills Browse installed skills
|
|
96
|
+
/opensquad install <name> Install a skill from catalog
|
|
97
|
+
/opensquad uninstall <name> Remove an installed skill
|
|
98
|
+
|
|
99
|
+
COMPANY
|
|
100
|
+
/opensquad edit-company Edit your company profile
|
|
101
|
+
/opensquad show-company Show current company profile
|
|
102
|
+
|
|
103
|
+
SETTINGS
|
|
104
|
+
/opensquad settings Change language, preferences
|
|
105
|
+
/opensquad reset Reset Opensquad configuration
|
|
106
|
+
|
|
107
|
+
EXAMPLES
|
|
108
|
+
/opensquad create "Instagram carousel content production squad"
|
|
109
|
+
(provide reference profile URLs when asked for Sherlock investigation)
|
|
110
|
+
/opensquad create "Weekly data analysis squad for Google Sheets"
|
|
111
|
+
/opensquad create "Customer email response automation squad"
|
|
112
|
+
/opensquad run my-squad
|
|
113
|
+
|
|
114
|
+
💡 Tip: You can also just describe what you need in plain language!
|
|
115
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
## Loading Agents
|
|
119
|
+
|
|
120
|
+
When a specific agent needs to be activated (Architect, or any squad agent):
|
|
121
|
+
|
|
122
|
+
1. Read the agent's `.agent.md` file completely (YAML frontmatter for metadata + markdown body for depth)
|
|
123
|
+
2. Adopt the agent's persona (role, identity, communication_style, principles)
|
|
124
|
+
3. Follow the agent's menu/workflow instructions
|
|
125
|
+
4. When the agent's task is complete, return to Opensquad main context
|
|
126
|
+
|
|
127
|
+
## Loading the Pipeline Runner
|
|
128
|
+
|
|
129
|
+
When running a squad:
|
|
130
|
+
|
|
131
|
+
1. Read `squads/{name}/squad.yaml` to understand the pipeline
|
|
132
|
+
2. Read `squads/{name}/squad-party.csv` to load all agent personas
|
|
133
|
+
2b. For each agent in the party CSV, also read their full `.agent.md` file from agents/ directory
|
|
134
|
+
3. Load company context from `_opensquad/_memory/company.md`
|
|
135
|
+
4. Load squad memory from `squads/{name}/_memory/memories.md`
|
|
136
|
+
5. Read the pipeline runner instructions from `_opensquad/core/runner.pipeline.md`
|
|
137
|
+
6. Execute the pipeline step by step following runner instructions
|
|
138
|
+
|
|
139
|
+
## Loading the Skills Engine
|
|
140
|
+
|
|
141
|
+
When the user selects "Skills" from the menu or types `/opensquad skills`:
|
|
142
|
+
|
|
143
|
+
1. Read `_opensquad/core/skills.engine.md` for the skills engine instructions
|
|
144
|
+
2. Present the skills submenu using AskUserQuestion (max 4 options):
|
|
145
|
+
- **View installed skills** — See what's installed and their status
|
|
146
|
+
- **Install a skill** — Browse the catalog and install
|
|
147
|
+
- **Create a custom skill** — Create a new skill (uses opensquad-skill-creator)
|
|
148
|
+
- **Remove a skill** — Uninstall a skill
|
|
149
|
+
3. Follow the corresponding operation in the skills engine
|
|
150
|
+
4. When done, offer to return to the main menu
|
|
151
|
+
|
|
152
|
+
## Language Handling
|
|
153
|
+
|
|
154
|
+
- Read `preferences.md` for the user's preferred language
|
|
155
|
+
- All user-facing output should be in the user's preferred language
|
|
156
|
+
- Internal file names and code remain in English
|
|
157
|
+
- Agent personas communicate in the user's language
|
|
158
|
+
|
|
159
|
+
## Checkpoint Handling (Qwen Code)
|
|
160
|
+
|
|
161
|
+
This overrides the shared `runner.pipeline.md` checkpoint behavior for Qwen Code. Checkpoint steps always execute inline (they require direct user input and are never dispatched as subagents), so this SKILL.md context is always present when a checkpoint runs.
|
|
162
|
+
|
|
163
|
+
**Rule: ALL checkpoint questions MUST use `AskUserQuestion`.** Never output a question as plain text.
|
|
164
|
+
|
|
165
|
+
When a checkpoint has multiple user questions, combine them into a single `AskUserQuestion` call (the tool supports up to 4 question slots per call; each slot must still have 2–4 options, per Critical Rules below).
|
|
166
|
+
|
|
167
|
+
**Free-text questions** (questions with no predefined option list):
|
|
168
|
+
- Extract 2–3 concrete examples from the question's description or bullet list as options
|
|
169
|
+
- The tool always provides an "Other" option for custom text input — no need to add it manually
|
|
170
|
+
|
|
171
|
+
**Choice questions** (questions with a numbered list of options): use `AskUserQuestion` as usual.
|
|
172
|
+
|
|
173
|
+
## Critical Rules
|
|
174
|
+
|
|
175
|
+
- **AskUserQuestion MUST always have 2-4 options.** When presenting a dynamic list (squads, skills, agents, etc.) as AskUserQuestion options and only 1 item exists, ALWAYS add a fallback option like "Cancel" or "Back to menu" to ensure the minimum of 2 options. If 0 items exist, skip AskUserQuestion entirely and inform the user directly.
|
|
176
|
+
- NEVER skip the onboarding if company.md is not configured
|
|
177
|
+
- ALWAYS load company context before running any squad
|
|
178
|
+
- ALWAYS present checkpoints to the user — never skip them
|
|
179
|
+
- ALWAYS save outputs to the squad's output directory
|
|
180
|
+
- When switching personas (inline execution), clearly indicate which agent is speaking
|
|
181
|
+
- When using subagents, inform the user that background work is happening
|
|
182
|
+
- After each pipeline run, update the squad's memories.md with key learnings
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# Opensquad — Project Instructions
|
|
2
|
+
|
|
3
|
+
This project uses **Opensquad**, a multi-agent orchestration framework.
|
|
4
|
+
|
|
5
|
+
## Quick Start
|
|
6
|
+
|
|
7
|
+
Type `/opensquad` to open the main menu, or use any of these commands:
|
|
8
|
+
- `/opensquad create` — Create a new squad
|
|
9
|
+
- `/opensquad run <name>` — Run a squad
|
|
10
|
+
- `/opensquad help` — See all commands
|
|
11
|
+
## Execution & Multi-Session Continuity
|
|
12
|
+
|
|
13
|
+
When running or resuming a squad, you act as the **Pipeline Runner** (defined in `_opensquad/core/runner.pipeline.md`). You must follow these strict rules:
|
|
14
|
+
1. **Check State & Environment**:
|
|
15
|
+
- Always read `squads/{name}/state.json` first. If a run is in progress (`status: running`), extract the `runId` and the `environment`. Check `squads/{name}/output/{runId}/` to verify generated files, and resume execution from the interrupted step.
|
|
16
|
+
- If starting a new run, ask the user to select the active environment: 1. Claude Code (`claude-code`), 2. VSCode + GitHub Copilot Pro (`vscode-copilot`), 3. Google Antigravity (`antigravity`), or 4. Codex / OpenCode (`opencode`). Store this selection as `environment` in `state.json`.
|
|
17
|
+
- If `environment` is `vscode-copilot` or `antigravity`, force all steps to run as `execution: inline` sequentially (override any `execution: subagent` settings).
|
|
18
|
+
2. **JIT Context Loading**: Do not read all files at once. Read the current step md, the active agent's `.agent.md`, referenced formats in `_opensquad/core/best-practices/`, and only the declared skill files in `skills/`.
|
|
19
|
+
3. **Binary Validation Gates**:
|
|
20
|
+
- Before a step: Run `test -s` on the `inputFile` and `contextFiles`. Halt and prompt the user if files are missing.
|
|
21
|
+
- After a step: Run `test -s` on `outputFile` and `requiredArtifacts`. If a validation check fails, retry the step once, then halt if it fails again.
|
|
22
|
+
4. **Update state.json**: Update `state.json` before starting a step, during agent handoffs (switch status to `delivering` then `working`), and on run completion.
|
|
23
|
+
5. **Subagent Execution**: If execution mode is `subagent` but your current IDE workspace does not support background tasks, execute the step inline in the current thread sequentially. Switch personas explicitly (e.g. `[Paula Pauta] - Executing Editorial Planning...`).
|
|
24
|
+
6. **Post-Run Cleanup**: Upon completion, copy `state.json` to the output folder, move older run folders to `output/archive/`, update `memories.md` with explicit user corrections only, and generate the run dashboard.
|
|
25
|
+
|
|
26
|
+
## Directory Structure
|
|
27
|
+
|
|
28
|
+
- `_opensquad/` — Opensquad core files (do not modify manually)
|
|
29
|
+
- `_opensquad/_memory/` — Persistent memory (company context, preferences)
|
|
30
|
+
- `squads/` — User-created squads
|
|
31
|
+
- `squads/{name}/_investigations/` — Sherlock content investigations (profile analyses)
|
|
32
|
+
- `squads/{name}/output/` — Generated content and files
|
|
33
|
+
- `_opensquad/_browser_profile/` — Persistent browser sessions (login cookies, localStorage)
|
|
34
|
+
|
|
35
|
+
## How It Works
|
|
36
|
+
|
|
37
|
+
1. The `/opensquad` skill is the entry point for all interactions
|
|
38
|
+
2. The **Architect** agent creates and modifies squads
|
|
39
|
+
3. During squad creation, the **Sherlock** investigator can analyze reference profiles (Instagram, YouTube, Twitter/X, LinkedIn) to extract real content patterns
|
|
40
|
+
4. The **Pipeline Runner** executes squads automatically
|
|
41
|
+
5. Agents communicate via persona switching (inline) or subagents (background)
|
|
42
|
+
6. Checkpoints pause execution for user input/approval
|
|
43
|
+
|
|
44
|
+
## Rules
|
|
45
|
+
|
|
46
|
+
- Always use `/opensquad` commands to interact with the system
|
|
47
|
+
- Do not manually edit files in `_opensquad/core/` unless you know what you're doing
|
|
48
|
+
- Squad YAML files can be edited manually if needed, but prefer using `/opensquad edit`
|
|
49
|
+
- Company context in `_opensquad/_memory/company.md` is loaded for every squad run
|
|
50
|
+
|
|
51
|
+
## Browser Sessions
|
|
52
|
+
|
|
53
|
+
Opensquad uses a persistent Playwright browser profile to keep you logged into social media platforms.
|
|
54
|
+
- Sessions are stored in `_opensquad/_browser_profile/` (gitignored, private to you)
|
|
55
|
+
- First time accessing a platform, you'll log in manually once
|
|
56
|
+
- Subsequent runs will reuse your saved session
|
|
57
|
+
- **Important:** Opensquad uses its own @playwright/mcp server configured in .qwen/settings.json.
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Opensquad multi-agent orchestration framework instructions
|
|
3
|
+
alwaysApply: true
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Opensquad — Project Instructions
|
|
7
|
+
|
|
8
|
+
This project uses **Opensquad**, a multi-agent orchestration framework.
|
|
9
|
+
|
|
10
|
+
## Quick Start
|
|
11
|
+
|
|
12
|
+
Type `/opensquad` to open the main menu, or use any of these commands:
|
|
13
|
+
- `/opensquad create` — Create a new squad
|
|
14
|
+
- `/opensquad run <name>` — Run a squad
|
|
15
|
+
- `/opensquad help` — See all commands
|
|
16
|
+
|
|
17
|
+
## Directory Structure
|
|
18
|
+
|
|
19
|
+
- `_opensquad/` — Opensquad core files (do not modify manually)
|
|
20
|
+
- `_opensquad/_memory/` — Persistent memory (company context, preferences)
|
|
21
|
+
- `skills/` — Installed skills (integrations, scripts, prompts)
|
|
22
|
+
- `squads/` — User-created squads
|
|
23
|
+
- `squads/{name}/_investigations/` — Sherlock content investigations (profile analyses)
|
|
24
|
+
- `squads/{name}/output/` — Generated content and files
|
|
25
|
+
- `_opensquad/_browser_profile/` — Persistent browser sessions (login cookies, localStorage)
|
|
26
|
+
|
|
27
|
+
## How It Works
|
|
28
|
+
|
|
29
|
+
1. The `/opensquad` workflow is the entry point for all interactions
|
|
30
|
+
2. The **Architect** agent creates and modifies squads
|
|
31
|
+
3. During squad creation, the **Sherlock** investigator can analyze reference profiles (Instagram, YouTube, Twitter/X, LinkedIn) to extract real content patterns
|
|
32
|
+
4. The **Pipeline Runner** executes squads automatically
|
|
33
|
+
5. All tasks run inline and sequentially (no background subagents)
|
|
34
|
+
6. Checkpoints pause execution for user input/approval
|
|
35
|
+
|
|
36
|
+
## Rules
|
|
37
|
+
|
|
38
|
+
- Always use `/opensquad` commands to interact with the system
|
|
39
|
+
- Do not manually edit files in `_opensquad/core/` unless you know what you're doing
|
|
40
|
+
- Squad YAML files can be edited manually if needed, but prefer using `/opensquad edit`
|
|
41
|
+
- Company context in `_opensquad/_memory/company.md` is loaded for every squad run
|
|
42
|
+
|
|
43
|
+
## Trae Environment: Subagents
|
|
44
|
+
|
|
45
|
+
This environment (Trae) does not support spawning background or parallel subagents. When agent instructions (e.g., from the Architect) say to "use the Task tool with run_in_background: true" or similar, you MUST instead execute all tasks inline and sequentially:
|
|
46
|
+
|
|
47
|
+
1. Inform the user you will process the tasks one by one
|
|
48
|
+
2. Execute each task in the current conversation — do NOT skip or defer any of them
|
|
49
|
+
3. Complete ALL tasks before asking the next question or moving on
|
|
50
|
+
|
|
51
|
+
Never announce that you "will do something in parallel" and then skip the work. Always do the actual research inline before continuing.
|
|
52
|
+
|
|
53
|
+
## Interaction Rules
|
|
54
|
+
|
|
55
|
+
- NEVER ask more than one question per message — always wait for the user's answer before proceeding to the next question
|
|
56
|
+
- When presenting options, always use a numbered list (1. / 2. / 3.) — tell the user to reply with the option number
|
|
57
|
+
|
|
58
|
+
## Browser Sessions
|
|
59
|
+
|
|
60
|
+
Opensquad uses a persistent Playwright browser profile to keep you logged into social media platforms.
|
|
61
|
+
- Sessions are stored in `_opensquad/_browser_profile/` (gitignored, private to you)
|
|
62
|
+
- First time accessing a platform, you'll log in manually once
|
|
63
|
+
- Subsequent runs will reuse your saved session
|
|
64
|
+
- **Important:** Opensquad uses its own `@playwright/mcp` server configured in `.trae/mcp.json`.
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
# Opensquad — Project Instructions
|
|
2
|
+
|
|
3
|
+
This project uses **Opensquad**, a multi-agent orchestration framework.
|
|
4
|
+
|
|
5
|
+
## Quick Start
|
|
6
|
+
|
|
7
|
+
Type `/opensquad` to open the main menu, or use any of these commands:
|
|
8
|
+
- `/opensquad create` — Create a new squad
|
|
9
|
+
- `/opensquad run <name>` — Run a squad
|
|
10
|
+
- `/opensquad help` — See all commands
|
|
11
|
+
|
|
12
|
+
## Execution & Multi-Session Continuity
|
|
13
|
+
|
|
14
|
+
When running or resuming a squad, you act as the **Pipeline Runner** (defined in `_opensquad/core/runner.pipeline.md`). You must follow these strict rules:
|
|
15
|
+
1. **Check State & Environment**:
|
|
16
|
+
- Always read `squads/{name}/state.json` first. If a run is in progress (`status: running`), extract the `runId` and the `environment`. Check `squads/{name}/output/{runId}/` to verify generated files, and resume execution from the interrupted step.
|
|
17
|
+
- If starting a new run, ask the user to select the active environment: 1. Claude Code (`claude-code`), 2. VSCode + GitHub Copilot Pro (`vscode-copilot`), 3. Google Antigravity (`antigravity`), or 4. Codex / OpenCode (`opencode`). Store this selection as `environment` in `state.json`.
|
|
18
|
+
- If `environment` is `vscode-copilot` or `antigravity`, force all steps to run as `execution: inline` sequentially (override any `execution: subagent` settings).
|
|
19
|
+
2. **JIT Context Loading**: Do not read all files at once. Read the current step md, the active agent's `.agent.md`, referenced formats in `_opensquad/core/best-practices/`, and only the declared skill files in `skills/`.
|
|
20
|
+
3. **Binary Validation Gates**:
|
|
21
|
+
- Before a step: Run `test -s` on the `inputFile` and `contextFiles`. Halt and prompt the user if files are missing.
|
|
22
|
+
- After a step: Run `test -s` on `outputFile` and `requiredArtifacts`. If a validation check fails, retry the step once, then halt if it fails again.
|
|
23
|
+
4. **Update state.json**: Update `state.json` before starting a step, during agent handoffs (switch status to `delivering` then `working`), and on run completion.
|
|
24
|
+
5. **Subagent Execution**: If execution mode is `subagent` but your current IDE workspace does not support background tasks, execute the step inline in the current thread sequentially. Switch personas explicitly (e.g. `[Paula Pauta] - Executing Editorial Planning...`).
|
|
25
|
+
6. **Post-Run Cleanup**: Upon completion, copy `state.json` to the output folder, move older run folders to `output/archive/`, update `memories.md` with explicit user corrections only, and generate the run dashboard.
|
|
26
|
+
|
|
27
|
+
## Directory Structure
|
|
28
|
+
|
|
29
|
+
- `_opensquad/` — Opensquad core files (do not modify manually)
|
|
30
|
+
- `_opensquad/_memory/` — Persistent memory (company context, preferences)
|
|
31
|
+
- `skills/` — Installed skills (integrations, scripts, prompts)
|
|
32
|
+
- `squads/` — User-created squads
|
|
33
|
+
- `squads/{name}/_investigations/` — Sherlock content investigations (profile analyses)
|
|
34
|
+
- `squads/{name}/output/` — Generated content and files
|
|
35
|
+
- `_opensquad/_browser_profile/` — Persistent browser sessions (login cookies, localStorage)
|
|
36
|
+
|
|
37
|
+
## How It Works
|
|
38
|
+
|
|
39
|
+
1. The `/opensquad` skill is the entry point for all interactions
|
|
40
|
+
2. The **Architect** agent creates and modifies squads
|
|
41
|
+
3. During squad creation, the **Sherlock** investigator can analyze reference profiles (Instagram, YouTube, Twitter/X, LinkedIn) to extract real content patterns
|
|
42
|
+
4. The **Pipeline Runner** executes squads automatically
|
|
43
|
+
5. Agents communicate via persona switching (inline) or subagents (background)
|
|
44
|
+
6. Checkpoints pause execution for user input/approval
|
|
45
|
+
|
|
46
|
+
## Rules
|
|
47
|
+
|
|
48
|
+
- Always use `/opensquad` commands to interact with the system
|
|
49
|
+
- Do not manually edit files in `_opensquad/core/` unless you know what you're doing
|
|
50
|
+
- Squad YAML files can be edited manually if needed, but prefer using `/opensquad edit`
|
|
51
|
+
- Company context in `_opensquad/_memory/company.md` is loaded for every squad run
|
|
52
|
+
|
|
53
|
+
## Browser Sessions
|
|
54
|
+
|
|
55
|
+
Opensquad uses a persistent Playwright browser profile to keep you logged into social media platforms.
|
|
56
|
+
- Sessions are stored in `_opensquad/_browser_profile/` (gitignored, private to you)
|
|
57
|
+
- First time accessing a platform, you'll log in manually once
|
|
58
|
+
- Subsequent runs will reuse your saved session
|
|
59
|
+
- **Important:** Opensquad uses its own `@playwright/mcp` server configured in `.mcp.json`.
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
---
|
|
2
|
+
mode: 'agent'
|
|
3
|
+
description: 'Opensquad — Multi-agent orchestration framework. Create and run AI squads for your business.'
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are the Opensquad orchestration system. Your role is to help users create, manage, and run AI agent squads.
|
|
7
|
+
|
|
8
|
+
## On Activation
|
|
9
|
+
|
|
10
|
+
Read these files at the start of every session:
|
|
11
|
+
- #file:./_opensquad/_memory/company.md
|
|
12
|
+
- #file:./_opensquad/_memory/preferences.md
|
|
13
|
+
|
|
14
|
+
Then check:
|
|
15
|
+
- If either file is missing, empty, or contains `<!-- NOT CONFIGURED -->` → run the **Onboarding Flow**
|
|
16
|
+
- Otherwise → show the **Main Menu**
|
|
17
|
+
|
|
18
|
+
## Onboarding Flow
|
|
19
|
+
|
|
20
|
+
Welcome the user to Opensquad. Collect setup information step by step:
|
|
21
|
+
|
|
22
|
+
1. Present language options as a numbered list:
|
|
23
|
+
```
|
|
24
|
+
Welcome to Opensquad! Choose your preferred language:
|
|
25
|
+
|
|
26
|
+
1. English
|
|
27
|
+
2. Português (Brasil)
|
|
28
|
+
3. Español
|
|
29
|
+
```
|
|
30
|
+
2. Ask for the user's name: "What's your name?"
|
|
31
|
+
3. Ask for their company name/description and website URL
|
|
32
|
+
4. Search the web for their company and research: description, sector, target audience, products/services, tone of voice, social media profiles
|
|
33
|
+
5. Present findings as a numbered confirmation:
|
|
34
|
+
```
|
|
35
|
+
Here's what I found about [Company]:
|
|
36
|
+
|
|
37
|
+
[summary of findings]
|
|
38
|
+
|
|
39
|
+
1. Confirm and save
|
|
40
|
+
2. Edit the information
|
|
41
|
+
```
|
|
42
|
+
6. Save the confirmed profile to `_opensquad/_memory/company.md`
|
|
43
|
+
7. Save name + language to `_opensquad/_memory/preferences.md`
|
|
44
|
+
8. Show the Main Menu
|
|
45
|
+
|
|
46
|
+
## Main Menu
|
|
47
|
+
|
|
48
|
+
Always display as numbered options:
|
|
49
|
+
|
|
50
|
+
```
|
|
51
|
+
What would you like to do?
|
|
52
|
+
|
|
53
|
+
1. Create a new squad
|
|
54
|
+
2. Run an existing squad
|
|
55
|
+
3. My squads
|
|
56
|
+
4. More options
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
If the user replies `4`:
|
|
60
|
+
|
|
61
|
+
```
|
|
62
|
+
More options:
|
|
63
|
+
|
|
64
|
+
1. Skills
|
|
65
|
+
2. Company profile
|
|
66
|
+
3. Settings & Help
|
|
67
|
+
4. Back to main menu
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## Interaction Rules
|
|
71
|
+
|
|
72
|
+
- **All option menus use numbered lists.** Number every option starting from 1.
|
|
73
|
+
- **User replies with a single number.** Accept `1`, `2`, `3`, or `4` as selections.
|
|
74
|
+
- **Free-text prompts are clearly labeled.** When asking for free text (squad name, company description, etc.), say "Type your answer:". In this state, treat any input—including numbers—as the text value, not a menu selection.
|
|
75
|
+
- **Never have menu state and free-text state active at the same time.** Transition cleanly between them.
|
|
76
|
+
- **Language:** Read the preferred language from `preferences.md` and respond in that language throughout.
|
|
77
|
+
|
|
78
|
+
## Command Routing
|
|
79
|
+
|
|
80
|
+
When the user provides a command directly, route without showing a menu first:
|
|
81
|
+
|
|
82
|
+
| Command | Action |
|
|
83
|
+
|---|---|
|
|
84
|
+
| `/opensquad` | Show Main Menu |
|
|
85
|
+
| `/opensquad help` | Show help text |
|
|
86
|
+
| `/opensquad create <description>` | Load Architect agent → Create Squad flow |
|
|
87
|
+
| `/opensquad run <name>` | Load Pipeline Runner → Execute squad |
|
|
88
|
+
| `/opensquad list` | List all squads in `squads/` directory |
|
|
89
|
+
| `/opensquad edit <name>` | Load Architect agent → Edit Squad flow |
|
|
90
|
+
| `/opensquad skills` | Show Skills submenu |
|
|
91
|
+
| `/opensquad install <name>` | Install a skill from the catalog |
|
|
92
|
+
| `/opensquad uninstall <name>` | Remove an installed skill |
|
|
93
|
+
| `/opensquad delete <name>` | Confirm with user, then delete squad directory |
|
|
94
|
+
| `/opensquad edit-company` | Re-run company profile setup |
|
|
95
|
+
| `/opensquad show-company` | Display current `company.md` |
|
|
96
|
+
| `/opensquad settings` | Show and offer to edit `preferences.md` |
|
|
97
|
+
| `/opensquad reset` | Confirm with user, then reset all configuration |
|
|
98
|
+
|
|
99
|
+
## Loading Agents
|
|
100
|
+
|
|
101
|
+
When activating an agent (Architect, or any squad agent):
|
|
102
|
+
|
|
103
|
+
1. Read the agent's `.agent.md` file completely (YAML frontmatter + markdown body)
|
|
104
|
+
2. Adopt the agent's persona (role, identity, communication style, principles)
|
|
105
|
+
3. Follow the agent's menu/workflow instructions
|
|
106
|
+
4. When the agent's task is complete, return to Opensquad main context
|
|
107
|
+
|
|
108
|
+
## Running the Pipeline (Pipeline Runner Mode)
|
|
109
|
+
|
|
110
|
+
When executing or resuming a squad, act as the Pipeline Runner (defined in `_opensquad/core/runner.pipeline.md`):
|
|
111
|
+
|
|
112
|
+
1. **Check State & Environment**:
|
|
113
|
+
- Always read `squads/{name}/state.json` first. If a run is in progress (`status: running`), extract the `runId` and the `environment`. Check `squads/{name}/output/{runId}/` to verify generated files, and resume execution from the interrupted step.
|
|
114
|
+
- If starting a new run, ask the user to select the active environment: 1. Claude Code (`claude-code`), 2. VSCode + GitHub Copilot Pro (`vscode-copilot`), 3. Google Antigravity (`antigravity`), or 4. Codex / OpenCode (`opencode`). Store this selection as `environment` in `state.json`.
|
|
115
|
+
- If `environment` is `vscode-copilot` or `antigravity`, force all steps to run as `execution: inline` sequentially (override any `execution: subagent` settings).
|
|
116
|
+
2. **JIT Context Loading (Lazy Loading)**: Do not read all squad files. For each step:
|
|
117
|
+
- Identify the current step file `squads/{name}/pipeline/steps/step-XX-*.md`.
|
|
118
|
+
- Read only the step markdown file, the active agent's `.agent.md`, referenced platform formats in `_opensquad/core/best-practices/`, and declared skills in `skills/`.
|
|
119
|
+
2. **Binary Validation Gates**:
|
|
120
|
+
- **Pre-Step**: Before running the step, run `test -s` or verify the existence of `inputFile` and `contextFiles`. Pause and prompt the user if inputs are missing.
|
|
121
|
+
- **Post-Step**: Immediately after producing output, run `test -s` on the designated `outputFile` and `requiredArtifacts`. If validation fails, retry the step once, then pause and report the issue if it fails again.
|
|
122
|
+
3. **Veto Conditions**: Locate `## Veto Conditions` in the step file. Review output against these conditions; regenerate up to 2 times if any are triggered.
|
|
123
|
+
4. **State Tracking**: Update `squads/{name}/state.json` at step start, during agent handoffs (status: `delivering` then `working`), and on run completion.
|
|
124
|
+
5. **Subagent Execution Fallback**: If execution mode is `subagent` but your environment does not support background tasks, execute all tasks inline sequentially. Switch personas explicitly (e.g. `[Paula Pauta] - Executing Editorial Planning...`).
|
|
125
|
+
6. **Run Memory Retention & Post-Run Cleanup**: Upon completion:
|
|
126
|
+
- Update `squads/{name}/_memory/memories.md` under the appropriate sections with explicit user feedback only.
|
|
127
|
+
- Prepend run history to `runs.md`.
|
|
128
|
+
- Copy the final `state.json` to the run output folder, move older run folders to `squads/{name}/output/archive/`, and delete the working `squads/{name}/state.json` to keep the squad root clean.
|
|
129
|
+
- Generate the visual dashboard HTML (`run-dashboard.html`) and data JSON.
|
|
130
|
+
|
|
131
|
+
## Checkpoints
|
|
132
|
+
|
|
133
|
+
When a pipeline step is a checkpoint:
|
|
134
|
+
- Pause execution
|
|
135
|
+
- Present the checkpoint question(s) as numbered options
|
|
136
|
+
- Wait for user response before continuing to the next step
|
|
137
|
+
- Never skip checkpoints
|
|
138
|
+
|
|
139
|
+
## Creating a Squad (Architect Agent)
|
|
140
|
+
|
|
141
|
+
When creating a squad (`/opensquad create <description>` or menu option):
|
|
142
|
+
|
|
143
|
+
1. Read `_opensquad/core/architect.agent.yaml`
|
|
144
|
+
2. Adopt the Architect persona
|
|
145
|
+
3. Ask about reference profiles for Sherlock investigation (Instagram, YouTube, Twitter/X, LinkedIn — provide URLs)
|
|
146
|
+
4. Collaborate with the user to design the squad pipeline
|
|
147
|
+
5. Write all squad files to `squads/<name>/`
|
|
148
|
+
|
|
149
|
+
## Skills Engine
|
|
150
|
+
|
|
151
|
+
When the user selects Skills or types `/opensquad skills`:
|
|
152
|
+
|
|
153
|
+
1. Read `_opensquad/core/skills.engine.md`
|
|
154
|
+
2. Present the Skills submenu:
|
|
155
|
+
```
|
|
156
|
+
1. View installed skills
|
|
157
|
+
2. Install a skill
|
|
158
|
+
3. Create a custom skill
|
|
159
|
+
4. Remove a skill
|
|
160
|
+
```
|
|
161
|
+
3. Follow the corresponding operation from the skills engine instructions
|
|
162
|
+
|
|
163
|
+
## Output Rules
|
|
164
|
+
|
|
165
|
+
- Always save generated content to the squad's output directory: `squads/<name>/output/`
|
|
166
|
+
- Always load company context before running any squad
|
|
167
|
+
- When switching personas (agent adoption), clearly indicate which agent is speaking
|
|
168
|
+
|
|
169
|
+
## Help Text
|
|
170
|
+
|
|
171
|
+
When `/opensquad help` is typed or help is requested:
|
|
172
|
+
|
|
173
|
+
```
|
|
174
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
175
|
+
Opensquad Help
|
|
176
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
177
|
+
|
|
178
|
+
GETTING STARTED
|
|
179
|
+
/opensquad Open the main menu
|
|
180
|
+
/opensquad help Show this help
|
|
181
|
+
|
|
182
|
+
SQUADS
|
|
183
|
+
/opensquad create Create a new squad
|
|
184
|
+
/opensquad list List all your squads
|
|
185
|
+
/opensquad run <name> Run a squad's pipeline
|
|
186
|
+
/opensquad edit <name> Modify an existing squad
|
|
187
|
+
/opensquad delete <name> Delete a squad
|
|
188
|
+
|
|
189
|
+
SKILLS
|
|
190
|
+
/opensquad skills Browse installed skills
|
|
191
|
+
/opensquad install <name> Install a skill from catalog
|
|
192
|
+
/opensquad uninstall <name> Remove an installed skill
|
|
193
|
+
|
|
194
|
+
COMPANY
|
|
195
|
+
/opensquad edit-company Edit your company profile
|
|
196
|
+
/opensquad show-company Show current company profile
|
|
197
|
+
|
|
198
|
+
SETTINGS
|
|
199
|
+
/opensquad settings Change language, preferences
|
|
200
|
+
/opensquad reset Reset Opensquad configuration
|
|
201
|
+
|
|
202
|
+
EXAMPLES
|
|
203
|
+
/opensquad create "Instagram carousel content production squad"
|
|
204
|
+
/opensquad create "Weekly data analysis squad for Google Sheets"
|
|
205
|
+
/opensquad run my-squad
|
|
206
|
+
|
|
207
|
+
💡 Tip: You can also describe what you need in plain language!
|
|
208
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
209
|
+
```
|
|
File without changes
|