bps-kit 1.0.7 → 1.0.9
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/CHANGELOG.md +39 -0
- package/README.md +42 -33
- package/bin/cli.js +27 -16
- package/package.json +1 -1
- package/templates/VAULT_INDEX.md +2 -2
- package/templates/agents-template/rules/GEMINI.md +4 -4
- package/templates/agents-template/scripts/convert_to_vscode.js +87 -0
- package/templates/skills_basic/behavioral-modes/SKILL.md +247 -0
- package/templates/skills_basic/brainstorming/SKILL.md +232 -0
- package/templates/skills_basic/clean-code/SKILL.md +94 -0
- package/templates/skills_basic/concise-planning/SKILL.md +68 -0
- package/templates/skills_basic/executing-plans/SKILL.md +82 -0
- package/templates/skills_basic/git-pushing/SKILL.md +36 -0
- package/templates/skills_basic/git-pushing/scripts/smart_commit.sh +19 -0
- package/templates/skills_basic/lint-and-validate/SKILL.md +50 -0
- package/templates/skills_basic/lint-and-validate/scripts/lint_runner.py +172 -0
- package/templates/skills_basic/lint-and-validate/scripts/type_coverage.py +173 -0
- package/templates/skills_basic/plan-writing/SKILL.md +154 -0
- package/templates/skills_basic/systematic-debugging/CREATION-LOG.md +119 -0
- package/templates/skills_basic/systematic-debugging/SKILL.md +299 -0
- package/templates/skills_basic/systematic-debugging/condition-based-waiting-example.ts +158 -0
- package/templates/skills_basic/systematic-debugging/condition-based-waiting.md +115 -0
- package/templates/skills_basic/systematic-debugging/defense-in-depth.md +122 -0
- package/templates/skills_basic/systematic-debugging/find-polluter.sh +63 -0
- package/templates/skills_basic/systematic-debugging/root-cause-tracing.md +169 -0
- package/templates/skills_basic/systematic-debugging/test-academic.md +14 -0
- package/templates/skills_basic/systematic-debugging/test-pressure-1.md +58 -0
- package/templates/skills_basic/systematic-debugging/test-pressure-2.md +68 -0
- package/templates/skills_basic/systematic-debugging/test-pressure-3.md +69 -0
- package/templates/skills_basic/verification-before-completion/SKILL.md +145 -0
- package/templates/skills_basic/vulnerability-scanner/SKILL.md +281 -0
- package/templates/skills_basic/vulnerability-scanner/checklists.md +121 -0
- package/templates/skills_basic/vulnerability-scanner/scripts/security_scan.py +458 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
Todas as mudanças notáveis neste projeto serão documentadas neste arquivo.
|
|
4
|
+
|
|
5
|
+
O formato é baseado no [Keep a Changelog](https://keepachangelog.com/pt-BR/1.0.0/),
|
|
6
|
+
e este projeto adere ao [Versionamento Semântico](https://semver.org/lang/pt-BR/).
|
|
7
|
+
|
|
8
|
+
## [1.0.9] - 2026-03-08
|
|
9
|
+
### Modificado
|
|
10
|
+
- Refatoração visual completa do `README.md` com adição de emblemas (badges) e seções formatadas.
|
|
11
|
+
- Remoção de menções à ferramentas de terceiros no README, com foco centralizado na engine do Antigravity e na integração oficial do VS Code.
|
|
12
|
+
- Inclusão oficial garantida de `node_modules/` no `.gitignore` para limpezas.
|
|
13
|
+
- Finalização da auditoria do artefato de checkup para a infraestrutura do Copilot.
|
|
14
|
+
|
|
15
|
+
## [1.0.8] - 2026-03-08
|
|
16
|
+
### Adicionado
|
|
17
|
+
- **Flag `--basic`:** Incluída opção de economia extrema de tokens, importando apenas 11 skills do core cognitivo e analítico da IA, reduzindo o overflow da janela de contexto.
|
|
18
|
+
- **Flag `--vscode`:** Grande atualização de arquitetura. O CLI agora suporta a conversão "on-the-fly" da arquitetura `.agents` tradicional para a arquitetura `.github` requerida nativamente pelo **GitHub Copilot** no VS Code.
|
|
19
|
+
|
|
20
|
+
## [1.0.7] - 2026-03-08
|
|
21
|
+
### Corrigido
|
|
22
|
+
- Ajuste e inclusão das especificações de Licença (MIT) diretamente na documentação primária do repositório público.
|
|
23
|
+
|
|
24
|
+
## [1.0.6] - 2026-03-08
|
|
25
|
+
### Ajustado
|
|
26
|
+
- Remoção pesada das referências "fantasmas" dos paths do Antigravity nos templates do `GEMINI.md` e do `VAULT_INDEX.md`, para garantir independência de sistema para os usuários finais.
|
|
27
|
+
|
|
28
|
+
## [1.0.1] até [1.0.5] - 2026-03-08
|
|
29
|
+
### Corrigido
|
|
30
|
+
- Séries de patches resolutos para contornar o mecanismo de segurança rígido do NPM, que ignorava pastas `.agents` ocultas durante a montagem do pacote de publicação.
|
|
31
|
+
- Solução implementada através de pastas "mock" renomeadas durante a etapa de `dest` do instalador em Node.js.
|
|
32
|
+
|
|
33
|
+
## [1.0.0] - 2026-03-08
|
|
34
|
+
### Lançamento Inicial
|
|
35
|
+
- Projeto fundado.
|
|
36
|
+
- Criação do instalador executável `npx bps-kit`.
|
|
37
|
+
- Separação revolucionária de mais de 1.200 especialistas/skills em um `Vault` inabitado, resolvendo o problema de limite de context-window e "Attention Decay".
|
|
38
|
+
- Perfis `normal` (39 skills web) e `extra` (65 skills gerais) estabelecidos.
|
|
39
|
+
- Slash workflows, Rules customizadas e Scripts Python auditores importados com sucesso a partir do fork matriz.
|
package/README.md
CHANGED
|
@@ -1,25 +1,38 @@
|
|
|
1
|
-
# 🚀 BPS Kit
|
|
1
|
+
# 🚀 BPS Kit — The Ultimate Antigravity Brain
|
|
2
2
|
|
|
3
|
-
O **BPS Kit** é a evolução modular e
|
|
3
|
+
O **BPS Kit** é a evolução modular e de larga escala do consagrado ecossistema de inteligência artificial de desenvolvedor (Antigravity). Ele é projetado como um pacote `npx` que "injeta" as regras milimétricas, habilidades (skills), personas (agents) e scripts de validação de código direto no seu repositório local.
|
|
4
4
|
|
|
5
|
-
Seu principal diferencial é o **Skill Vault System**: o sistema resolve o limite de tokens das LLMs ao armazenar mais de +1.200 skills em um cofre (Vault)
|
|
5
|
+
Seu principal diferencial é o brilhante **Skill Vault System**: o sistema resolve o temido limite de tokens (Context Window) das LLMs ao armazenar mais de +1.200 skills valiosas em um cofre fechado (Vault) munido de um índice super comprimido. Ele mantém no seu "Core Ativo" apenas as Skills cruciais baseadas no perfil de desenvolvimento escolhido (ex: Web, Sec, Cloud).
|
|
6
6
|
|
|
7
7
|
## 📦 Instalação (Via NPX)
|
|
8
8
|
|
|
9
|
-
Você
|
|
9
|
+
Você não precisa e não deve instalar isso via `npm install` fixo. Você invoca a maleta de ferramentas instantaneamente na raiz do projeto sempre que quiser injetar o "cérebro":
|
|
10
10
|
|
|
11
11
|
```bash
|
|
12
|
-
#
|
|
13
|
-
npx bps-kit --normal
|
|
12
|
+
# 🟢 Modo Essencial (Antigravity Core - Web/React/Next - 39 Skills)
|
|
13
|
+
npx bps-kit@latest --normal
|
|
14
14
|
|
|
15
|
-
#
|
|
16
|
-
npx bps-kit --extra
|
|
15
|
+
# 🔴 Modo Extra (Engenharia Pesada - Cloud/Sec/Python/QA - 65 Skills)
|
|
16
|
+
npx bps-kit@latest --extra
|
|
17
|
+
|
|
18
|
+
# 🟡 Modo Economia Extrema (Apenas Motor Analítico - 11 Skills Cognitivas)
|
|
19
|
+
npx bps-kit@latest --basic
|
|
20
|
+
|
|
21
|
+
# 💻 Integrar nativamente para VS Code (GitHub Copilot)
|
|
22
|
+
# Adicione a flag --vscode combinada a qualquer um dos perfis acima:
|
|
23
|
+
npx bps-kit@latest --basic --vscode
|
|
17
24
|
```
|
|
18
25
|
|
|
19
|
-
### O que acontece após a instalação?
|
|
20
|
-
- A pasta `.agents/` será criada na raiz do seu repositório.
|
|
21
|
-
-
|
|
22
|
-
|
|
26
|
+
### 🧠 O que acontece após a instalação? (Motor Antigravity Padrão)
|
|
27
|
+
- A pasta oculta `.agents/` será criada na raiz do seu repositório.
|
|
28
|
+
- A IA que ler sua base de código passará instantaneamente a obedecer ao manifesto militar contido lá (o arquivo `GEMINI.md`), possuindo validação lint e audição de arquivos *out-of-the-box*.
|
|
29
|
+
|
|
30
|
+
### ⚡ O que acontece após a instalação? (VS Code / Copilot)
|
|
31
|
+
Se você adicionou a flag `--vscode`, a arquitetura compilada será organicamente moldada para as regras da nuvem do GitHub (`.github/`):
|
|
32
|
+
- O manifesto base e as Workflows irão habitar o `.github/copilot-instructions.md`.
|
|
33
|
+
- As Skills ativas receberão glob patterns específicos (`applyTo: "**/*"`) protegendo seu ciclo de vida.
|
|
34
|
+
- As famosas 20 Personas se fundirão em um único registro local `.github/AGENTS.md`.
|
|
35
|
+
- A gigantesca Vault contendo +1000 skills inativas será armazenada inteligentemente em isolamento (`.copilot-vault/`), salvando permanentemente seu limite de Chat no VS Code de travar.
|
|
23
36
|
|
|
24
37
|
### 🪄 Autocalibragem de Base de Código (Workflow Analyzer)
|
|
25
38
|
O BPS Kit inclui uma workflow customizada! Após rodar o npx no projeto, apenas diga para a IA no seu chat:
|
|
@@ -28,31 +41,27 @@ O BPS Kit inclui uma workflow customizada! Após rodar o npx no projeto, apenas
|
|
|
28
41
|
|
|
29
42
|
A inteligência fará um _scan_ do seu `package.json`, `requirements.txt` ou `composer.json` e autoativará skills específicas alojadas na Vault de acordo com a sua stack real!
|
|
30
43
|
|
|
31
|
-
###
|
|
32
|
-
|
|
33
|
-
Devido às limitações arquiteturais das LLMs modernas (como a enorme janela de contexto e o modelo de *Attention Decay*), assim como conflitos com o *System Prompt* nativo da IDE, a IA pode ocasionalmente "esquecer" ou atropelar o protocolo estrito do nosso `GEMINI.md` (deixando de anunciar a Persona e pulando o checklist) em conversas que fiquem muito extensas.
|
|
44
|
+
### 🛠️ Lidando com a Amnésia da IA (Attention Decay)
|
|
34
45
|
|
|
35
|
-
|
|
36
|
-
O BPS Kit já embute `Anti-Amnesia Protocols` nas regras internas, mas a sua melhor defesa caso a máquina saia dos trilhos para lhe entregar o código "mais rápido" que a formatação é o **RLHF (Reinforcement Learning from Human Feedback)** direcional.
|
|
46
|
+
Bugs de esquecimento ocorrem devido às limitações físicas das LLMs (enorme janela de contexto vs degradação de atenção ao longo da conversa). Com o tempo, a IA pode ocasionalmente "esquecer" ou atropelar o protocolo estrito do nosso manifesto.
|
|
37
47
|
|
|
38
|
-
|
|
48
|
+
**A Cura imediata via RLHF:**
|
|
49
|
+
O BPS Kit já embute dezenas de mecanismos passivos de _Anti-Amnesia Protocols_. Contudo, a sua melhor e definitiva defesa contínua é aplicar o **RLHF (Reinforcement Learning from Human Feedback)** direcional no chat quando o bot errar:
|
|
39
50
|
|
|
40
|
-
> *"Você quebrou as regras do
|
|
51
|
+
> *"Você quebrou as regras do seu System Prompt e do Antigravity Kit. Volte a ler e aplicar estritamente as regras de Skills abordadas de novo."*
|
|
41
52
|
|
|
42
|
-
Isso
|
|
53
|
+
Isso forçará a engine a jogar o lixo fora e focar nos blocos iniciais cruciais.
|
|
43
54
|
|
|
44
55
|
---
|
|
45
56
|
|
|
46
|
-
## 🏗️ Slash Commands
|
|
57
|
+
## 🏗️ Slash Commands Nativos (Modo Standard)
|
|
47
58
|
|
|
48
|
-
|
|
59
|
+
Se não estiver usando a flag `--vscode` (onde workflows são embutidas), você terá acesso à estrutura local com robustez. Digite no chat da sua IA:
|
|
49
60
|
|
|
50
|
-
- `/brainstorm` -
|
|
51
|
-
- `/
|
|
52
|
-
- `/
|
|
53
|
-
- `/
|
|
54
|
-
- `/deploy` - Validações hardcore antes de empurrar pra produção.
|
|
55
|
-
- `/setup-brain` - Roda o Analyzer de calibração do BPS Kit.
|
|
61
|
+
- `/brainstorm` - O mais importante. Obrigue-a explorar opções antes de disparar o teclado para programar.
|
|
62
|
+
- `/plan` - Desdobramentos detalhados de planejamento arquitetural.
|
|
63
|
+
- `/debug` - Roda o framework forense completo contra erros de teste (Systematic Debugging).
|
|
64
|
+
- `/deploy` - Exige checagens manuais e de segurança pesadas antes de cometer um simples origin master push.
|
|
56
65
|
|
|
57
66
|
---
|
|
58
67
|
|
|
@@ -60,13 +69,13 @@ Acesse workflows robustos empacotados digitando barras (slash) no chat da IA:
|
|
|
60
69
|
|
|
61
70
|
O **BPS Kit** deve sua fundação brilhante e seu mar enciclopédico de regras a bibliotecas open-source excepcionais de onde os templates originais foram bifurcados/incorporados. Deixamos nossos enormes agradecimentos às fontes originais:
|
|
62
71
|
|
|
63
|
-
1. **[antigravity-awesome-skills (by sickn33)](https://github.com/sickn33/antigravity-awesome-skills)**
|
|
64
|
-
|
|
72
|
+
1. **[antigravity-awesome-skills (by sickn33)](https://github.com/sickn33/antigravity-awesome-skills)**
|
|
73
|
+
A mãe de virtualmente todas as nossas mais de 1.100+ skills abrigadas no Vault. Essa bibilioteca lendária confere a capacidade enciclopédica esmagadora de cobrir quase que a íntegra dos casos de uso para software development do planeta (Mobile, Machine Learning, Copywriting, FinOps, Design, Data Engineering e DevOps).
|
|
65
74
|
|
|
66
|
-
2. **[antigravity-kit (by vudovn)](https://github.com/vudovn/antigravity-kit)**
|
|
67
|
-
A
|
|
75
|
+
2. **[antigravity-kit (by vudovn)](https://github.com/vudovn/antigravity-kit)**
|
|
76
|
+
A forja estrutural primária. Responsável pela árvore original de Personas de Agentes, Workflows, Slash Commands, e os potentes 18 scripts de validação Python Hardcore na camada de código em si.
|
|
68
77
|
|
|
69
|
-
|
|
78
|
+
A engenharia inteira do **BPS Kit** serve massivamente para unificar essas duas titânicas inteligências em um fluxo só — através da magia do Auto-Routing isolacionista por Glob e do Vaulting Comprimido — ultrapassando enfim as limitações brutais da context-window. Sem a colaboração fundadora de vudovn e sickn33, essa maravilha não existiria.
|
|
70
79
|
|
|
71
80
|
---
|
|
72
81
|
## 📄 Licença
|
package/bin/cli.js
CHANGED
|
@@ -9,8 +9,10 @@ const { program } = require('commander');
|
|
|
9
9
|
program
|
|
10
10
|
.version('1.0.0')
|
|
11
11
|
.description('BPS Kit Installer - The NextGen Modular AI Brain Setup')
|
|
12
|
-
.option('-
|
|
12
|
+
.option('-b, --basic', 'Modo economia extrema (11 skills apenas o core analítico, ideal para Copilot)')
|
|
13
|
+
.option('-n, --normal', 'Instala as skills essenciais (39 skills, ideal para Web/React/Next)')
|
|
13
14
|
.option('-e, --extra', 'Instala as skills avançadas Premium (65 skills, inclui Python, QA, Cloud e Sec)')
|
|
15
|
+
.option('--vscode', 'Converte a estrutura final herdada do Cursor/Windsurf (.agents) para o formato do VS Code GitHub Copilot (.github)')
|
|
14
16
|
.parse(process.argv);
|
|
15
17
|
|
|
16
18
|
const options = program.opts();
|
|
@@ -27,10 +29,12 @@ async function runInstaller() {
|
|
|
27
29
|
|
|
28
30
|
// Determinar o mode (default normal se nao passar args)
|
|
29
31
|
let mode = 'normal';
|
|
30
|
-
if (options.
|
|
32
|
+
if (options.basic) {
|
|
33
|
+
mode = 'basic';
|
|
34
|
+
} else if (options.extra) {
|
|
31
35
|
mode = 'extra';
|
|
32
|
-
} else if (!options.normal && !options.extra) {
|
|
33
|
-
console.log(chalk.yellow('⚠️ Nenhum perfil explicitado (--normal ou --extra). Utilizando default: --normal
|
|
36
|
+
} else if (!options.normal && !options.extra && !options.basic) {
|
|
37
|
+
console.log(chalk.yellow('⚠️ Nenhum perfil explicitado (--basic, --normal ou --extra). Utilizando default: --normal\n'));
|
|
34
38
|
}
|
|
35
39
|
|
|
36
40
|
const spinner = ora('Montando diretórios base...').start();
|
|
@@ -78,25 +82,32 @@ async function runInstaller() {
|
|
|
78
82
|
|
|
79
83
|
spinner.text = `Injetando pacotes de skills do perfil [${chalk.yellow(mode)}]...`;
|
|
80
84
|
|
|
81
|
-
//
|
|
82
|
-
|
|
83
|
-
path.join(TEMPLATES_DIR, '
|
|
84
|
-
|
|
85
|
-
|
|
85
|
+
// Copiar pacote baseado no mode
|
|
86
|
+
if (mode === 'basic') {
|
|
87
|
+
await fs.copy(path.join(TEMPLATES_DIR, 'skills_basic'), skillsDest);
|
|
88
|
+
} else if (mode === 'normal') {
|
|
89
|
+
await fs.copy(path.join(TEMPLATES_DIR, 'skills_normal'), skillsDest);
|
|
90
|
+
} else if (mode === 'extra') {
|
|
91
|
+
await fs.copy(path.join(TEMPLATES_DIR, 'skills_normal'), skillsDest);
|
|
92
|
+
await fs.copy(path.join(TEMPLATES_DIR, 'skills_extra'), skillsDest);
|
|
93
|
+
}
|
|
86
94
|
|
|
87
|
-
//
|
|
88
|
-
if (
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
);
|
|
95
|
+
// 5. Conversor para VS Code se solicitado
|
|
96
|
+
if (options.vscode) {
|
|
97
|
+
spinner.text = `Transformando arquitetura para padrão GitHub Copilot (VS Code)...`;
|
|
98
|
+
const { convertToVsCode } = require('../src/scripts/convert_to_vscode');
|
|
99
|
+
await convertToVsCode(DEST_AGENTS, DEST_BASE);
|
|
93
100
|
}
|
|
94
101
|
|
|
95
102
|
spinner.succeed(chalk.green('Cérebro de IA instanciado com sucesso!'));
|
|
96
103
|
|
|
104
|
+
let finalCount = '39';
|
|
105
|
+
if (mode === 'basic') finalCount = '11';
|
|
106
|
+
if (mode === 'extra') finalCount = '65';
|
|
107
|
+
|
|
97
108
|
console.log(chalk.cyan('\n============== [ RESUMO DA INSTALAÇÃO ] =============='));
|
|
98
109
|
console.log(chalk.white(`Perfil Carregado : `) + chalk.greenBright(mode.toUpperCase()));
|
|
99
|
-
console.log(chalk.white(`Skills Ativas : `) + chalk.greenBright(
|
|
110
|
+
console.log(chalk.white(`Skills Ativas : `) + chalk.greenBright(finalCount));
|
|
100
111
|
console.log(chalk.white(`Skills no Vault : `) + chalk.greenBright('1197'));
|
|
101
112
|
console.log(chalk.cyan('======================================================'));
|
|
102
113
|
|
package/package.json
CHANGED
package/templates/VAULT_INDEX.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# 🗄️ Vault Index
|
|
2
2
|
|
|
3
|
-
> 1197 skills in `./.agents/vault/`.
|
|
4
|
-
> To use: `view_file ./.agents/vault/{skill-name}/SKILL.md`
|
|
3
|
+
> 1197 skills in `./.agents/antigravity/vault/`.
|
|
4
|
+
> To use: `view_file ./.agents/antigravity/vault/{skill-name}/SKILL.md`
|
|
5
5
|
|
|
6
6
|
## Web & Frontend (53)
|
|
7
7
|
3d-web-experience angular angular-best-practices angular-migration angular-state-management angular-ui-patterns animejs-animation antigravity-design-expert antigravity-workflows baseline-ui chrome-extension-developer cloudflare-workers-expert design-md design-orchestration design-spells frontend-dev-guidelines frontend-mobile-development-component-scaffold frontend-mobile-security-xss-scan frontend-security-coder frontend-slides frontend-ui-dark-ts html-injection-testing nextjs-app-router-patterns radix-ui-design-system react-best-practices react-flow-architect react-flow-node-ts react-modernization react-native-architecture react-nextjs-development react-state-management react-ui-patterns spline-3d-integration tailwind-design-system threejs-animation threejs-fundamentals threejs-geometry threejs-interaction threejs-lighting threejs-loaders threejs-materials threejs-postprocessing threejs-shaders threejs-skills threejs-textures ui-skills ui-ux-pro-max ui-visual-validator web-artifacts-builder web-design-guidelines web-scraper web-security-testing webflow-automation
|
|
@@ -67,16 +67,16 @@ Agent activated → Check frontmatter "skills:" → Read SKILL.md (INDEX) → Re
|
|
|
67
67
|
## 🧠 Skill Auto-Routing System (v8.0.0 — Vault Edition)
|
|
68
68
|
|
|
69
69
|
### Architecture
|
|
70
|
-
- **Active skills** (~65): in `./.agents/skills/` — always in context
|
|
71
|
-
- **Vault skills** (~1200+): in `./.agents/vault/` — discoverable via index
|
|
70
|
+
- **Active skills** (~65): in `./.agents/antigravity/skills/` — always in context
|
|
71
|
+
- **Vault skills** (~1200+): in `./.agents/antigravity/vault/` — discoverable via index
|
|
72
72
|
|
|
73
73
|
### Core Rule — Skills First
|
|
74
74
|
After invoking any skill, explicitly say: '📖 Using skill: [skill-name]' before proceeding. If no skill was used, say: '⚠️ No skill used — responding from base knowledge.'
|
|
75
75
|
|
|
76
76
|
### Routing Flow
|
|
77
77
|
1. Check if an **active skill** covers the request → use it directly
|
|
78
|
-
2. If not → open `./.agents/skills/VAULT_INDEX.md` to find a vault skill
|
|
79
|
-
3. If found → `view_file ./.agents/vault/{name}/SKILL.md`
|
|
78
|
+
2. If not → open `./.agents/antigravity/skills/VAULT_INDEX.md` to find a vault skill
|
|
79
|
+
3. If found → `view_file ./.agents/antigravity/vault/{name}/SKILL.md`
|
|
80
80
|
4. If nothing found → respond from base knowledge
|
|
81
81
|
|
|
82
82
|
### Intent → Skill Routing Map (Active Skills)
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
const fs = require('fs-extra');
|
|
2
|
+
const path = require('path');
|
|
3
|
+
const chalk = require('chalk');
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Converte toda a estrutura .agents importada para .github estrutural do Copilot
|
|
7
|
+
* @param {string} destAgents O diretorio destino onde a copy crua (.agents) aportou
|
|
8
|
+
* @param {string} destBase A raiz do repositorio final
|
|
9
|
+
*/
|
|
10
|
+
async function convertToVsCode(destAgents, destBase) {
|
|
11
|
+
const gitHubDir = path.join(destBase, '.github');
|
|
12
|
+
const copilotInstructionsDir = path.join(gitHubDir, 'instructions');
|
|
13
|
+
|
|
14
|
+
await fs.ensureDir(copilotInstructionsDir);
|
|
15
|
+
|
|
16
|
+
console.log(chalk.dim(' [VS Code] Convertendo arquivos para sintaxe do Copilot...'));
|
|
17
|
+
|
|
18
|
+
// 1. Converter a rule master GEMINI.md em copilot-instructions.md
|
|
19
|
+
const geminiPath = path.join(destAgents, 'rules', 'GEMINI.md');
|
|
20
|
+
if (await fs.pathExists(geminiPath)) {
|
|
21
|
+
let content = await fs.readFile(geminiPath, 'utf8');
|
|
22
|
+
// Adaptamos os caminhos na rule principal para o contexto do .github/ do VS Code
|
|
23
|
+
content = content.replace(/\.\/\.agents\/skills\//g, './.github/instructions/');
|
|
24
|
+
content = content.replace(/\.\/\.agents\/vault\//g, './.copilot-vault/');
|
|
25
|
+
content = content.replace(/\.\/\.agents\/rules\/GEMINI\.md/g, './.github/copilot-instructions.md');
|
|
26
|
+
|
|
27
|
+
// As workflows no VS Code estao desabrigadas da pasta nativa, sugerimos le-las do vault ou inline
|
|
28
|
+
content += `\n\n## 🔄 Workflows Base\nAs workflows antigas de Cursor (/brainstorm, etc) agora devem ser invocadas naturalmente no chat: "Rode o fluxo de brainstorm". Consulte o AGENTS.md para contexto.\n`;
|
|
29
|
+
|
|
30
|
+
await fs.writeFile(path.join(gitHubDir, 'copilot-instructions.md'), content);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// 2. Converter as skills nativas (ativas) em glob .instructions.md
|
|
34
|
+
const skillsDest = path.join(destAgents, 'skills');
|
|
35
|
+
if (await fs.pathExists(skillsDest)) {
|
|
36
|
+
const skillsDirs = await fs.readdir(skillsDest);
|
|
37
|
+
for (const skillName of skillsDirs) {
|
|
38
|
+
const skillFile = path.join(skillsDest, skillName, 'SKILL.md');
|
|
39
|
+
if (await fs.pathExists(skillFile)) {
|
|
40
|
+
let content = await fs.readFile(skillFile, 'utf8');
|
|
41
|
+
|
|
42
|
+
// Injetamos um frontmatter basico aceitavel pelo Copilot apontando para tudo (**/*)
|
|
43
|
+
// para que a Skill ative independente do arquivo no Workspace se for convocada.
|
|
44
|
+
const vsCodeContent = `---
|
|
45
|
+
description: ${skillName.replace(/-/g, ' ')}
|
|
46
|
+
applyTo: "**/*"
|
|
47
|
+
---
|
|
48
|
+
${content}`;
|
|
49
|
+
await fs.writeFile(path.join(copilotInstructionsDir, `${skillName}.instructions.md`), vsCodeContent);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
// 3. Converter o Vault Index (Tudo que esta no index vira uma mera instruction text base local)
|
|
55
|
+
const vaultIndexSrc = path.join(destAgents, 'VAULT_INDEX.md');
|
|
56
|
+
if (await fs.pathExists(vaultIndexSrc)) {
|
|
57
|
+
let content = await fs.readFile(vaultIndexSrc, 'utf8');
|
|
58
|
+
content = content.replace(/\.\/\.agents\/vault\//g, './.copilot-vault/');
|
|
59
|
+
await fs.writeFile(path.join(copilotInstructionsDir, 'VAULT_INDEX.instructions.md'), content);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
// 4. Mover o Vault inteiro para uma pasta customizada oculta que nao polua a base restrita do Git / do Copilot local
|
|
63
|
+
const vaultSrc = path.join(destAgents, 'vault');
|
|
64
|
+
const copilotVaultDir = path.join(destBase, '.copilot-vault');
|
|
65
|
+
if (await fs.pathExists(vaultSrc)) {
|
|
66
|
+
await fs.move(vaultSrc, copilotVaultDir, { overwrite: true });
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
// 5. Consolidar as 20 personas (AGENTS) num unico arquivao master na root do github chamado AGENTS.md
|
|
70
|
+
const agentsSrc = path.join(destAgents, 'agents');
|
|
71
|
+
if (await fs.pathExists(agentsSrc)) {
|
|
72
|
+
const agentFiles = await fs.readdir(agentsSrc);
|
|
73
|
+
let consolidatedAgents = `# 🤖 Antigravity Copilot Agents Roster\n\n`;
|
|
74
|
+
for (const agent of agentFiles) {
|
|
75
|
+
if (agent.endsWith('.md')) {
|
|
76
|
+
const content = await fs.readFile(path.join(agentsSrc, agent), 'utf8');
|
|
77
|
+
consolidatedAgents += `\n## Agent: ${agent.replace('.md', '')}\n${content}\n---\n`;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
await fs.writeFile(path.join(gitHubDir, 'AGENTS.md'), consolidatedAgents);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// Limpeza pesada! Como o ambiente ja foi migrado de .agents para .github e .copilot-vault, delete a origem da instalacao hibrida.
|
|
84
|
+
await fs.remove(destAgents);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
module.exports = { convertToVsCode };
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: behavioral-modes
|
|
3
|
+
description: "AI operational modes (brainstorm, implement, debug, review, teach, ship, orchestrate). Use to adapt behavior based on task type."
|
|
4
|
+
risk: unknown
|
|
5
|
+
source: community
|
|
6
|
+
date_added: "2026-02-27"
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# Behavioral Modes - Adaptive AI Operating Modes
|
|
10
|
+
|
|
11
|
+
## Purpose
|
|
12
|
+
This skill defines distinct behavioral modes that optimize AI performance for specific tasks. Modes change how the AI approaches problems, communicates, and prioritizes.
|
|
13
|
+
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
## Available Modes
|
|
17
|
+
|
|
18
|
+
### 1. 🧠 BRAINSTORM Mode
|
|
19
|
+
|
|
20
|
+
**When to use:** Early project planning, feature ideation, architecture decisions
|
|
21
|
+
|
|
22
|
+
**Behavior:**
|
|
23
|
+
- Ask clarifying questions before assumptions
|
|
24
|
+
- Offer multiple alternatives (at least 3)
|
|
25
|
+
- Think divergently - explore unconventional solutions
|
|
26
|
+
- No code yet - focus on ideas and options
|
|
27
|
+
- Use visual diagrams (mermaid) to explain concepts
|
|
28
|
+
|
|
29
|
+
**Output style:**
|
|
30
|
+
```
|
|
31
|
+
"Let's explore this together. Here are some approaches:
|
|
32
|
+
|
|
33
|
+
Option A: [description]
|
|
34
|
+
✅ Pros: ...
|
|
35
|
+
❌ Cons: ...
|
|
36
|
+
|
|
37
|
+
Option B: [description]
|
|
38
|
+
✅ Pros: ...
|
|
39
|
+
❌ Cons: ...
|
|
40
|
+
|
|
41
|
+
What resonates with you? Or should we explore a different direction?"
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
### 2. ⚡ IMPLEMENT Mode
|
|
47
|
+
|
|
48
|
+
**When to use:** Writing code, building features, executing plans
|
|
49
|
+
|
|
50
|
+
**Behavior:**
|
|
51
|
+
- **CRITICAL: Use `clean-code` skill standards** - concise, direct, no verbose explanations
|
|
52
|
+
- Fast execution - minimize questions
|
|
53
|
+
- Use established patterns and best practices
|
|
54
|
+
- Write complete, production-ready code
|
|
55
|
+
- Include error handling and edge cases
|
|
56
|
+
- **NO tutorial-style explanations** - just code
|
|
57
|
+
- **NO unnecessary comments** - let code self-document
|
|
58
|
+
- **NO over-engineering** - solve the problem directly
|
|
59
|
+
- **NO RUSHING** - Quality > Speed. Read ALL references before coding.
|
|
60
|
+
|
|
61
|
+
**Output style:**
|
|
62
|
+
```
|
|
63
|
+
[Code block]
|
|
64
|
+
|
|
65
|
+
[Brief summary, max 1-2 sentences]
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
**NOT:**
|
|
69
|
+
```
|
|
70
|
+
"Building [feature]...
|
|
71
|
+
|
|
72
|
+
✓ Created [file1]
|
|
73
|
+
✓ Created [file2]
|
|
74
|
+
✓ Updated [file3]
|
|
75
|
+
|
|
76
|
+
[long explanation]
|
|
77
|
+
|
|
78
|
+
Run `npm run dev` to test."
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
### 3. 🔍 DEBUG Mode
|
|
84
|
+
|
|
85
|
+
**When to use:** Fixing bugs, troubleshooting errors, investigating issues
|
|
86
|
+
|
|
87
|
+
**Behavior:**
|
|
88
|
+
- Ask for error messages and reproduction steps
|
|
89
|
+
- Think systematically - check logs, trace data flow
|
|
90
|
+
- Form hypothesis → test → verify
|
|
91
|
+
- Explain the root cause, not just the fix
|
|
92
|
+
- Prevent future occurrences
|
|
93
|
+
|
|
94
|
+
**Output style:**
|
|
95
|
+
```
|
|
96
|
+
"Investigating...
|
|
97
|
+
|
|
98
|
+
🔍 Symptom: [what's happening]
|
|
99
|
+
🎯 Root cause: [why it's happening]
|
|
100
|
+
✅ Fix: [the solution]
|
|
101
|
+
🛡️ Prevention: [how to avoid in future]
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
### 4. 📋 REVIEW Mode
|
|
107
|
+
|
|
108
|
+
**When to use:** Code review, architecture review, security audit
|
|
109
|
+
|
|
110
|
+
**Behavior:**
|
|
111
|
+
- Be thorough but constructive
|
|
112
|
+
- Categorize by severity (Critical/High/Medium/Low)
|
|
113
|
+
- Explain the "why" behind suggestions
|
|
114
|
+
- Offer improved code examples
|
|
115
|
+
- Acknowledge what's done well
|
|
116
|
+
|
|
117
|
+
**Output style:**
|
|
118
|
+
```
|
|
119
|
+
## Code Review: [file/feature]
|
|
120
|
+
|
|
121
|
+
### 🔴 Critical
|
|
122
|
+
- [issue with explanation]
|
|
123
|
+
|
|
124
|
+
### 🟠 Improvements
|
|
125
|
+
- [suggestion with example]
|
|
126
|
+
|
|
127
|
+
### 🟢 Good
|
|
128
|
+
- [positive observation]
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
---
|
|
132
|
+
|
|
133
|
+
### 5. 📚 TEACH Mode
|
|
134
|
+
|
|
135
|
+
**When to use:** Explaining concepts, documentation, onboarding
|
|
136
|
+
|
|
137
|
+
**Behavior:**
|
|
138
|
+
- Explain from fundamentals
|
|
139
|
+
- Use analogies and examples
|
|
140
|
+
- Progress from simple to complex
|
|
141
|
+
- Include practical exercises
|
|
142
|
+
- Check understanding
|
|
143
|
+
|
|
144
|
+
**Output style:**
|
|
145
|
+
```
|
|
146
|
+
## Understanding [Concept]
|
|
147
|
+
|
|
148
|
+
### What is it?
|
|
149
|
+
[Simple explanation with analogy]
|
|
150
|
+
|
|
151
|
+
### How it works
|
|
152
|
+
[Technical explanation with diagram]
|
|
153
|
+
|
|
154
|
+
### Example
|
|
155
|
+
[Code example with comments]
|
|
156
|
+
|
|
157
|
+
### Try it yourself
|
|
158
|
+
[Exercise or task]
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
---
|
|
162
|
+
|
|
163
|
+
### 6. 🚀 SHIP Mode
|
|
164
|
+
|
|
165
|
+
**When to use:** Production deployment, final polish, release preparation
|
|
166
|
+
|
|
167
|
+
**Behavior:**
|
|
168
|
+
- Focus on stability over features
|
|
169
|
+
- Check for missing error handling
|
|
170
|
+
- Verify environment configs
|
|
171
|
+
- Run all tests
|
|
172
|
+
- Create deployment checklist
|
|
173
|
+
|
|
174
|
+
**Output style:**
|
|
175
|
+
```
|
|
176
|
+
## Pre-Ship Checklist
|
|
177
|
+
|
|
178
|
+
### ✅ Code Quality
|
|
179
|
+
- [ ] No TypeScript errors
|
|
180
|
+
- [ ] ESLint passing
|
|
181
|
+
- [ ] All tests passing
|
|
182
|
+
|
|
183
|
+
### ✅ Security
|
|
184
|
+
- [ ] No exposed secrets
|
|
185
|
+
- [ ] Input validation complete
|
|
186
|
+
|
|
187
|
+
### ✅ Performance
|
|
188
|
+
- [ ] Bundle size acceptable
|
|
189
|
+
- [ ] No console.logs
|
|
190
|
+
|
|
191
|
+
### 🚀 Ready to deploy
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
---
|
|
195
|
+
|
|
196
|
+
## Mode Detection
|
|
197
|
+
|
|
198
|
+
The AI should automatically detect the appropriate mode based on:
|
|
199
|
+
|
|
200
|
+
| Trigger | Mode |
|
|
201
|
+
|---------|------|
|
|
202
|
+
| "what if", "ideas", "options" | BRAINSTORM |
|
|
203
|
+
| "build", "create", "add" | IMPLEMENT |
|
|
204
|
+
| "not working", "error", "bug" | DEBUG |
|
|
205
|
+
| "review", "check", "audit" | REVIEW |
|
|
206
|
+
| "explain", "how does", "learn" | TEACH |
|
|
207
|
+
| "deploy", "release", "production" | SHIP |
|
|
208
|
+
|
|
209
|
+
---
|
|
210
|
+
|
|
211
|
+
## Multi-Agent Collaboration Patterns (2025)
|
|
212
|
+
|
|
213
|
+
Modern architectures optimized for agent-to-agent collaboration:
|
|
214
|
+
|
|
215
|
+
### 1. 🔭 EXPLORE Mode
|
|
216
|
+
**Role:** Discovery and Analysis (Explorer Agent)
|
|
217
|
+
**Behavior:** Socratic questioning, deep-dive code reading, dependency mapping.
|
|
218
|
+
**Output:** `discovery-report.json`, architectural visualization.
|
|
219
|
+
|
|
220
|
+
### 2. 🗺️ PLAN-EXECUTE-CRITIC (PEC)
|
|
221
|
+
Cyclic mode transitions for high-complexity tasks:
|
|
222
|
+
1. **Planner:** Decomposes the task into atomic steps (`task.md`).
|
|
223
|
+
2. **Executor:** Performs the actual coding (`IMPLEMENT`).
|
|
224
|
+
3. **Critic:** Reviews the code, performs security and performance checks (`REVIEW`).
|
|
225
|
+
|
|
226
|
+
### 3. 🧠 MENTAL MODEL SYNC
|
|
227
|
+
Behavior for creating and loading "Mental Model" summaries to preserve context between sessions.
|
|
228
|
+
|
|
229
|
+
---
|
|
230
|
+
|
|
231
|
+
## Combining Modes
|
|
232
|
+
|
|
233
|
+
---
|
|
234
|
+
|
|
235
|
+
## Manual Mode Switching
|
|
236
|
+
|
|
237
|
+
Users can explicitly request a mode:
|
|
238
|
+
|
|
239
|
+
```
|
|
240
|
+
/brainstorm new feature ideas
|
|
241
|
+
/implement the user profile page
|
|
242
|
+
/debug why login fails
|
|
243
|
+
/review this pull request
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
## When to Use
|
|
247
|
+
This skill is applicable to execute the workflow or actions described in the overview.
|