@aksp/opencrew 1.10.0 → 1.12.0
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 +100 -0
- package/README.md +15 -4
- package/package.json +1 -1
- package/src/commands/init.js +4 -5
- package/src/commands/update.js +8 -0
- package/src/lib/resumo.js +5 -1
- package/templates/AGENTS.md +16 -9
- package/templates/_opencrew/.opencrew-version +1 -1
- package/templates/_opencrew/core/architect.agent.yaml +25 -16
- package/templates/_opencrew/core/best-practices/_catalog.yaml +5 -0
- package/templates/_opencrew/core/best-practices/texto-livre.md +23 -0
- package/templates/_opencrew/core/formato-da-crew.md +162 -0
- package/templates/_opencrew/core/prompts/build.prompt.md +35 -59
- package/templates/_opencrew/core/prompts/design.prompt.md +16 -16
- package/templates/_opencrew/core/prompts/discovery.prompt.md +28 -8
- package/templates/_opencrew/core/prompts/documento.prompt.md +9 -5
- package/templates/_opencrew/core/prompts/entrega.prompt.md +7 -2
- package/templates/_opencrew/core/prompts/repair.prompt.md +75 -84
- package/templates/_opencrew/core/runner.pipeline.md +25 -28
- package/templates/_opencrew/core/scripts/caminho/argumentos.mjs +3 -1
- package/templates/_opencrew/core/scripts/caminho/nucleo.mjs +16 -0
- package/templates/_opencrew/core/scripts/caminho.mjs +11 -8
- package/templates/_opencrew/core/scripts/conferir-fontes/relatorio.mjs +4 -2
- package/templates/_opencrew/core/scripts/conferir-fontes.mjs +22 -16
- package/templates/_opencrew/core/scripts/conserto/achados.mjs +158 -0
- package/templates/_opencrew/core/scripts/conserto/aplicar.mjs +156 -0
- package/templates/_opencrew/core/scripts/conserto/argumentos.mjs +51 -0
- package/templates/_opencrew/core/scripts/conserto/crew.mjs +126 -0
- package/templates/_opencrew/core/scripts/conserto/edicoes.mjs +133 -0
- package/templates/_opencrew/core/scripts/conserto/gravar.mjs +55 -0
- package/templates/_opencrew/core/scripts/conserto.mjs +82 -0
- package/templates/_opencrew/core/scripts/documento/markdown.mjs +2 -1
- package/templates/_opencrew/core/scripts/documento/pacote.mjs +1 -0
- package/templates/_opencrew/core/scripts/documento/perfil.mjs +14 -0
- package/templates/_opencrew/core/scripts/entrega/pendencias.mjs +4 -1
- package/templates/_opencrew/core/scripts/entrega/separar.mjs +2 -1
- package/templates/_opencrew/core/scripts/verificar/documento.mjs +20 -0
- package/templates/_opencrew/core/scripts/verificar/medicao.mjs +2 -1
- package/templates/_opencrew/core/scripts/verificar/proibicoes.mjs +30 -5
- package/templates/_opencrew/core/scripts/verificar.mjs +3 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,106 @@
|
|
|
3
3
|
All notable changes to opencrew are documented here.
|
|
4
4
|
The format is based on [Keep a Changelog](https://keepachangelog.com/).
|
|
5
5
|
|
|
6
|
+
## [1.12.0] — 2026-10-07
|
|
7
|
+
|
|
8
|
+
Fase U5, fatia 1: "Polimento do uso" (`specs/fase-u5a-polimento-do-uso.md`). A U5 é a fase de
|
|
9
|
+
fechamento do projeto, em quatro fatias (`specs/fase-u5-roteiro.md`). Chega a quem já usa com um
|
|
10
|
+
`npx @aksp/opencrew@latest update`.
|
|
11
|
+
|
|
12
|
+
Ainda não nesta versão: o runner dividido (1.13.0), o histórico confiável e o "retomar" (1.14.0)
|
|
13
|
+
e o pedido avulso à crew (1.15.0).
|
|
14
|
+
|
|
15
|
+
### Added
|
|
16
|
+
- **Formato `texto-livre`** (o 24º guia): para o texto que não é post nem documento para
|
|
17
|
+
imprimir ou assinar — proposta, minuta que vira HTML ou PDF, plano, relatório interno. Não tem
|
|
18
|
+
limite de tamanho, não gera Word, e a entrega leva o arquivo inteiro para `outros/`. O
|
|
19
|
+
`/opencrew repair` passa a propô-lo para esse tipo de passo.
|
|
20
|
+
- **O que o Word não vai converter aparece antes do revisor.** No passo com
|
|
21
|
+
`format: documento-oficial`, o verificador avisa de imagem, de marcação `:::` desconhecida e
|
|
22
|
+
de bloco de assinaturas sem fim. São alertas: quem decide é o revisor.
|
|
23
|
+
- Aviso de conversão quando uma linha de tabela tem mais células que o cabeçalho.
|
|
24
|
+
|
|
25
|
+
### Changed
|
|
26
|
+
- **O nome da execução (`run_id`) vem do script**, com a data e a hora do computador
|
|
27
|
+
(`caminho.mjs <crew> pasta`, sem `--run`). Antes a IA montava a hora por conta própria.
|
|
28
|
+
- **Conferência de fontes:** o resumo concorda em número ("1 fonte", "1 alerta"); quando há
|
|
29
|
+
caminho com sugestão, o relatório diz como corrigir; com `--corrigir`, cada arquivo alterado
|
|
30
|
+
aparece com o nome da cópia que ficou, e o relatório sai uma vez só.
|
|
31
|
+
- Depois de um conserto por veto, o runner confere o arquivo de novo.
|
|
32
|
+
- O runner não cita mais ferramenta de uma IDE só ("Task tool", `.claude/settings.local.json`).
|
|
33
|
+
- **Perfil de documento oficial:** chave escrita quase certa (`Logotipo:`, `rodapé:`, com
|
|
34
|
+
espaço antes) agora é erro que diz a grafia certa; antes a linha era ignorada em silêncio.
|
|
35
|
+
- O onboarding grava o `company.md` com seis cabeçalhos fixos e tira a marca
|
|
36
|
+
`NOT CONFIGURED` dos dois arquivos.
|
|
37
|
+
- A linha "Não medido" some para formato que não declara limite (`documento-oficial`,
|
|
38
|
+
`texto-livre`).
|
|
39
|
+
- Na entrega sem canal de rede, "O que não foi conferido" não cita imagens nem redes.
|
|
40
|
+
- Prompts de criação: dez contradições que a execução real da 1.11.0 achou ganharam uma frase
|
|
41
|
+
cada (a pergunta de tier com modelo, `extends:` × "do zero", dependências de agente lidas
|
|
42
|
+
também do "Context Loading", skills nativas fora da conferência, exemplo de saída com 15
|
|
43
|
+
linhas, a pergunta 1 quando o comando já traz a descrição, entre outras).
|
|
44
|
+
|
|
45
|
+
### Fixed
|
|
46
|
+
- **Uma frase errada da 1.11.0.** O `/opencrew repair`, o README e este arquivo diziam que texto
|
|
47
|
+
sem formato "é medido como post de blog". Isso só acontece quando o arquivo tem `title:` no
|
|
48
|
+
frontmatter. O que acontece sempre, sem o formato: o redator não recebe o guia do tipo de
|
|
49
|
+
texto, e o verificador procura no arquivo peças de rede (legenda, post). A frase foi trocada
|
|
50
|
+
em todos os lugares.
|
|
51
|
+
|
|
52
|
+
## [1.11.0] — 2026-10-07
|
|
53
|
+
|
|
54
|
+
Fase U4, fatia 1: "Conserto de crews e caminho de criação" (`specs/fase-u4a-conserto-de-crews.md`).
|
|
55
|
+
Chega a quem já usa com um `npx @aksp/opencrew@latest update`; as suas crews só mudam quando você
|
|
56
|
+
pede o conserto e diz sim a cada ponto.
|
|
57
|
+
|
|
58
|
+
Ainda não nesta versão: histórico confiável, retomar uma execução interrompida e pedido avulso à
|
|
59
|
+
crew (`/opencrew pedir`), que ficaram para a fase U5 (`specs/fase-u5-roteiro.md`). O conserto não reordena passos: crew
|
|
60
|
+
sem revisão, sem aprovação final ou que publica antes da revisão é apontada e resolvida com
|
|
61
|
+
`/opencrew edit`.
|
|
62
|
+
|
|
63
|
+
### Added
|
|
64
|
+
- **`/opencrew repair <crew>` conserta crews antigas.** Ele lê a crew e mostra, em português, o
|
|
65
|
+
que falta para as melhorias das versões seguintes valerem nela: passo sem o formato do texto
|
|
66
|
+
(o redator ficava sem o guia do tipo de texto), crew sem os arquivos do projeto que deve ler,
|
|
67
|
+
proibição sem trecho entre aspas (que o verificador não consegue barrar), nomes dos agentes,
|
|
68
|
+
passo que publica sem a marca. Conserta um ponto por vez, com o seu sim; cada arquivo alterado
|
|
69
|
+
ganha uma cópia `.bak`. Quem grava é um script (`_opencrew/core/scripts/conserto.mjs`), não a
|
|
70
|
+
IA; sem `--aplicar` ele só lê.
|
|
71
|
+
- **Proibição que é regra de conteúdo** ("nunca prever votação por aclamação") pode ser marcada
|
|
72
|
+
como `(revisão humana)`: fica para o revisor e deixa de aparecer como pendência do verificador.
|
|
73
|
+
- **Crew de documento na criação.** Pedir uma crew de ata, ofício, contrato ou proposta leva a
|
|
74
|
+
perguntas próprias (quais documentos, quem assina e quem recebe, papel timbrado, quais arquivos
|
|
75
|
+
mandam no texto), sem a oferta de investigar perfis de referência, e os passos já saem com o
|
|
76
|
+
formato `documento-oficial`.
|
|
77
|
+
- **Formato da crew escrito num lugar só** (`_opencrew/core/formato-da-crew.md`): `crew.yaml`,
|
|
78
|
+
`pipeline.yaml`, os campos de cada passo e o `id` do agente, com um exemplo completo. A criação,
|
|
79
|
+
o runner e o conserto seguem esse arquivo; as formas que versões antigas gravaram continuam
|
|
80
|
+
sendo lidas.
|
|
81
|
+
- Depois do `update`, quando o projeto tem ao menos uma crew, o resumo lembra do
|
|
82
|
+
`/opencrew repair`.
|
|
83
|
+
|
|
84
|
+
### Changed
|
|
85
|
+
- **`max_review_cycles` no `crew.yaml` passa a valer.** O runner só lia o limite de ciclos de
|
|
86
|
+
revisão no passo de revisão; crews que o declaravam no `crew.yaml` recebiam sempre 3.
|
|
87
|
+
- **Tier Express tem passo de revisão**, feito pelo próprio redator: o verificador automático roda
|
|
88
|
+
também nele. Antes o texto dizia "o redator se revisa" e, em outro ponto, "toda crew precisa de
|
|
89
|
+
revisor".
|
|
90
|
+
- **Checkpoint que guarda a resposta em arquivo** deixa de usar sempre o formato de "foco de
|
|
91
|
+
pesquisa": fora do checkpoint do pesquisador, grava o título, a sua resposta e a data.
|
|
92
|
+
- O Architect lista os prompts de cada fase da criação, e o ponto de entrada diz onde ele está;
|
|
93
|
+
antes um apontava para o outro.
|
|
94
|
+
- Pasta de `crews/` sem `crew.yaml` (os modelos instalados) não aparece mais como crew nas
|
|
95
|
+
listas.
|
|
96
|
+
|
|
97
|
+
### Fixed
|
|
98
|
+
- `init --ide=<lista> --yes` (e `--all`) instalava as pontes das 9 IDEs; agora a lista vence.
|
|
99
|
+
`--yes` sem `--ide` continua instalando todas.
|
|
100
|
+
- Uma frase cortada no meio nas instruções instaladas (`_opencrew/core/system.md`, desde a
|
|
101
|
+
1.10.0): a rota do documento Word e o pedido de entrega de uma execução encerrada não exigem o
|
|
102
|
+
onboarding.
|
|
103
|
+
- O Build exigia um checkpoint imediatamente antes de cada passo que publica, o que era
|
|
104
|
+
impossível com dois passos de publicação seguidos.
|
|
105
|
+
|
|
6
106
|
## [1.10.0] — 2026-10-07
|
|
7
107
|
|
|
8
108
|
Fase U3b "Documento Word, com perfil de documento oficial" (`specs/fase-u3b-documento-word.md`).
|
package/README.md
CHANGED
|
@@ -184,8 +184,9 @@ meu-projeto/
|
|
|
184
184
|
│ │ ├── runner.pipeline.md ← executor de pipeline
|
|
185
185
|
│ │ ├── skills.engine.md ← gerenciador de skills
|
|
186
186
|
│ │ ├── architect.agent.yaml ← definição do Arquiteto
|
|
187
|
-
│ │ ├──
|
|
188
|
-
│ │ ├──
|
|
187
|
+
│ │ ├── formato-da-crew.md ← o formato dos arquivos de uma crew (crew.yaml, pipeline.yaml, passos)
|
|
188
|
+
│ │ ├── best-practices/ ← 24 guias de melhores práticas + _catalog.yaml
|
|
189
|
+
│ │ ├── scripts/ ← verificador, conferência de fontes, caminhos, entrega, documento Word, conserto de crews e os scripts do Escritório
|
|
189
190
|
│ │ ├── modelos/ ← modelo do perfil de documento oficial (papel timbrado)
|
|
190
191
|
│ │ ├── escritorio/ ← página do Escritório ao vivo (abre com /opencrew dashboard)
|
|
191
192
|
│ │ └── prompts/ ← 15 prompts de fase (discovery, design, build, entrega, documento, etc.)
|
|
@@ -437,6 +438,16 @@ o que você fez:
|
|
|
437
438
|
`# opencrew:end`)? Nenhuma linha sua é apagada: o `update` guarda o arquivo como estava e põe
|
|
438
439
|
um bloco completo no fim. O bloco começa por um comentário que diz que ele é do OpenCrew: as
|
|
439
440
|
suas linhas ficam fora dele.
|
|
441
|
+
- **E as crews que você já tinha?** O `update` não mexe nelas. Para levar a elas o que veio
|
|
442
|
+
depois — o formato de cada texto (sem ele o redator não recebe o guia do tipo de texto), os
|
|
443
|
+
arquivos do projeto que a crew deve ler, as proibições que o verificador consegue barrar —,
|
|
444
|
+
peça na sua IDE `/opencrew repair <nome>`. Ele mostra o que falta, pergunta antes de cada
|
|
445
|
+
mudança e deixa uma cópia `.bak` do arquivo que alterou. O que não dá para consertar assim
|
|
446
|
+
(crew sem passo de revisão, publicação antes da revisão) ele aponta e manda para
|
|
447
|
+
`/opencrew edit`.
|
|
448
|
+
- **Texto que não é post nem documento para assinar?** Proposta, minuta que outro passo diagrama,
|
|
449
|
+
plano: o passo recebe o formato `texto-livre`. Não há limite de tamanho, nada vira Word, e a
|
|
450
|
+
entrega guarda o arquivo como está, em `outros/`.
|
|
440
451
|
- **A instalação anterior parou no meio?** O `update` não altera nada e pede para você rodar
|
|
441
452
|
`npx @aksp/opencrew init`, que conclui a instalação sem apagar o que já existe.
|
|
442
453
|
- **Apagou um modelo de crew ou um skill do catálogo?** Ele volta no `update`, e a saída diz o
|
|
@@ -489,7 +500,7 @@ npx @aksp/opencrew update --check
|
|
|
489
500
|
| `/opencrew run <nome>` | Executa o pipeline de uma crew |
|
|
490
501
|
| `/opencrew list` | Lista todas as suas crews |
|
|
491
502
|
| `/opencrew edit <nome>` | Modifica uma crew existente |
|
|
492
|
-
| `/opencrew repair <nome>` |
|
|
503
|
+
| `/opencrew repair <nome>` | Mostra o que falta numa crew que você já tem (formato de cada texto, arquivos do projeto que ela deve ler, proibições que o verificador consegue barrar, nomes dos agentes) e conserta um ponto por vez, com o seu sim e uma cópia `.bak` |
|
|
493
504
|
| `/opencrew delete <nome>` | Remove uma crew |
|
|
494
505
|
| `/opencrew skills` | Navega, instala ou remove skills |
|
|
495
506
|
| `/opencrew install <skill>` | Instala uma skill do catálogo |
|
|
@@ -509,7 +520,7 @@ npx @aksp/opencrew update --check
|
|
|
509
520
|
| `npx @aksp/opencrew@latest update` | Atualiza o framework |
|
|
510
521
|
| `npx @aksp/opencrew update --check` (ou `--dry-run`) | Verifica se há update disponível, sem alterar nada |
|
|
511
522
|
| `npx @aksp/opencrew upgrade` | Atalho para `update` |
|
|
512
|
-
| `npx @aksp/opencrew init --ide=claude-code,cursor` | Instala só as pontes das IDEs indicadas |
|
|
523
|
+
| `npx @aksp/opencrew init --ide=claude-code,cursor` | Instala só as pontes das IDEs indicadas (também com `--yes`) |
|
|
513
524
|
| `npx @aksp/opencrew init --all` (ou `-y`) | Instala as pontes de todas as IDEs |
|
|
514
525
|
| `npx @aksp/opencrew@latest init --repair-bridges` | Regrava as pontes das IDEs já instaladas num workspace existente (`--ide=a,b`: só as indicadas; `--all`: as 9) |
|
|
515
526
|
| `npx @aksp/opencrew version` | Mostra a versão instalada |
|
package/package.json
CHANGED
package/src/commands/init.js
CHANGED
|
@@ -148,14 +148,13 @@ async function workspaceState(target) {
|
|
|
148
148
|
}
|
|
149
149
|
|
|
150
150
|
/**
|
|
151
|
-
* Decide which IDEs to configure. --
|
|
152
|
-
* nothing → `fallback()` (the interactive prompt; in repair mode, the
|
|
153
|
-
* UsageError if --ide names no valid IDE.
|
|
151
|
+
* Decide which IDEs to configure. --ide → validated list, whatever comes with it; without it,
|
|
152
|
+
* --all / --yes → every IDE; nothing → `fallback()` (the interactive prompt; in repair mode, the
|
|
153
|
+
* detection). Throws UsageError if --ide names no valid IDE.
|
|
154
154
|
*/
|
|
155
155
|
async function resolveIdes(opts, fallback) {
|
|
156
|
-
if (opts.all || opts.yes) return allIdeIds();
|
|
157
156
|
const ids = normalizeIdes(opts.ide);
|
|
158
|
-
if (!ids) return fallback();
|
|
157
|
+
if (!ids) return opts.all || opts.yes ? allIdeIds() : fallback();
|
|
159
158
|
const invalid = ids.filter((id) => !ideById(id));
|
|
160
159
|
const valid = ids.filter((id) => ideById(id));
|
|
161
160
|
if (!valid.length) {
|
package/src/commands/update.js
CHANGED
|
@@ -88,6 +88,7 @@ async function apply(target, version) {
|
|
|
88
88
|
const done = { unreadable, ...(await refreshBridges(ctx)) };
|
|
89
89
|
done.mcp = await updateMcp(ctx, await readFile(tpl('.mcp.json')));
|
|
90
90
|
done.leftovers = await findLeftovers(target);
|
|
91
|
+
done.hasCrew = await hasCrew(target);
|
|
91
92
|
say(updateSummary(ctx, done));
|
|
92
93
|
|
|
93
94
|
await writeManifest(target, version, ctx.files);
|
|
@@ -97,6 +98,13 @@ async function apply(target, version) {
|
|
|
97
98
|
log(c.dim(`${UNTOUCHED}\n`));
|
|
98
99
|
}
|
|
99
100
|
|
|
101
|
+
/** Is there a crew of the user's? A folder of `crews/` with `crew.yaml` (the templates have none). Only looks. */
|
|
102
|
+
async function hasCrew(target) {
|
|
103
|
+
const dirs = await fs.readdir(path.join(target, 'crews'), { withFileTypes: true }).catch(() => []);
|
|
104
|
+
const found = await Promise.all(dirs.filter((d) => d.isDirectory()).map((d) => exists(path.join(target, 'crews', d.name, 'crew.yaml'))));
|
|
105
|
+
return found.includes(true);
|
|
106
|
+
}
|
|
107
|
+
|
|
100
108
|
/** @returns what `deliverTree` did to each crew template (only the missing ones are written). */
|
|
101
109
|
async function refreshFramework(ctx) {
|
|
102
110
|
const dest = (...p) => path.join(ctx.target, ...p);
|
package/src/lib/resumo.js
CHANGED
|
@@ -18,6 +18,9 @@ export const ALREADY_INSTALLED = 'Para atualizar, rode `npx @aksp/opencrew@lates
|
|
|
18
18
|
/** `update` over `_opencrew/core` with no version stamp (spec U3a-2, rule 31). */
|
|
19
19
|
export const INTERRUPTED = 'A instalação anterior não terminou. Rode `npx @aksp/opencrew init` para concluir.';
|
|
20
20
|
|
|
21
|
+
/** After an `update`, when the project has at least one crew (spec U4-1, decision 7). */
|
|
22
|
+
export const REPAIR_HINT = 'Para levar as melhorias novas às crews que você já tem, peça na sua IDE: /opencrew repair';
|
|
23
|
+
|
|
21
24
|
const NO_BRIDGES = 'Nenhuma ponte de IDE encontrada: nada a atualizar. Para criar a ponte de uma IDE: `npx @aksp/opencrew@latest init --repair-bridges --ide=<id>`.';
|
|
22
25
|
const LEAK_REMOVED = 'CLAUDE.md: removi a seção de STATUS.md que as versões 1.4.0 e 1.4.1 gravaram por engano.';
|
|
23
26
|
const FIRST_PROTECTED = 'Primeira atualização com proteção: sem registro anterior, guardamos tudo o que diferia. Daqui em diante, só o que você editar.';
|
|
@@ -112,7 +115,7 @@ function copyLines(ctx, unreadable) {
|
|
|
112
115
|
* @param {object} done what each step returned: `agents` and `gitignore` (deliverBlock; `agents`
|
|
113
116
|
* is null when a pre-1.3 AGENTS.md was migrated), `ides` (detected), `bridges` (deliverBridges),
|
|
114
117
|
* `leak` (the STATUS.md section left CLAUDE.md's block), `mcp` (updateMcp), `leftovers`
|
|
115
|
-
* (findLeftovers)
|
|
118
|
+
* (findLeftovers), `unreadable` (manifest) and `hasCrew` (a folder of `crews/` with `crew.yaml`)
|
|
116
119
|
* @returns {Array<[Function, string]>} lines for `say`
|
|
117
120
|
*/
|
|
118
121
|
export function updateSummary(ctx, done) {
|
|
@@ -124,5 +127,6 @@ export function updateSummary(ctx, done) {
|
|
|
124
127
|
...mcpLines(ctx, done.mcp),
|
|
125
128
|
...leftoverLines(done.leftovers, done.mcp),
|
|
126
129
|
...copyLines(ctx, done.unreadable),
|
|
130
|
+
...(done.hasCrew ? [[info, REPAIR_HINT]] : []),
|
|
127
131
|
];
|
|
128
132
|
}
|
package/templates/AGENTS.md
CHANGED
|
@@ -10,8 +10,10 @@ On activation, perform these steps IN ORDER:
|
|
|
10
10
|
1. Read the company context file: `{project-root}/_opencrew/_memory/company.md`
|
|
11
11
|
2. Read the preferences file: `{project-root}/_opencrew/_memory/preferences.md`
|
|
12
12
|
3. Check if company.md is empty or contains only the template — if so, trigger ONBOARDING
|
|
13
|
-
(except for `/opencrew documento` and the
|
|
14
|
-
|
|
13
|
+
(except for `/opencrew documento` and the request to deliver a run that already ended: neither
|
|
14
|
+
uses the company context)
|
|
15
|
+
4. Otherwise: when the message carried a command or a request, route it (Command Routing);
|
|
16
|
+
display the MAIN MENU only when it carried none
|
|
15
17
|
|
|
16
18
|
## Onboarding Flow (first time only)
|
|
17
19
|
|
|
@@ -24,8 +26,12 @@ If `company.md` is empty or contains `<!-- NOT CONFIGURED -->`:
|
|
|
24
26
|
description/sector, target audience, products/services, tone of voice,
|
|
25
27
|
social media profiles
|
|
26
28
|
4. Present findings in a clean summary, ask the user to confirm or correct,
|
|
27
|
-
save the profile to `_opencrew/_memory/company.md`
|
|
28
|
-
|
|
29
|
+
save the profile to `_opencrew/_memory/company.md` under these fixed headings, in this order:
|
|
30
|
+
`## Nome`, `## O que faz`, `## Público`, `## Produtos e serviços`, `## Tom de voz`,
|
|
31
|
+
`## Site e redes` (under it, the site goes on its own line, `- Site: https://…`). Then remove the line
|
|
32
|
+
`<!-- NOT CONFIGURED -->` from `company.md` and from `preferences.md`
|
|
33
|
+
5. When the message that started this carried a command or a request, route it now (Command
|
|
34
|
+
Routing); show the main menu only when it carried none
|
|
29
35
|
|
|
30
36
|
## Main Menu
|
|
31
37
|
|
|
@@ -50,11 +56,11 @@ Route input to the matching action:
|
|
|
50
56
|
|---------------|--------|
|
|
51
57
|
| `/opencrew` or `/opencrew menu` | Show main menu |
|
|
52
58
|
| `/opencrew help` | Show help text |
|
|
53
|
-
| `/opencrew create <description>` | Load Architect → Create Crew flow |
|
|
54
|
-
| `/opencrew list` | List all crews in `crews/` |
|
|
59
|
+
| `/opencrew create <description>` | Load the Architect (`_opencrew/core/architect.agent.yaml`) → Create Crew flow: one prompt per phase, listed there |
|
|
60
|
+
| `/opencrew list` | List all crews in `crews/` (a folder without `crew.yaml` is not a crew) |
|
|
55
61
|
| `/opencrew run <name>` | Load Pipeline Runner → Execute crew |
|
|
56
|
-
| `/opencrew edit <name> <changes>` | Load Architect → Edit Crew flow |
|
|
57
|
-
| `/opencrew repair <name>` | Load `_opencrew/core/prompts/repair.prompt.md` → fix
|
|
62
|
+
| `/opencrew edit <name> <changes>` | Load the Architect → Edit Crew flow |
|
|
63
|
+
| `/opencrew repair <name>` | Load `_opencrew/core/prompts/repair.prompt.md` → show what an existing crew is missing and fix one point at a time, each with a `.bak` copy |
|
|
58
64
|
| `/opencrew skills` | Load Skills Engine → Show skills menu |
|
|
59
65
|
| `/opencrew install <name>` | Install a skill from the catalog |
|
|
60
66
|
| `/opencrew uninstall <name>` | Remove an installed skill |
|
|
@@ -74,7 +80,8 @@ Route input to the matching action:
|
|
|
74
80
|
|
|
75
81
|
When a specific agent needs to be activated:
|
|
76
82
|
|
|
77
|
-
1. Read the agent's `.agent.md` file completely
|
|
83
|
+
1. Read the agent's `.agent.md` file completely (the Architect is the exception: it lives in
|
|
84
|
+
`_opencrew/core/architect.agent.yaml`)
|
|
78
85
|
2. Adopt the agent's persona (role, identity, communication_style, principles)
|
|
79
86
|
3. Follow the agent's menu/workflow instructions
|
|
80
87
|
4. When the agent's task is complete, return to the opencrew main context
|
|
@@ -1 +1 @@
|
|
|
1
|
-
1.
|
|
1
|
+
1.12.0
|
|
@@ -57,24 +57,30 @@ agent:
|
|
|
57
57
|
create-crew: |
|
|
58
58
|
## Create Crew
|
|
59
59
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
60
|
+
Creating a crew takes four phases, in this order. Each phase is one prompt: read it
|
|
61
|
+
completely when its turn comes, follow it to the end, and only then load the next one.
|
|
62
|
+
|
|
63
|
+
1. `_opencrew/core/prompts/discovery.prompt.md` — Discovery: the questions; ends by
|
|
64
|
+
writing `crews/{code}/_build/discovery.yaml`
|
|
65
|
+
2. `_opencrew/core/prompts/sherlock-shared.md` — Investigation: ONLY when the discovery
|
|
66
|
+
ended with the investigation enabled; it names the platform prompt to load with it
|
|
67
|
+
3. `_opencrew/core/prompts/design.prompt.md` — Design: agents and pipeline (includes the
|
|
68
|
+
optional template selection); ends by writing `crews/{code}/_build/design.yaml`
|
|
69
|
+
4. `_opencrew/core/prompts/build.prompt.md` — Build: writes the crew files, in the format
|
|
70
|
+
of `_opencrew/core/formato-da-crew.md`, and validates them
|
|
71
|
+
|
|
72
|
+
If your IDE can run a phase as a subagent, you may; otherwise run the phases one after
|
|
73
|
+
the other in this conversation. Never skip a phase and never write crew files before
|
|
74
|
+
the Build.
|
|
71
75
|
|
|
72
76
|
edit-crew: |
|
|
73
77
|
## Edit Crew Workflow
|
|
74
78
|
|
|
75
|
-
1. Ask which crew to edit (list available crews if not specified
|
|
79
|
+
1. Ask which crew to edit (list available crews if not specified; a folder without
|
|
80
|
+
crew.yaml is not a crew).
|
|
76
81
|
If only 1 crew exists, add "Cancel" as a second option. If 0 crews, inform user directly.
|
|
77
|
-
2. Read the crew's crew.yaml to understand current structure
|
|
82
|
+
2. Read the crew's crew.yaml to understand current structure (the format of the crew
|
|
83
|
+
files is in `_opencrew/core/formato-da-crew.md`)
|
|
78
84
|
3. Ask what changes the user wants
|
|
79
85
|
4. **If the user asks to edit/define/change the visual template or identity of a design agent:**
|
|
80
86
|
- Read and follow `skills/template-designer/SKILL.md`
|
|
@@ -86,8 +92,10 @@ agent:
|
|
|
86
92
|
list-crews: |
|
|
87
93
|
## List Crews Workflow
|
|
88
94
|
|
|
89
|
-
1. Read all directories in crews
|
|
90
|
-
|
|
95
|
+
1. Read all directories in crews/. A folder without crew.yaml is not a crew (the
|
|
96
|
+
template folders installed with the product): leave it out
|
|
97
|
+
2. For each crew, read crew.yaml to get name, description and icon (inside `crew:` or,
|
|
98
|
+
in older crews, loose at the top level) and count the agents in crew-party.csv
|
|
91
99
|
3. Present as a formatted list:
|
|
92
100
|
```
|
|
93
101
|
Your Crews:
|
|
@@ -102,7 +110,8 @@ agent:
|
|
|
102
110
|
delete-crew: |
|
|
103
111
|
## Delete Crew Workflow
|
|
104
112
|
|
|
105
|
-
1. Ask which crew to delete (list available if not specified
|
|
113
|
+
1. Ask which crew to delete (list available if not specified; a folder without
|
|
114
|
+
crew.yaml is not a crew).
|
|
106
115
|
If only 1 crew exists, add "Cancel" as a second option. If 0 crews, inform user directly.
|
|
107
116
|
2. Show crew details (name, agents, output count)
|
|
108
117
|
3. Confirm deletion with explicit "Are you sure?" presented as a numbered list (1. Yes, delete / 2. No, cancel)
|
|
@@ -119,3 +119,8 @@ catalog:
|
|
|
119
119
|
name: "Documento oficial (Word)"
|
|
120
120
|
whenToUse: "Creating agents that produce a document to print, sign or file (minutes, official letter, statement, contract, formal report) that becomes a Word file."
|
|
121
121
|
file: documento-oficial.md
|
|
122
|
+
|
|
123
|
+
- id: texto-livre
|
|
124
|
+
name: "Texto livre"
|
|
125
|
+
whenToUse: "Creating agents that write a text with no channel and no Word file: commercial proposal, draft that becomes HTML or PDF, work plan, internal report."
|
|
126
|
+
file: texto-livre.md
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: "Texto livre"
|
|
3
|
+
content_type: "plain-text"
|
|
4
|
+
description: "Text with no channel and no Word file: a proposal, a draft that becomes HTML or PDF, a plan, an internal report"
|
|
5
|
+
whenToUse: |
|
|
6
|
+
Creating agents that write a text that is not a post for a network and is not a document to print or sign: commercial proposal, draft (minuta) that another step turns into HTML or PDF, work plan, internal report, briefing.
|
|
7
|
+
version: "1.0.0"
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## Compact Rules
|
|
11
|
+
|
|
12
|
+
1. Write the full, final text: no outline, no notes to the reader, no "insert here".
|
|
13
|
+
2. No YAML frontmatter and no labels such as `=== TITLE ===`: everything in the file is the text itself.
|
|
14
|
+
3. Use `#`, `##` and `###` for the sections, simple tables for figures, `- ` for lists.
|
|
15
|
+
4. Missing real data is marked `[PREENCHER: o que falta]`; never invent a name, a date, a price or a number.
|
|
16
|
+
5. Copy figures exactly from the file they come from; when a total is shown, the parts add up to it.
|
|
17
|
+
6. Follow the structure the step asks for (its "Output Format"): this guide adds no structure of its own.
|
|
18
|
+
|
|
19
|
+
## What this format does not do
|
|
20
|
+
|
|
21
|
+
There is no size limit here and nothing is converted: the delivery keeps the file as it is, in
|
|
22
|
+
`outros/`. For a text to print, sign or file, use `documento-oficial`; for a post, an e-mail or a
|
|
23
|
+
message, use the format of that channel.
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
# Crew file format (formato da crew)
|
|
2
|
+
|
|
3
|
+
The single definition of the files that make a crew. The Build phase writes them, the Pipeline
|
|
4
|
+
Runner and the scripts read them, `/opencrew repair` checks them. When another prompt and this
|
|
5
|
+
file disagree, this file wins.
|
|
6
|
+
|
|
7
|
+
```
|
|
8
|
+
crews/{code}/
|
|
9
|
+
├── crew.yaml the crew: identity, sources, limits
|
|
10
|
+
├── crew-party.csv one row per agent (the names shown to the user)
|
|
11
|
+
├── agents/{agent-id}.agent.md
|
|
12
|
+
├── pipeline/
|
|
13
|
+
│ ├── pipeline.yaml the order of the steps
|
|
14
|
+
│ ├── steps/step-NN-{name}.md
|
|
15
|
+
│ └── data/ reference material (never an output)
|
|
16
|
+
├── _memory/ memories.md, runs.md
|
|
17
|
+
└── output/{run_id}/ what each run produces
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
A folder under `crews/` without a `crew.yaml` is not a crew (the template folders installed with
|
|
21
|
+
the product only carry `discovery.template.yaml`).
|
|
22
|
+
|
|
23
|
+
## crew.yaml
|
|
24
|
+
|
|
25
|
+
```yaml
|
|
26
|
+
crew:
|
|
27
|
+
code: "atas-do-conselho" # the folder name
|
|
28
|
+
name: "Atas do Conselho" # shown in lists
|
|
29
|
+
description: "Da pauta à ata pronta para assinar"
|
|
30
|
+
icon: "📄"
|
|
31
|
+
tier: "standard" # express | standard | full
|
|
32
|
+
|
|
33
|
+
pipeline:
|
|
34
|
+
entry: "pipeline/pipeline.yaml"
|
|
35
|
+
steps_dir: "pipeline/steps"
|
|
36
|
+
|
|
37
|
+
skills: # every skill the agents use
|
|
38
|
+
- web_search
|
|
39
|
+
- web_fetch
|
|
40
|
+
|
|
41
|
+
data: # reference material the steps load
|
|
42
|
+
- pipeline/data/domain-framework.md
|
|
43
|
+
- pipeline/data/quality-criteria.md
|
|
44
|
+
|
|
45
|
+
fontes: # files of the user's project the crew must read
|
|
46
|
+
- caminho: Regras/estatuto.md # relative to the project root, never absolute
|
|
47
|
+
para_que: regras que mandam no texto
|
|
48
|
+
|
|
49
|
+
agent_dependencies: # only when an agent can be left out (see below)
|
|
50
|
+
rita-redacao: []
|
|
51
|
+
vito-veredito: [rita-redacao]
|
|
52
|
+
|
|
53
|
+
max_review_cycles: 2 # express 1 · standard 2 · full 3
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
| Field | Written by | Read by |
|
|
57
|
+
|---|---|---|
|
|
58
|
+
| `crew.code`, `name`, `description`, `icon` | Build, from `design.yaml` | crew lists (Architect) |
|
|
59
|
+
| `crew.tier` | Build, from `design.yaml → crew.tier` | Runner (run header) |
|
|
60
|
+
| `pipeline.entry`, `steps_dir` | Build, always these two values | a reference for people; the Runner reads these two paths directly |
|
|
61
|
+
| `skills` | Build | Runner, Skills Engine |
|
|
62
|
+
| `data` | Build; the template designer appends | Runner |
|
|
63
|
+
| `fontes` (`caminho`, `para_que`) | Build, from `discovery.yaml → project_sources`; `/opencrew repair` | Runner (reads the sources at the start of the run), `conferir-fontes.mjs` |
|
|
64
|
+
| `agent_dependencies` | Build | Runner (Pre-Execution Agent Selection) |
|
|
65
|
+
| `max_review_cycles` | Build | Runner (Review Loops) |
|
|
66
|
+
| `entrega.destino` | `entregar.mjs --lembrar-destino` only | `entregar.mjs` |
|
|
67
|
+
|
|
68
|
+
- **`fontes`** is omitted only when the discovery found no project source.
|
|
69
|
+
- **`agent_dependencies`** is written when at least one agent can be left out of a run without
|
|
70
|
+
breaking another (for example, one writer per channel). Each key is an agent `id`; its value
|
|
71
|
+
lists the agents whose output it reads. When every agent is needed in every run, omit the
|
|
72
|
+
field: the Runner then runs all agents and shows no selection step.
|
|
73
|
+
- **`max_review_cycles`** — the Runner uses the value of the review step when the step declares
|
|
74
|
+
one, then this one, then 3.
|
|
75
|
+
- Old crews carry `name`, `code`, `description` and `tier` loose at the top level, without the
|
|
76
|
+
`crew:` block. Readers accept both; new crews use the block.
|
|
77
|
+
|
|
78
|
+
## pipeline.yaml
|
|
79
|
+
|
|
80
|
+
```yaml
|
|
81
|
+
steps:
|
|
82
|
+
- step: 1
|
|
83
|
+
file: "step-01-checkpoint-pauta.md" # relative to pipeline/steps
|
|
84
|
+
- step: 2
|
|
85
|
+
file: "step-02-redigir-ata.md"
|
|
86
|
+
- step: 3
|
|
87
|
+
file: "step-03-revisar.md"
|
|
88
|
+
- step: 4
|
|
89
|
+
file: "step-04-checkpoint-final.md"
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
The steps run in the order of the list. `step` is the number other steps refer to (`on_reject`);
|
|
93
|
+
without it, the number is the position in the list. Old crews write `file: steps/step-…md`;
|
|
94
|
+
readers accept both. Nothing else is read from this file.
|
|
95
|
+
|
|
96
|
+
## Step files
|
|
97
|
+
|
|
98
|
+
The frontmatter of `pipeline/steps/step-NN-{name}.md` says how the Runner executes the step.
|
|
99
|
+
|
|
100
|
+
**Creation step**
|
|
101
|
+
```yaml
|
|
102
|
+
---
|
|
103
|
+
execution: inline # inline | subagent
|
|
104
|
+
agent: rita-redacao # the agent id (see "Agent id")
|
|
105
|
+
format: documento-oficial # the kind of text this step produces (a best-practices id)
|
|
106
|
+
inputFile: crews/atas-do-conselho/output/pauta.md
|
|
107
|
+
outputFile: crews/atas-do-conselho/output/ata.md
|
|
108
|
+
---
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
**Review step** — the one with `on_reject`
|
|
112
|
+
```yaml
|
|
113
|
+
---
|
|
114
|
+
execution: inline
|
|
115
|
+
agent: vito-veredito
|
|
116
|
+
inputFile: crews/atas-do-conselho/output/ata.md
|
|
117
|
+
outputFile: crews/atas-do-conselho/output/revisao.md
|
|
118
|
+
on_reject: 2 # the number of the step the pipeline goes back to on a rejection
|
|
119
|
+
---
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
**Checkpoint**
|
|
123
|
+
```yaml
|
|
124
|
+
---
|
|
125
|
+
type: checkpoint
|
|
126
|
+
agent: rita-redacao # optional: skipped together with that agent
|
|
127
|
+
outputFile: crews/atas-do-conselho/output/pauta.md # optional: the user's answer is saved here
|
|
128
|
+
---
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
| Field | Rule |
|
|
132
|
+
|---|---|
|
|
133
|
+
| `execution` | `subagent` runs in the background; `inline` runs in the conversation. A step that publishes or sends is always `inline` |
|
|
134
|
+
| `agent` | the agent id |
|
|
135
|
+
| `format` | every step whose text is checked before the review (from the `on_reject` step up to the review) declares one; without it the writer does not get the guide of that kind of text and the checker looks in the file for pieces of a network (caption, post, blog title). A text to print, sign or file is `documento-oficial`; a text with no channel and no Word file (a proposal, a draft that becomes HTML or PDF, a plan) is `texto-livre`. Omit only for research, analysis and the review itself |
|
|
136
|
+
| `inputFile`, `outputFile` | always under `crews/{code}/output/`; never `pipeline/data/` |
|
|
137
|
+
| `model_tier` | `fast` or `powerful`, only on `subagent` steps. Express: `fast`. Standard: `fast` for research and data gathering, `powerful` for the rest. Full: `powerful`. Inline steps do not carry it |
|
|
138
|
+
| `side_effects: irreversible` | every step that publishes, posts or sends outside the project; such steps come after the review and the final approval |
|
|
139
|
+
| `on_reject` | marks the review step; its value is a step number |
|
|
140
|
+
| `max_review_cycles` | optional on the review step, when it must differ from the crew's |
|
|
141
|
+
| `skills_needed` | optional list of skills whose full instructions the step needs from the start |
|
|
142
|
+
| `type: checkpoint` | a pause for the user; no `execution` |
|
|
143
|
+
|
|
144
|
+
Every crew has a review step, followed by a final approval checkpoint. In the Express tier the
|
|
145
|
+
review step is done by the writer agent itself; Standard and Full have a dedicated reviewer agent.
|
|
146
|
+
|
|
147
|
+
## Agent id
|
|
148
|
+
|
|
149
|
+
One definition: the agent `id` is the file name without `.agent.md`
|
|
150
|
+
(`agents/rita-redacao.agent.md` → `rita-redacao`). The same text goes in the `id` column of
|
|
151
|
+
`crew-party.csv`, in `agent:` of the steps and in `agent_dependencies`. Old agent files carry
|
|
152
|
+
`id: "crews/{code}/agents/{id}"` in the frontmatter; readers use the last segment.
|
|
153
|
+
|
|
154
|
+
## crew-party.csv
|
|
155
|
+
|
|
156
|
+
```
|
|
157
|
+
id,displayName,title,icon,path,execution
|
|
158
|
+
rita-redacao,"Rita Redação","Redatora de Atas",📝,./agents/rita-redacao.agent.md,inline
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
`displayName` is the agent's `name:` (the two-word persona name), never the role. Quote any field
|
|
162
|
+
with a space or a comma.
|