{"_id":"@arvoretech/pi-recap","_rev":"2-f1acfa9277125b052529ccb43b84b780","name":"@arvoretech/pi-recap","dist-tags":{"latest":"1.0.1"},"versions":{"1.0.0":{"name":"@arvoretech/pi-recap","version":"1.0.0","keywords":["pi-package","pi","extension","recap","summary","session"],"author":{"name":"Arvore"},"license":"MIT","_id":"@arvoretech/pi-recap@1.0.0","maintainers":[{"name":"joao.barros.arvore","email":"joao.barros@arvore.com.br"},{"name":"rafsouza","email":"rafasouza@protonmail.com"},{"name":"pedro.adas","email":"pedro.adas@gmail.com"},{"name":"guilhermebs","email":"guilhermebscontact@gmail.com"},{"name":"ricardoraposorfox","email":"ricardorbxx1@gmail.com"},{"name":"jott4","email":"jvgcunha2002@gmail.com"},{"name":"vitor.piovezan","email":"vitor.piovezan@arvore.com.br"}],"homepage":"https://github.com/arvoreeducacao/arvore-pi-extensions#readme","bugs":{"url":"https://github.com/arvoreeducacao/arvore-pi-extensions/issues"},"pi":{"extensions":["./dist/index.js"]},"dist":{"shasum":"b44f9105a5c92e52cdbc1142ba53c9925c510b82","tarball":"https://registry.npmjs.org/@arvoretech/pi-recap/-/pi-recap-1.0.0.tgz","fileCount":18,"integrity":"sha512-dn4BOp4dzqf7Bg9VQE3F00P4E53b7UtSzZjAFbgkXvlP5YmAJGDadk+qL5yaHyuSBFfkLCp3x3hcHUg2+Szpaw==","signatures":[{"sig":"MEUCICzMFiDhygami74RuggqFcu099StZ7s6dNkD1ql3nw/7AiEA48737DKkGML2g+b8QI3iID68832jAK8Omi231KDxvd8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":29420},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","gitHead":"2a77fc53c52ed8fc6d6981c817a1716821dafc87","scripts":{"dev":"tsc --watch","lint":"tsc --noEmit","build":"tsc"},"_npmUser":{"name":"joao.barros.arvore","email":"joao.barros@arvore.com.br"},"repository":{"url":"git+https://github.com/arvoreeducacao/arvore-pi-extensions.git","type":"git","directory":"packages/recap"},"_npmVersion":"10.9.4","description":"PI extension that drafts a one-line recap of where you left off — on demand with /recap and automatically when you return to an idle session","directories":{},"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.3.0","@types/node":"^20.10.0","@earendil-works/pi-ai":"latest","@earendil-works/pi-coding-agent":"latest"},"peerDependencies":{"@earendil-works/pi-coding-agent":">=0.74.0"},"_npmOperationalInternal":{"tmp":"tmp/pi-recap_1.0.0_1783364397146_0.028812531462826474","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"@arvoretech/pi-recap","version":"1.0.1","description":"PI extension that drafts a one-line recap of where you left off — on demand with /recap and automatically when you return to an idle session","main":"dist/index.js","types":"dist/index.d.ts","type":"module","peerDependencies":{"@earendil-works/pi-coding-agent":">=0.74.0"},"devDependencies":{"@earendil-works/pi-coding-agent":"latest","@earendil-works/pi-ai":"latest","@types/node":"^20.10.0","typescript":"^5.3.0"},"pi":{"extensions":["./dist/index.js"]},"keywords":["pi-package","pi","extension","recap","summary","session"],"repository":{"type":"git","url":"git+https://github.com/arvoreeducacao/arvore-pi-extensions.git","directory":"packages/recap"},"author":{"name":"Arvore"},"license":"MIT","scripts":{"build":"tsc","dev":"tsc --watch","lint":"tsc --noEmit"},"_id":"@arvoretech/pi-recap@1.0.1","bugs":{"url":"https://github.com/arvoreeducacao/arvore-pi-extensions/issues"},"homepage":"https://github.com/arvoreeducacao/arvore-pi-extensions#readme","_integrity":"sha512-pNWbmdZP4v26A6ZoMbcAzClppMVUOD/KX1hRuL5l0oYKUup6RXzwD6XY+7BPzo1GZ7Z8yPQoEqTlgtZUWKn5YA==","_resolved":"/tmp/arvoretech-pi-recap-1.0.1.tgz","_from":"file:/tmp/arvoretech-pi-recap-1.0.1.tgz","_nodeVersion":"22.23.1","_npmVersion":"11.18.0","dist":{"integrity":"sha512-pNWbmdZP4v26A6ZoMbcAzClppMVUOD/KX1hRuL5l0oYKUup6RXzwD6XY+7BPzo1GZ7Z8yPQoEqTlgtZUWKn5YA==","shasum":"a9549a8885fa29eb00b7b6c38e0e5c7af4daa8c6","tarball":"https://registry.npmjs.org/@arvoretech/pi-recap/-/pi-recap-1.0.1.tgz","fileCount":18,"unpackedSize":29551,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@arvoretech%2fpi-recap@1.0.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQC0q4OoeFpKEeqYQm27bCKItxCo6LaSR81i9z34a8ykCAIgW/wC4psDB0MXH6Cuao5eV8mO0bx/IZ9q0yrAihbwPkg="}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:12738e7c-3a33-4567-9bd2-56f26784269b"}},"directories":{},"maintainers":[{"name":"joao.barros.arvore","email":"joao.barros@arvore.com.br"},{"name":"rafsouza","email":"rafasouza@protonmail.com"},{"name":"pedro.adas","email":"pedro.adas@gmail.com"},{"name":"guilhermebs","email":"guilhermebscontact@gmail.com"},{"name":"ricardoraposorfox","email":"ricardorbxx1@gmail.com"},{"name":"jott4","email":"jvgcunha2002@gmail.com"},{"name":"vitor.piovezan","email":"vitor.piovezan@arvore.com.br"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/pi-recap_1.0.1_1783555338574_0.3241973410549115"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-06T18:59:56.919Z","modified":"2026-07-09T00:02:19.134Z","1.0.0":"2026-07-06T18:59:57.290Z","1.0.1":"2026-07-09T00:02:18.712Z"},"bugs":{"url":"https://github.com/arvoreeducacao/arvore-pi-extensions/issues"},"author":{"name":"Arvore"},"license":"MIT","homepage":"https://github.com/arvoreeducacao/arvore-pi-extensions#readme","keywords":["pi-package","pi","extension","recap","summary","session"],"repository":{"type":"git","url":"git+https://github.com/arvoreeducacao/arvore-pi-extensions.git","directory":"packages/recap"},"description":"PI extension that drafts a one-line recap of where you left off — on demand with /recap and automatically when you return to an idle session","maintainers":[{"name":"joao.barros.arvore","email":"joao.barros@arvore.com.br"},{"name":"rafsouza","email":"rafasouza@protonmail.com"},{"name":"pedro.adas","email":"pedro.adas@gmail.com"},{"name":"guilhermebs","email":"guilhermebscontact@gmail.com"},{"name":"ricardoraposorfox","email":"ricardorbxx1@gmail.com"},{"name":"jott4","email":"jvgcunha2002@gmail.com"},{"name":"vitor.piovezan","email":"vitor.piovezan@arvore.com.br"}],"readme":"# @arvoretech/pi-recap\n\nDrafts a one-line recap of where you left off in a Pi session — inspired by Claude Code's session recap.\n\n## What it does\n\n- **On demand:** run `/recap` any time to get a 1–2 line summary of what was being worked on, what's done, and the next pending step. Useful before a commit, before opening a PR, or after a long session.\n- **Automatically on return:** when you come back to a session that has been idle for a while, Pi drafts the recap and shows it before your next turn — so you don't have to scroll back to rebuild context.\n\nThe recap is generated by a background model call (via the host's `completeSimple`, same mechanism as `smart-context`) using the current session model. It's best-effort: if it can't run, it silently no-ops and never blocks your turn.\n\n## Auto-recap trigger\n\nPi has no native terminal focus/blur event, so instead of Claude Code's \"unfocused ≥ 3 min\" signal this extension uses **idle wall-clock time** since the last completed turn:\n\n1. At least **3 minutes** elapsed since the last `agent_end`.\n2. Session has at least **3 user turns** behind it.\n3. **Never twice in a row** — after a recap is shown, the next one waits for fresh activity.\n4. Interactive mode only (`ctx.hasUI`); skipped in print/headless mode.\n\nThe practical effect (a recap waiting when you return) is the same; the trigger is time-based rather than focus-based.\n\n## Configuration\n\nAuto-recap is on by default. Disable it with an env var:\n\n```bash\nexport PI_ENABLE_AWAY_RECAP=0\n```\n\n`/recap` always works regardless of this setting.\n\n## Install\n\n`.pi/settings.json`:\n\n```json\n{\n  \"packages\": [\"npm:@arvoretech/pi-recap\"]\n}\n```\n","readmeFilename":"README.md"}