@igor-guari/pi-skill-implement 0.0.0-stage → 1.0.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/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2024 Matt Pocock
4
+ Copyright (c) 2025 Igor Guariroba
5
+
6
+ Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ of this software and associated documentation files (the "Software"), to deal
8
+ in the Software without restriction, including without limitation the rights
9
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ copies of the Software, and to permit persons to whom the Software is
11
+ furnished to do so, subject to the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be included in all
14
+ copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,53 @@
1
- # Temporary Holding Version
1
+ # pi-skill-implement
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ [![Pi Package](https://img.shields.io/badge/pi--package-skill-blue)](https://github.com/IgorGuariroba/pi-skill-implement)
4
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)
5
+
6
+ **implement** skill for the **[Pi coding agent](https://pi.dev)**, adapted from Matt Pocock's Engineering Skills.
7
+
8
+ > Implement a piece of work based on a spec or set of tickets.
9
+
10
+ ---
11
+
12
+ ## Installation
13
+
14
+ Install directly into Pi using `pi install`:
15
+
16
+ ```bash
17
+ pi install git:github.com/IgorGuariroba/pi-skill-implement
18
+ ```
19
+
20
+ Or clone into your local/global skills directory:
21
+
22
+ ```bash
23
+ # Global Pi skills directory:
24
+ git clone https://github.com/IgorGuariroba/pi-skill-implement.git ~/.pi/agent/skills/implement
25
+
26
+ # Or Agent Skills standard path:
27
+ git clone https://github.com/IgorGuariroba/pi-skill-implement.git ~/.agents/skills/implement
28
+ ```
29
+
30
+ ---
31
+
32
+ ## Usage
33
+
34
+ Trigger it explicitly in your session:
35
+
36
+ ```text
37
+ /skill:implement
38
+ ```
39
+
40
+ Or let Pi automatically route to it based on conversation context and need.
41
+
42
+ ---
43
+
44
+ ## Credits
45
+
46
+ - **Original concept & methodology**: [Matt Pocock](https://github.com/mattpocock)
47
+ - **Adapted for Pi Agent**: [Igor Guariroba](https://github.com/IgorGuariroba)
48
+
49
+ ---
50
+
51
+ ## License
52
+
53
+ [MIT](LICENSE)
package/SKILL.md ADDED
@@ -0,0 +1,23 @@
1
+ ---
2
+ name: implement
3
+ description: Implement a piece of work based on a spec or set of tickets.
4
+ disable-model-invocation: true
5
+ license: MIT
6
+ metadata:
7
+ author: Matt Pocock
8
+ adapted_by: Igor Guariroba
9
+ version: 1.0.0
10
+ ---
11
+
12
+
13
+ Implement the work described by the user in the spec or tickets. Before editing, record the starting HEAD and existing staged/unstaged/untracked changes. Preserve the user's work and use that starting SHA as the review base.
14
+
15
+ Read `../tdd/SKILL.md` and apply it where possible, at pre-agreed seams. Resolve skill references relative to this skill directory; Pi loads their instructions through file reads, not a Skill tool.
16
+
17
+ Work in the current Pi session by default. When independent work benefits from delegation, read `references/pi-workers.md` and use fresh Pi processes; each concurrent writer needs its own worktree. Herdr is optional under that guide's conditions.
18
+
19
+ Run typechecking regularly, single test files regularly, and the full test suite once at the end.
20
+
21
+ Once implemented and validated, read `../code-review/SKILL.md` to review both your commits and your uncommitted changes against that SHA. Fix actionable findings and rerun the affected checks before concluding.
22
+
23
+ Commit only your work to the current branch. Report the commit, acceptance criteria covered, checks run and any remaining blockers; completion requires every requested criterion to be accounted for.
package/package.json CHANGED
@@ -1,6 +1,29 @@
1
1
  {
2
2
  "name": "@igor-guari/pi-skill-implement",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "1.0.0",
4
+ "description": "Implement a piece of work based on a spec or set of tickets.",
5
+ "keywords": [
6
+ "pi-package",
7
+ "pi-skill",
8
+ "pi",
9
+ "implement",
10
+ "engineering-skills"
11
+ ],
12
+ "author": "Igor Guariroba",
13
+ "license": "MIT",
14
+ "repository": {
15
+ "type": "git",
16
+ "url": "git+https://github.com/IgorGuariroba/pi-skill-implement.git"
17
+ },
18
+ "homepage": "https://github.com/IgorGuariroba/pi-skill-implement#readme",
19
+ "pi": {
20
+ "skills": [
21
+ "."
22
+ ]
23
+ },
24
+ "files": [
25
+ "SKILL.md",
26
+ "*.md",
27
+ "references/"
28
+ ]
29
+ }
@@ -0,0 +1,33 @@
1
+ # Workers no Pi
2
+
3
+ Referência compartilhada para delegação em processos Pi independentes. Um **worker** é outro processo Pi com contexto próprio; o coordenador continua responsável pelo resultado.
4
+
5
+ ## Preparar e executar
6
+
7
+ 1. Confira `pi --help` para as opções da instalação. Crie um diretório de execução fora do repositório (`mktemp -d`) e um prompt por tarefa. Registre papel, cwd absoluto, escopo permitido, referências absolutas à spec/tickets/skills, resultado esperado e critério de conclusão. Compartilhe ponteiros, não o histórico da conversa.
8
+ 2. Execute cada tarefa com cwd explícito e contexto novo. Exemplo de comando para `process_start` (substitua os caminhos):
9
+
10
+ ```bash
11
+ cd /absolute/worktree && pi --print --no-session @/absolute/run/task.md > /absolute/run/result.md 2> /absolute/run/stderr.log
12
+ ```
13
+
14
+ Use o modelo/provider solicitado, se houver; caso contrário, mantenha os defaults configurados. `--no-session` evita persistir/reutilizar a conversa; configurações e instruções do projeto continuam disponíveis. Carregue outras skills lendo seus `SKILL.md` por caminho absoluto no prompt. Pi não precisa de uma ferramenta `Skill` para isso.
15
+ 3. Inicie tarefas independentes com chamadas separadas de `process_start`, cada uma com `watch`: `success: {exitCode: {eq: 0}}`, `failure: {exitCode: {ne: 0}}` e `timeoutMs` finito conforme o trabalho (por exemplo, 600000 para revisão). Após registrar os watches, informe a espera e encerre o turno. Os resultados chegam automaticamente; use `process_logs` para diagnóstico, não polling manual.
16
+ 4. Ao receber a conclusão, leia resultado e stderr e confira os artefatos. Exit code zero comprova execução, não cumprimento da tarefa. Uma resposta sem evidência, com bloqueio ou trabalho parcial é incompleta. Em timeout, inspecione e pare o processo antes de repetir ou liberar seu worktree. Preserve prompts, resultados e logs até entregar o trabalho.
17
+
18
+ Se `process_start`/watch não estiverem disponíveis, escolha o caminho Herdr abaixo quando aplicável; caso contrário, execute tarefas sequencialmente com timeout explícito na ferramenta disponível. Registre a perda de paralelismo. Falha de autenticação ou diálogo que exija interação deve ser reportado ao usuário; não invente aprovações nem transfira segredos em prompts.
19
+
20
+ ## Contratos e isolamento
21
+
22
+ - **Implementação:** um worktree e branch exclusivos por worker escritor. O resultado informa commit(s), critérios atendidos, comandos/testes e resultados, pendências e status Git. Só aceite conclusão após conferir esses itens.
23
+ - **Revisão/exploração:** leitura apenas do código; saída final em stdout, capturada pelo coordenador. Autorize escrita de notas externas apenas quando a tarefa exigir. Com `bash`, uma instrução de leitura não é sandbox: mantenha o escopo explícito e verifique o status Git antes/depois. Para leitura estrita sem shell, a instalação oferece `--tools read,grep,find,ls --no-mcp`; o coordenador pode fornecer diff e commits em arquivos externos.
24
+ - **Integração:** um único escritor na branch de integração. O coordenador serializa merges; workers de tickets não atualizam essa branch. Nenhum reset destrutivo ou limpeza forçada de alterações alheias.
25
+ - **Conclusão:** o coordenador valida commits, testes e critérios de aceitação. Estado de processo/pane não substitui essa validação.
26
+
27
+ ## Herdr: acompanhamento visível
28
+
29
+ Quando o usuário mencionar/pedir Herdr e `HERDR_ENV=1`, leia `../skills/herdr/SKILL.md` (relativo a este arquivo) e consulte a CLI instalada antes de controlar panes. Fora do Herdr, continue com processos Pi; Herdr não é pré-requisito.
30
+
31
+ Use os comandos documentados de pane para executar o mesmo comando `pi --print --no-session` em um shell disponível, preservando foco e cwd explícito. Capture saída, stderr e exit code em arquivos exclusivos fora do repositório. Aguarde via `watch_create` com polling barato do arquivo de exit code, sucesso zero, falha não zero e timeout finito. Publique esse arquivo apenas depois que o Pi terminar. Após registrar o watch, encerre o turno. Em timeout, inspecione o pane antes de repetir.
32
+
33
+ Se preferir um Pi interativo reconhecido por Herdr, confira primeiro se a CLI instalada oferece esse kind e siga a skill Herdr para iniciar, enviar prompt e aguardar. Cada tarefa independente começa em um processo/sessão nova. `idle`/`done` indica estado da interface, não aceitação do trabalho: leia a resposta e valide os artefatos. Crie workspaces/tabs ou outra topologia somente quando o usuário os solicitar; encerre apenas recursos criados para esta execução.