logsayer 0.6.0__tar.gz
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.
- logsayer-0.6.0/.gitignore +15 -0
- logsayer-0.6.0/AGENTS.md +67 -0
- logsayer-0.6.0/CHANGELOG.md +56 -0
- logsayer-0.6.0/LICENSE +21 -0
- logsayer-0.6.0/PKG-INFO +156 -0
- logsayer-0.6.0/README.md +126 -0
- logsayer-0.6.0/docs/01_global/mission.md +19 -0
- logsayer-0.6.0/docs/02_technical/decisions.md +23 -0
- logsayer-0.6.0/docs/02_technical/tech-stack.md +22 -0
- logsayer-0.6.0/docs/03_process/definition-of-ready.md +18 -0
- logsayer-0.6.0/docs/03_process/merge-checklist.md +21 -0
- logsayer-0.6.0/docs/04_user_stories/HU-01/README.md +24 -0
- logsayer-0.6.0/docs/04_user_stories/HU-02/README.md +21 -0
- logsayer-0.6.0/docs/04_user_stories/HU-03/README.md +21 -0
- logsayer-0.6.0/docs/04_user_stories/HU-04/README.md +19 -0
- logsayer-0.6.0/docs/04_user_stories/HU-05/README.md +21 -0
- logsayer-0.6.0/docs/05_agile_methodology/metodologia.md +27 -0
- logsayer-0.6.0/docs/06_audits/audit_2026-09-24.md +29 -0
- logsayer-0.6.0/docs/06_audits/audit_2026-09-24.prompt.md +11 -0
- logsayer-0.6.0/docs/logbooks/00_index.md +10 -0
- logsayer-0.6.0/docs/logbooks/logbook_dogfooding_01.md +5 -0
- logsayer-0.6.0/docs/logbooks/logbook_fase1_01.md +5 -0
- logsayer-0.6.0/docs/logbooks/logbook_fase2_01.md +6 -0
- logsayer-0.6.0/docs/logbooks/logbook_fase3_01.md +4 -0
- logsayer-0.6.0/docs/logbooks/logbook_fase4_01.md +4 -0
- logsayer-0.6.0/docs/logbooks/logbook_fase5_01.md +5 -0
- logsayer-0.6.0/docs/project_state.md +21 -0
- logsayer-0.6.0/examples/hello-logsayer/README.md +187 -0
- logsayer-0.6.0/logsayer.toml +4 -0
- logsayer-0.6.0/logsayer_especificacion_maestra.md +293 -0
- logsayer-0.6.0/opencode.json +4 -0
- logsayer-0.6.0/prompts_bootstrap_framework.md +169 -0
- logsayer-0.6.0/pyproject.toml +72 -0
- logsayer-0.6.0/src/logsayer/__init__.py +3 -0
- logsayer-0.6.0/src/logsayer/__main__.py +4 -0
- logsayer-0.6.0/src/logsayer/adapters/__init__.py +10 -0
- logsayer-0.6.0/src/logsayer/adapters/base.py +21 -0
- logsayer-0.6.0/src/logsayer/adapters/claude.py +22 -0
- logsayer-0.6.0/src/logsayer/adapters/generate.py +39 -0
- logsayer-0.6.0/src/logsayer/adapters/opencode.py +22 -0
- logsayer-0.6.0/src/logsayer/adapters/registry.py +38 -0
- logsayer-0.6.0/src/logsayer/cli.py +311 -0
- logsayer-0.6.0/src/logsayer/config.py +62 -0
- logsayer-0.6.0/src/logsayer/core/__init__.py +1 -0
- logsayer-0.6.0/src/logsayer/core/audit.py +81 -0
- logsayer-0.6.0/src/logsayer/core/checks.py +22 -0
- logsayer-0.6.0/src/logsayer/core/fremen.py +90 -0
- logsayer-0.6.0/src/logsayer/core/logbook.py +116 -0
- logsayer-0.6.0/src/logsayer/core/paths.py +30 -0
- logsayer-0.6.0/src/logsayer/core/project.py +84 -0
- logsayer-0.6.0/src/logsayer/core/specs.py +39 -0
- logsayer-0.6.0/src/logsayer/core/suk.py +155 -0
- logsayer-0.6.0/src/logsayer/scaffold.py +104 -0
- logsayer-0.6.0/src/logsayer/templates/00_index.md.j2 +4 -0
- logsayer-0.6.0/src/logsayer/templates/AGENTS.md.j2 +29 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/claude/mentat.md.j2 +16 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/claude/navigator.md.j2 +16 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/claude/reverend-mother.md.j2 +17 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/claude/truthsayer.md.j2 +17 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/opencode/mentat.md.j2 +37 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/opencode/navigator.md.j2 +31 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/opencode/reverend-mother.md.j2 +35 -0
- logsayer-0.6.0/src/logsayer/templates/adapters/opencode/truthsayer.md.j2 +35 -0
- logsayer-0.6.0/src/logsayer/templates/audit_prompt.md.j2 +11 -0
- logsayer-0.6.0/src/logsayer/templates/audit_report.md.j2 +20 -0
- logsayer-0.6.0/src/logsayer/templates/hu.md.j2 +11 -0
- logsayer-0.6.0/src/logsayer/templates/logsayer.toml.j2 +4 -0
- logsayer-0.6.0/src/logsayer/templates/project_state.md.j2 +17 -0
- logsayer-0.6.0/tests/conftest.py +20 -0
- logsayer-0.6.0/tests/test_adapters.py +79 -0
- logsayer-0.6.0/tests/test_checks.py +114 -0
- logsayer-0.6.0/tests/test_cli.py +66 -0
- logsayer-0.6.0/tests/test_cli_commands.py +133 -0
- logsayer-0.6.0/tests/test_config.py +47 -0
- logsayer-0.6.0/tests/test_logbook.py +70 -0
- logsayer-0.6.0/tests/test_paths.py +13 -0
- logsayer-0.6.0/tests/test_project.py +29 -0
- logsayer-0.6.0/tests/test_scaffold.py +120 -0
- logsayer-0.6.0/tests/test_specs.py +34 -0
logsayer-0.6.0/AGENTS.md
ADDED
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# AGENTS.md — logsayer
|
|
2
|
+
|
|
3
|
+
CLI open source en Python que scaffoldea y coordina un sistema de 5 capas documentales para proyectos con agentes IA (Especificación, Estado, Bitácora, Verificación y Proceso). Stack: Python 3.11+, Typer, Jinja2, TOML (`logsayer.toml`), empaquetado con `pyproject.toml` + hatchling, distribución vía PyPI (`uv tool install` / `pipx`).
|
|
4
|
+
|
|
5
|
+
## Idioma y tono
|
|
6
|
+
- Responder siempre en español rioplatense, informal ("vos"). Nunca en inglés, aunque el código, logs o skills estén en inglés.
|
|
7
|
+
- La superficie pública del framework (rutas `docs/`, comandos, README) va en inglés; el contenido generado puede ir en español.
|
|
8
|
+
|
|
9
|
+
## Comandos del proyecto
|
|
10
|
+
- Instalar: `uv tool install .`
|
|
11
|
+
- Tests: `python -m pytest -q` (entorno: `.venv`)
|
|
12
|
+
- Lint/formato: `ruff check src tests`
|
|
13
|
+
- Tipado: `mypy src` (strict)
|
|
14
|
+
|
|
15
|
+
## Setup / gotchas
|
|
16
|
+
- Fuente de verdad absoluta: `logsayer_especificacion_maestra.md`. Reemplaza y consolida toda decisión previa (capas, roadmap, tema Dune, bot vs subagente, umbrales, estrategia multi-agente).
|
|
17
|
+
- `prompts_bootstrap_framework.md` es el flujo de prompts de bootstrap: define la constitución y las features del propio CLI.
|
|
18
|
+
- No inventar comandos, config ni estructura que no estén en la especificación maestra: verificar ahí antes de asumir.
|
|
19
|
+
- `__version__` vive en `src/logsayer/__init__.py` y debe seguir el `version` de `pyproject.toml`.
|
|
20
|
+
|
|
21
|
+
## Arquitectura del proyecto
|
|
22
|
+
- El CLI genera para proyectos usuarios: `docs/01_global/`, `docs/02_technical/`, `docs/03_process/`, `docs/04_user_stories/HU-XX/`, `docs/05_agile_methodology/`, `docs/06_audits/`; más `docs/project_state.md` (Capa 2) y `docs/logbooks/logbook_<fase>_NN.md` con `00_index.md` (Capa 3) — ver `src/logsayer/scaffold.py`.
|
|
23
|
+
- Motor único `logsayer/core/` + adaptadores por agente (`logsayer/adapters/<agente>/`) que solo traducen la convención de archivos nativa de cada herramienta e invocan comandos del CLI.
|
|
24
|
+
- Comandos con alias plano: `logsayer truthsayer audit run` ≡ `logsayer audit run`.
|
|
25
|
+
|
|
26
|
+
## Fuente de verdad
|
|
27
|
+
- `logsayer_especificacion_maestra.md` es la única fuente de verdad (nombre, 5 capas, estructura, umbrales, comandos, roadmap, stack, riesgos conocidos, disclaimer).
|
|
28
|
+
- Si el código real contradice la especificación, avisar antes de asumir.
|
|
29
|
+
|
|
30
|
+
## Reglas globales (no duplicar, ya cargadas vía config global)
|
|
31
|
+
- Git/git flow, anti-alucinación, APA y SOLID viven en `~/.config/opencode/rules/`. No copiarlas acá: si este repo necesita algo distinto, documentarlo JUSTIFICANDO la diferencia.
|
|
32
|
+
|
|
33
|
+
## Reglas del proyecto
|
|
34
|
+
- No duplicar lógica del framework dentro de los templates/adaptadores que genera el CLI: todo juicio vive en `logsayer/core/`, los archivos generados son wrappers finos (spec §6).
|
|
35
|
+
|
|
36
|
+
## Coordinación con docs/ (dogfooding)
|
|
37
|
+
Este repo usa logsayer sobre sí mismo (marco de sesiones, spec §7). Los umbrales viven en `logsayer.toml`; esto tiene que reflejarlos (lo verifica `logsayer fremen verify`).
|
|
38
|
+
|
|
39
|
+
### Al iniciar sesión
|
|
40
|
+
1. Leer `docs/project_state.md` (Capa 2, obligatorio, siempre).
|
|
41
|
+
2. Si el contador de HUs cerradas desde la última auditoría es >= 3 HUs, proponer auditoría (Decidora de Verdad) antes de tomar tarea nueva.
|
|
42
|
+
3. NO leer `docs/logbooks/` completa — solo `docs/logbooks/00_index.md` bajo demanda.
|
|
43
|
+
|
|
44
|
+
### Durante la sesión
|
|
45
|
+
- Si el uso de contexto supera el 70%, proponer cierre de sesión antes de tomar más tareas.
|
|
46
|
+
- Trabajar cada HU leyendo solo su carpeta en `docs/04_user_stories/`.
|
|
47
|
+
- Decisión de arquitectura nueva → candidata a entrada de logbook y a `docs/02_technical/decisions.md`; nunca se escribe directo en el estado.
|
|
48
|
+
|
|
49
|
+
### Al cerrar sesión o commit (requiere aprobación previa)
|
|
50
|
+
- Sobrescribir `docs/project_state.md` (snapshot, no acumulativo).
|
|
51
|
+
- Append en el logbook activo `docs/logbooks/logbook_dogfooding_NN.md`.
|
|
52
|
+
- Si el logbook activo supera las 400 líneas, crear `NN+1` y actualizar `00_index.md`.
|
|
53
|
+
- Si se cerró una HU, incrementar el contador de auditoría.
|
|
54
|
+
|
|
55
|
+
### Auditoría (Decidora de Verdad)
|
|
56
|
+
- Disparador: contador >= 3 HUs. Ejecutar `logsayer audit run`.
|
|
57
|
+
- Compara `docs/04_user_stories/` contra el código real; resultado en `docs/06_audits/audit_<fecha>.md`.
|
|
58
|
+
- Resetear el contador tras la aprobación.
|
|
59
|
+
|
|
60
|
+
## Estado actual
|
|
61
|
+
- Dogfooding del marco activo: logsayer se gobierna a sí mismo (docs/ bootstrappeado con `init --here` en modo adopt, HUs reales HU-01..05 en `docs/04_user_stories/`, logbooks por fase, auditoría 2026-09-24 aprobada y contador reseteado).
|
|
62
|
+
- Versión actual: `0.6.0` (sync entre `pyproject.toml` y `src/logsayer/__init__.py`). El modo adopt de `init --here` (spec §5) cerró la deuda de repositorios existentes, verificado con tests + check + fremen.
|
|
63
|
+
- Fases 0-5 del roadmap cerradas. Pendientes: publicar en PyPI (token de `3m1l10j4v13r4qu1n0`), fase 3 restante (copilot/cursor/gemini/hermes por demanda), fase 6 (comunidad: presets, más agentes).
|
|
64
|
+
- `main` tiene solo el bootstrap; feature branches convergen en `develop`; releases con tag semver (`v0.1.0`..`v0.6.0`).
|
|
65
|
+
|
|
66
|
+
## Memoria del proyecto
|
|
67
|
+
- [x] Dogfooding del propio repo: `docs/` bootstrappeado sobre sí mismo; `docs/project_state.md` (Capa 2), logbooks por fase (Capa 3) y auditoría (Capa 4) mantenidos en el marco de sesiones.
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
Todos los cambios notables de logsayer quedan documentados acá, por versión, en orden cronológico inverso. Formato [Keep a Changelog](https://keepachangelog.com/es/1.1.0/), versionado [semver](https://semver.org/lang/es/).
|
|
4
|
+
|
|
5
|
+
## [Unreleased]
|
|
6
|
+
|
|
7
|
+
## [0.6.0] — 2026-09-24
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
- **Modo adopt en `logsayer init --here`** (spec §5): scaffoldea sobre un repositorio existente — crea lo que falta (capa de `docs/`, `logsayer.toml`) y **no sobrescribe** archivos ya presentes (`AGENTS.md`, estado, índice). Cierra la deuda entre la especificación y el código.
|
|
11
|
+
- **Dogfooding activo**: el propio repo ahora se gobierna con logsayer (Capa 1-5 en `docs/`), con HUs reales HU-01..05, logbooks por fase y auditoría 2026-09-24 aprobada.
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
- `scaffold()` acepta `adopt` y devuelve los paths escritos; el CLI reporta qué se preservó y qué se generó.
|
|
15
|
+
|
|
16
|
+
## [0.5.0] — 2026-09-24
|
|
17
|
+
|
|
18
|
+
### Added
|
|
19
|
+
- `README.md` público (inglés) con el disclaimer Dune obligatorio (spec §12).
|
|
20
|
+
- `LICENSE` MIT.
|
|
21
|
+
- `examples/hello-logsayer/` — sesión real documentada con salidas del CLI.
|
|
22
|
+
- Empaquetado listo para PyPI: `readme`, `authors`, `keywords`, clasificadores y URLs en `pyproject.toml`.
|
|
23
|
+
|
|
24
|
+
## [0.4.0] — 2026-09-24
|
|
25
|
+
|
|
26
|
+
### Added
|
|
27
|
+
- **Suk Doctor** (`logsayer suk doctor` / alias `logsayer check`): verificación mecánica determinística — marcadores de raíz, estructura de capas, estado, índice de bitácora, ubicación de HUs y detección de capas mezcladas. Exit code 1 ante fallas.
|
|
28
|
+
- **Fremen** (`logsayer fremen verify` / alias `logsayer process check`): estado documentado, proceso desplegado, acuerdo de coordinación y Definition of Ready.
|
|
29
|
+
|
|
30
|
+
## [0.3.0] — 2026-09-24
|
|
31
|
+
|
|
32
|
+
### Added
|
|
33
|
+
- **`logsayer agent add <opencode|claude>`**: genera subagentes por rol (mentat, navigator, reverend-mother, truthsayer) como wrappers finos que invocan al CLI (motor único, spec §6).
|
|
34
|
+
|
|
35
|
+
## [0.2.0] — 2026-09-24
|
|
36
|
+
|
|
37
|
+
### Added
|
|
38
|
+
- **Comandos core** con alias plano (spec §13): `spec new` (template mínimo de HU), `state show`, `log add` con partición automática, `log index`, `audit run` y `audit status`.
|
|
39
|
+
|
|
40
|
+
### Changed
|
|
41
|
+
- Registro de comandos bajo grupo de rol **y** con alias plano en la raíz.
|
|
42
|
+
|
|
43
|
+
## [0.1.0] — 2026-09-24
|
|
44
|
+
|
|
45
|
+
### Added
|
|
46
|
+
- **`logsayer init <project-name>`** y `--here`: scaffoldea `docs/` con las 7 carpetas de capas, `AGENTS.md`, `project_state.md` e índice de bitácora.
|
|
47
|
+
- **`logsayer.toml`** con los umbrales (spec §4): `session_close_context_threshold = 0.70`, `bitacora_max_lines = 400`, `audit_threshold_hus = 3`.
|
|
48
|
+
- Valida slug y destino vacío; empaquetado hatchling (`pyproject.toml`).
|
|
49
|
+
|
|
50
|
+
[Unreleased]: https://github.com/3m1l10j4v13r4qu1n0/logsayer/compare/v0.6.0...HEAD
|
|
51
|
+
[0.6.0]: https://github.com/3m1l10j4v13r4qu1n0/logsayer/compare/v0.5.0...v0.6.0
|
|
52
|
+
[0.5.0]: https://github.com/3m1l10j4v13r4qu1n0/logsayer/compare/v0.4.0...v0.5.0
|
|
53
|
+
[0.4.0]: https://github.com/3m1l10j4v13r4qu1n0/logsayer/compare/v0.3.0...v0.4.0
|
|
54
|
+
[0.3.0]: https://github.com/3m1l10j4v13r4qu1n0/logsayer/compare/v0.2.0...v0.3.0
|
|
55
|
+
[0.2.0]: https://github.com/3m1l10j4v13r4qu1n0/logsayer/compare/v0.1.0...v0.2.0
|
|
56
|
+
[0.1.0]: https://github.com/3m1l10j4v13r4qu1n0/logsayer/releases/tag/v0.1.0
|
logsayer-0.6.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Emilio Javier Aquino
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
logsayer-0.6.0/PKG-INFO
ADDED
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: logsayer
|
|
3
|
+
Version: 0.6.0
|
|
4
|
+
Summary: CLI que extiende el patron spec-driven con estado, bitacora y verificacion continua de que lo construido sigue siendo lo especificado.
|
|
5
|
+
Project-URL: Homepage, https://github.com/3m1l10j4v13r4qu1n0/logsayer
|
|
6
|
+
Project-URL: Repository, https://github.com/3m1l10j4v13r4qu1n0/logsayer
|
|
7
|
+
Project-URL: Issues, https://github.com/3m1l10j4v13r4qu1n0/logsayer/issues
|
|
8
|
+
Author-email: Emilio Javier Aquino <aquinoemiliojavier@gmail.com>
|
|
9
|
+
License: MIT
|
|
10
|
+
License-File: LICENSE
|
|
11
|
+
Keywords: agents,ai,cli,documentation,logbook,scaffolding,spec-driven,state,verification
|
|
12
|
+
Classifier: Development Status :: 4 - Beta
|
|
13
|
+
Classifier: Environment :: Console
|
|
14
|
+
Classifier: Intended Audience :: Developers
|
|
15
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
16
|
+
Classifier: Operating System :: OS Independent
|
|
17
|
+
Classifier: Programming Language :: Python :: 3
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
21
|
+
Classifier: Topic :: Software Development :: Documentation
|
|
22
|
+
Requires-Python: >=3.11
|
|
23
|
+
Requires-Dist: jinja2>=3.1
|
|
24
|
+
Requires-Dist: typer>=0.12
|
|
25
|
+
Provides-Extra: dev
|
|
26
|
+
Requires-Dist: mypy>=1.11; extra == 'dev'
|
|
27
|
+
Requires-Dist: pytest>=8.0; extra == 'dev'
|
|
28
|
+
Requires-Dist: ruff>=0.6; extra == 'dev'
|
|
29
|
+
Description-Content-Type: text/markdown
|
|
30
|
+
|
|
31
|
+
# logsayer
|
|
32
|
+
|
|
33
|
+
> **Spec-kit tells you what to build. logsayer tells you where you stand, how you got there, and whether what you built is still what you said you would build.**
|
|
34
|
+
|
|
35
|
+
A Python CLI that scaffolds and coordinates a 5-layer documentary system for AI-agent projects: Specification, State, Logbook, Verification (mechanical + semantic), and Process.
|
|
36
|
+
|
|
37
|
+
Everything the agent needs to know about a project is written down by the same system that uses it — each layer answers one question, each document lives in exactly one layer, and every judgment lives in the CLI, not in the generated files.
|
|
38
|
+
|
|
39
|
+
## Disclaimer (Dune homage)
|
|
40
|
+
|
|
41
|
+
> This project uses names and concepts from Frank Herbert's *Dune* saga exclusively as a thematic reference and role metaphor. It is not affiliated with, sponsored by, or officially associated with Herbert Properties LLC, Legendary Entertainment, or any rights holders of the franchise. No art, logos, or protected material is reproduced — only concept/role names as a design analogy.
|
|
42
|
+
|
|
43
|
+
## Why logsayer
|
|
44
|
+
|
|
45
|
+
The spec-driven pattern (as popularized by GitHub Spec Kit) governs the *first* generation of code. After that, its authority over the code is by convention, not verification. logsayer closes the loop that pattern leaves open:
|
|
46
|
+
|
|
47
|
+
- **State continuity** between sessions — an anchor snapshot the agent reads (and only that) at session start.
|
|
48
|
+
- **A partitioned, append-only logbook** for the *"why"* of past decisions.
|
|
49
|
+
- **A mechanical + semantic verification loop** that checks whether the code still matches the spec — both structurally and in meaning.
|
|
50
|
+
- **Multi-agent coordination** through the standard `AGENTS.md` convention, with thin native adapters per tool (opencode and Claude Code today).
|
|
51
|
+
|
|
52
|
+
## The 5 layers
|
|
53
|
+
|
|
54
|
+
| # | Layer | Question it answers | Dune role |
|
|
55
|
+
|---|-------|--------------------|-----------|
|
|
56
|
+
| 1 | Specification (normative) | What must be built? | Mentat |
|
|
57
|
+
| 2 | State (anchor) | Where is the project right now? | Guild Navigator |
|
|
58
|
+
| 3 | Logbook (historical) | How did we get here, and why? | Reverend Mother |
|
|
59
|
+
| 4 | Verification | Does what was built still match the spec? | Suk Doctor (mechanical) + Truthsayer (semantic) |
|
|
60
|
+
| 5 | Process (operational) | How do we work here? | Fremen |
|
|
61
|
+
|
|
62
|
+
Every layer has a plain-English alias, so you can use logsayer without knowing any of the lore.
|
|
63
|
+
|
|
64
|
+
## Installation
|
|
65
|
+
|
|
66
|
+
Requires Python 3.11+.
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
uv tool install logsayer
|
|
70
|
+
# or
|
|
71
|
+
pipx install logsayer
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## Quick start
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
# 1. Scaffold a new project
|
|
78
|
+
logsayer init my-project
|
|
79
|
+
cd my-project
|
|
80
|
+
|
|
81
|
+
# 2. Write the spec for a user story
|
|
82
|
+
logsayer spec new HU-01
|
|
83
|
+
|
|
84
|
+
# 3. Add an agent adapter (opencode, claude)
|
|
85
|
+
logsayer agent add opencode
|
|
86
|
+
|
|
87
|
+
# 4. Start a session: check state, work the story
|
|
88
|
+
logsayer state show
|
|
89
|
+
# ... implement HU-01 ...
|
|
90
|
+
|
|
91
|
+
# 5. Close the session: log it, audit when threshold is hit
|
|
92
|
+
logsayer log add "HU-01 done: API + tests"
|
|
93
|
+
logsayer check # mechanical: structure, no mixed layers
|
|
94
|
+
logsayer audit run # semantic: spec vs real code report
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
For an existing project:
|
|
98
|
+
|
|
99
|
+
```bash
|
|
100
|
+
logsayer init --here
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
## Commands
|
|
104
|
+
|
|
105
|
+
| Command | Dune alias | Layer | Purpose |
|
|
106
|
+
|---------|-----------|-------|---------|
|
|
107
|
+
| `logsayer init [name]` | — | scaffold | Creates `docs/` + `AGENTS.md` + `logsayer.toml` |
|
|
108
|
+
| `logsayer init --here` | — | scaffold | Scaffolds into the current directory |
|
|
109
|
+
| `logsayer agent add <opencode\|claude>` | — | coordination | Generates per-role subagents for a tool |
|
|
110
|
+
| `logsayer spec new <hu>` | `logsayer mentat spec new` | 1 | Creates a minimal HU template |
|
|
111
|
+
| `logsayer state show` | `logsayer navigator state show` | 2 | Prints the project snapshot |
|
|
112
|
+
| `logsayer log add "…"` | `logsayer reverend-mother log add` | 3 | Appends a logbook entry (auto-partition) |
|
|
113
|
+
| `logsayer log index` | `logsayer reverend-mother log index` | 3 | Rebuilds `00_index.md` from real files |
|
|
114
|
+
| `logsayer check` | `logsayer suk doctor` | 4 | Mechanical checks: structure, no layer mixing |
|
|
115
|
+
| `logsayer audit run` | `logsayer truthsayer audit run` | 4 | Generates the audit report + semantic prompt |
|
|
116
|
+
| `logsayer audit status` | `logsayer truthsayer audit status` | 4 | Shows HU counter vs threshold, last report |
|
|
117
|
+
| `logsayer process check` | `logsayer fremen verify` | 5 | Process checks: Dor, coordination agreement |
|
|
118
|
+
|
|
119
|
+
## Configuration (`logsayer.toml`)
|
|
120
|
+
|
|
121
|
+
Generated by `logsayer init`, tuned in a single file:
|
|
122
|
+
|
|
123
|
+
```toml
|
|
124
|
+
[logsayer]
|
|
125
|
+
session_close_context_threshold = 0.70 # % context used → propose session close
|
|
126
|
+
bitacora_max_lines = 400 # lines/logbook file before partitioning
|
|
127
|
+
audit_threshold_hus = 3 # HUs closed since last audit → trigger audit
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
## How a session flows
|
|
131
|
+
|
|
132
|
+
1. **Session start** — the agent reads *only* the state layer (`docs/project_state.md`). Cheap in tokens, enough to orient.
|
|
133
|
+
2. **Audit check** — if the closed-HUs counter meets the threshold, the agent proactively proposes an audit (semantic verification).
|
|
134
|
+
3. **Work** — the agent works a HU reading only its folder under `docs/04_user_stories/`, and only opens a logbook entry when it needs the *"why"* of a past decision.
|
|
135
|
+
4. **Close / commit** — with your prior approval, the agent overwrites the state snapshot and appends to the active logbook.
|
|
136
|
+
5. **Auto-partition** — when the active logbook exceeds the line limit, the next file is created and the master index updated.
|
|
137
|
+
|
|
138
|
+
## Example session
|
|
139
|
+
|
|
140
|
+
A full, real transcript — run against a freshly scaffolded project — lives in [`examples/hello-logsayer/`](examples/hello-logsayer/README.md). It walks through scaffold, story creation, logbook entries, verification, and agent adapters, with the actual output of every command.
|
|
141
|
+
|
|
142
|
+
## Multi-agent design
|
|
143
|
+
|
|
144
|
+
A single engine (`logsayer/core/`) plus one thin adapter per agent (`logsayer/adapters/<agent>/`) that only translates each tool's native file convention and calls the CLI. Adding a new agent means a new adapter, not new logic. See [`docs/` of this repo](logsayer_especificacion_maestra.md) (master spec) for the full architecture.
|
|
145
|
+
|
|
146
|
+
## Roadmap
|
|
147
|
+
|
|
148
|
+
- **0–4 (done):** naming & manifest, `init`, core commands (`spec`, `state`, `log`, `audit`), opencode/Claude adapters, mechanical validation (`check`, `process check`).
|
|
149
|
+
- **5 (current):** documentation & publishing — README, PyPI, MIT, examples. You are here.
|
|
150
|
+
- **6:** community presets, more agents on demand (copilot, cursor, gemini, hermes).
|
|
151
|
+
|
|
152
|
+
## Acknowledgment & license
|
|
153
|
+
|
|
154
|
+
- MIT — see [LICENSE](LICENSE).
|
|
155
|
+
- Built around the 5-layer documentary system described in the master spec.
|
|
156
|
+
- Names and concepts from *Dune* are used as a thematic role metaphor only (full disclaimer at the top of this document).
|
logsayer-0.6.0/README.md
ADDED
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
# logsayer
|
|
2
|
+
|
|
3
|
+
> **Spec-kit tells you what to build. logsayer tells you where you stand, how you got there, and whether what you built is still what you said you would build.**
|
|
4
|
+
|
|
5
|
+
A Python CLI that scaffolds and coordinates a 5-layer documentary system for AI-agent projects: Specification, State, Logbook, Verification (mechanical + semantic), and Process.
|
|
6
|
+
|
|
7
|
+
Everything the agent needs to know about a project is written down by the same system that uses it — each layer answers one question, each document lives in exactly one layer, and every judgment lives in the CLI, not in the generated files.
|
|
8
|
+
|
|
9
|
+
## Disclaimer (Dune homage)
|
|
10
|
+
|
|
11
|
+
> This project uses names and concepts from Frank Herbert's *Dune* saga exclusively as a thematic reference and role metaphor. It is not affiliated with, sponsored by, or officially associated with Herbert Properties LLC, Legendary Entertainment, or any rights holders of the franchise. No art, logos, or protected material is reproduced — only concept/role names as a design analogy.
|
|
12
|
+
|
|
13
|
+
## Why logsayer
|
|
14
|
+
|
|
15
|
+
The spec-driven pattern (as popularized by GitHub Spec Kit) governs the *first* generation of code. After that, its authority over the code is by convention, not verification. logsayer closes the loop that pattern leaves open:
|
|
16
|
+
|
|
17
|
+
- **State continuity** between sessions — an anchor snapshot the agent reads (and only that) at session start.
|
|
18
|
+
- **A partitioned, append-only logbook** for the *"why"* of past decisions.
|
|
19
|
+
- **A mechanical + semantic verification loop** that checks whether the code still matches the spec — both structurally and in meaning.
|
|
20
|
+
- **Multi-agent coordination** through the standard `AGENTS.md` convention, with thin native adapters per tool (opencode and Claude Code today).
|
|
21
|
+
|
|
22
|
+
## The 5 layers
|
|
23
|
+
|
|
24
|
+
| # | Layer | Question it answers | Dune role |
|
|
25
|
+
|---|-------|--------------------|-----------|
|
|
26
|
+
| 1 | Specification (normative) | What must be built? | Mentat |
|
|
27
|
+
| 2 | State (anchor) | Where is the project right now? | Guild Navigator |
|
|
28
|
+
| 3 | Logbook (historical) | How did we get here, and why? | Reverend Mother |
|
|
29
|
+
| 4 | Verification | Does what was built still match the spec? | Suk Doctor (mechanical) + Truthsayer (semantic) |
|
|
30
|
+
| 5 | Process (operational) | How do we work here? | Fremen |
|
|
31
|
+
|
|
32
|
+
Every layer has a plain-English alias, so you can use logsayer without knowing any of the lore.
|
|
33
|
+
|
|
34
|
+
## Installation
|
|
35
|
+
|
|
36
|
+
Requires Python 3.11+.
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
uv tool install logsayer
|
|
40
|
+
# or
|
|
41
|
+
pipx install logsayer
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## Quick start
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
# 1. Scaffold a new project
|
|
48
|
+
logsayer init my-project
|
|
49
|
+
cd my-project
|
|
50
|
+
|
|
51
|
+
# 2. Write the spec for a user story
|
|
52
|
+
logsayer spec new HU-01
|
|
53
|
+
|
|
54
|
+
# 3. Add an agent adapter (opencode, claude)
|
|
55
|
+
logsayer agent add opencode
|
|
56
|
+
|
|
57
|
+
# 4. Start a session: check state, work the story
|
|
58
|
+
logsayer state show
|
|
59
|
+
# ... implement HU-01 ...
|
|
60
|
+
|
|
61
|
+
# 5. Close the session: log it, audit when threshold is hit
|
|
62
|
+
logsayer log add "HU-01 done: API + tests"
|
|
63
|
+
logsayer check # mechanical: structure, no mixed layers
|
|
64
|
+
logsayer audit run # semantic: spec vs real code report
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
For an existing project:
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
logsayer init --here
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
## Commands
|
|
74
|
+
|
|
75
|
+
| Command | Dune alias | Layer | Purpose |
|
|
76
|
+
|---------|-----------|-------|---------|
|
|
77
|
+
| `logsayer init [name]` | — | scaffold | Creates `docs/` + `AGENTS.md` + `logsayer.toml` |
|
|
78
|
+
| `logsayer init --here` | — | scaffold | Scaffolds into the current directory |
|
|
79
|
+
| `logsayer agent add <opencode\|claude>` | — | coordination | Generates per-role subagents for a tool |
|
|
80
|
+
| `logsayer spec new <hu>` | `logsayer mentat spec new` | 1 | Creates a minimal HU template |
|
|
81
|
+
| `logsayer state show` | `logsayer navigator state show` | 2 | Prints the project snapshot |
|
|
82
|
+
| `logsayer log add "…"` | `logsayer reverend-mother log add` | 3 | Appends a logbook entry (auto-partition) |
|
|
83
|
+
| `logsayer log index` | `logsayer reverend-mother log index` | 3 | Rebuilds `00_index.md` from real files |
|
|
84
|
+
| `logsayer check` | `logsayer suk doctor` | 4 | Mechanical checks: structure, no layer mixing |
|
|
85
|
+
| `logsayer audit run` | `logsayer truthsayer audit run` | 4 | Generates the audit report + semantic prompt |
|
|
86
|
+
| `logsayer audit status` | `logsayer truthsayer audit status` | 4 | Shows HU counter vs threshold, last report |
|
|
87
|
+
| `logsayer process check` | `logsayer fremen verify` | 5 | Process checks: Dor, coordination agreement |
|
|
88
|
+
|
|
89
|
+
## Configuration (`logsayer.toml`)
|
|
90
|
+
|
|
91
|
+
Generated by `logsayer init`, tuned in a single file:
|
|
92
|
+
|
|
93
|
+
```toml
|
|
94
|
+
[logsayer]
|
|
95
|
+
session_close_context_threshold = 0.70 # % context used → propose session close
|
|
96
|
+
bitacora_max_lines = 400 # lines/logbook file before partitioning
|
|
97
|
+
audit_threshold_hus = 3 # HUs closed since last audit → trigger audit
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
## How a session flows
|
|
101
|
+
|
|
102
|
+
1. **Session start** — the agent reads *only* the state layer (`docs/project_state.md`). Cheap in tokens, enough to orient.
|
|
103
|
+
2. **Audit check** — if the closed-HUs counter meets the threshold, the agent proactively proposes an audit (semantic verification).
|
|
104
|
+
3. **Work** — the agent works a HU reading only its folder under `docs/04_user_stories/`, and only opens a logbook entry when it needs the *"why"* of a past decision.
|
|
105
|
+
4. **Close / commit** — with your prior approval, the agent overwrites the state snapshot and appends to the active logbook.
|
|
106
|
+
5. **Auto-partition** — when the active logbook exceeds the line limit, the next file is created and the master index updated.
|
|
107
|
+
|
|
108
|
+
## Example session
|
|
109
|
+
|
|
110
|
+
A full, real transcript — run against a freshly scaffolded project — lives in [`examples/hello-logsayer/`](examples/hello-logsayer/README.md). It walks through scaffold, story creation, logbook entries, verification, and agent adapters, with the actual output of every command.
|
|
111
|
+
|
|
112
|
+
## Multi-agent design
|
|
113
|
+
|
|
114
|
+
A single engine (`logsayer/core/`) plus one thin adapter per agent (`logsayer/adapters/<agent>/`) that only translates each tool's native file convention and calls the CLI. Adding a new agent means a new adapter, not new logic. See [`docs/` of this repo](logsayer_especificacion_maestra.md) (master spec) for the full architecture.
|
|
115
|
+
|
|
116
|
+
## Roadmap
|
|
117
|
+
|
|
118
|
+
- **0–4 (done):** naming & manifest, `init`, core commands (`spec`, `state`, `log`, `audit`), opencode/Claude adapters, mechanical validation (`check`, `process check`).
|
|
119
|
+
- **5 (current):** documentation & publishing — README, PyPI, MIT, examples. You are here.
|
|
120
|
+
- **6:** community presets, more agents on demand (copilot, cursor, gemini, hermes).
|
|
121
|
+
|
|
122
|
+
## Acknowledgment & license
|
|
123
|
+
|
|
124
|
+
- MIT — see [LICENSE](LICENSE).
|
|
125
|
+
- Built around the 5-layer documentary system described in the master spec.
|
|
126
|
+
- Names and concepts from *Dune* are used as a thematic role metaphor only (full disclaimer at the top of this document).
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Misión y alcance — logsayer
|
|
2
|
+
|
|
3
|
+
**Mensaje de una línea:** *Spec Kit te dice qué construir. logsayer te dice dónde estás parado, cómo llegaste, y si lo que construiste sigue siendo lo que dijiste que ibas a construir.*
|
|
4
|
+
|
|
5
|
+
## Problema
|
|
6
|
+
|
|
7
|
+
Spec Kit y el patrón spec-driven gobiernan la primera generación de código; después, su autoridad sobre el código es por convención, no por verificación. Además, los agentes de IA no tienen memoria persistente entre sesiones: cada sesión arranca sin saber dónde está parado el proyecto ni por qué se tomaron decisiones pasadas.
|
|
8
|
+
|
|
9
|
+
## Qué resuelve logsayer
|
|
10
|
+
|
|
11
|
+
1. **Continuidad de estado entre sesiones** — snapshot ancla (`project_state.md`) que el agente lee al arrancar y que se sobrescribe al cerrar, con aprobación previa.
|
|
12
|
+
2. **Bitácora histórica particionable** — el "por qué" de las decisiones, en append-only, con índice y partición automática por tamaño.
|
|
13
|
+
3. **Verificación continua** — mecánica (estructura, no mezcla de capas) y semántica (lo construido sigue siendo lo especificado).
|
|
14
|
+
4. **Coordinación multi-agente** — un motor único + adaptadores finos por herramienta, con `AGENTS.md` como punto de coordinación universal.
|
|
15
|
+
|
|
16
|
+
## Alcance (qué no es)
|
|
17
|
+
|
|
18
|
+
- No es un ORM de documentación ni genera documentos de cientos de líneas por defecto: produce el mínimo indispensable (spec §10).
|
|
19
|
+
- El resultado del audit semántico no es determinístico: lo produce un subagente a partir de la estructura y el prompt que genera el CLI (spec §10).
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Decisiones técnicas — logsayer
|
|
2
|
+
|
|
3
|
+
Registro de las decisiones de arquitectura activas. Cada una tiene su porqué (entrada de logbook en su momento); acá solo la referencia viva.
|
|
4
|
+
|
|
5
|
+
## D1. Un motor único + adaptadores finos (spec §6)
|
|
6
|
+
|
|
7
|
+
Toda la lógica vive en `logsayer/core/` y `cli.py`. Los archivos generados por `agent add` son wrappers finos que llaman al CLI — agregar un agente nuevo no duplica lógica. *Referencia: bitácora fase 3.*
|
|
8
|
+
|
|
9
|
+
## D2. Alias plano como puerta de entrada (spec §13)
|
|
10
|
+
|
|
11
|
+
`logsayer audit run` ≡ `logsayer truthsayer audit run`. El lore Dune da identidad pero nunca debe ser la única puerta de entrada a la funcionalidad.
|
|
12
|
+
|
|
13
|
+
## D3. Template mínimo por HU (spec §10)
|
|
14
|
+
|
|
15
|
+
Un solo `README.md` por HU con "Qué hay que construir" + "Cómo se valida". Nada de documentos de cientos de líneas por defecto (anti "sea of markdown").
|
|
16
|
+
|
|
17
|
+
## D4. `init --here` en modo adopt (spec §5)
|
|
18
|
+
|
|
19
|
+
`logsayer init --here` scaffoldea sobre un proyecto existente: crea lo que falta y **no sobrescribe** archivos ya presentes (AGENTS.md, logsayer.toml, estado, índice). Cerrado en el dogfooding del propio repo (fase del marco de sesiones).
|
|
20
|
+
|
|
21
|
+
## D5. Audit semántico honesto (spec §10)
|
|
22
|
+
|
|
23
|
+
El CLI genera estructura + prompt; el resultado lo produce un subagente. No se promete determinismo: se documenta. La responsabilidad es generar la estructura del reporte y el prompt, no el veredicto.
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Stack técnico — logsayer (fuente: spec §11 y `pyproject.toml`)
|
|
2
|
+
|
|
3
|
+
| Componente | Elección | Por qué |
|
|
4
|
+
|---|---|---|
|
|
5
|
+
| Lenguaje | Python 3.11+ (`requires-python >=3.11`) | Tipado moderno, ecosistema CLI, targets compatibles |
|
|
6
|
+
| CLI framework | Typer `>=0.12` | Comandos anidados + alias con poco boilerplate |
|
|
7
|
+
| Templates | Jinja2 `>=3.1` | Render de `AGENTS.md`, estado, índice, HUs y adaptadores |
|
|
8
|
+
| Config | TOML (`logsayer.toml`) | Spec §4: umbrales en un solo archivo, parsing nativo (`tomllib`) |
|
|
9
|
+
| Empaquetado | `pyproject.toml` + hatchling | `packages = ["src/logsayer"]`, publicación vía PyPI |
|
|
10
|
+
| Distribución | `uv tool install` / `pipx` | Instalación global de CLIs sin contaminar entornos |
|
|
11
|
+
| Verificación | pytest, ruff, mypy (`--strict`) | Tests + lint + tipado estricto (`pyproject.toml`) |
|
|
12
|
+
|
|
13
|
+
## Layout
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
src/logsayer/
|
|
17
|
+
├── cli.py # comandos Typer + alias planos
|
|
18
|
+
├── config.py # LogsayerConfig (umbrales)
|
|
19
|
+
├── scaffold.py # init / modo adopt
|
|
20
|
+
├── core/ # motor único: specs, logbook, audit, suk, fremen, checks, project
|
|
21
|
+
└── adapters/ # por agente: opencode, claude — wrappers finos al CLI
|
|
22
|
+
```
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Definition of Ready — logsayer
|
|
2
|
+
|
|
3
|
+
Criterios objetivo para considerar una HU lista para trabajar y para cerrar (Capa 5 — Fremen). Reglas del equipo; el framework solo verifica su cumplimiento estructural.
|
|
4
|
+
|
|
5
|
+
## Para arrancar una HU
|
|
6
|
+
|
|
7
|
+
- La HU vive en `docs/04_user_stories/HU-XX/` con su README (qué construir + cómo se valida).
|
|
8
|
+
- La fase del roadmap está reflejada en `docs/project_state.md` (Capa 2).
|
|
9
|
+
- El contador de auditoría está por debajo del umbral (`audit status`); si no, se audita antes.
|
|
10
|
+
|
|
11
|
+
## Para cerrar una HU
|
|
12
|
+
|
|
13
|
+
- `pytest` pasa completo.
|
|
14
|
+
- `ruff check src tests` pasa.
|
|
15
|
+
- `mypy src` (strict) pasa.
|
|
16
|
+
- `logsayer check` reporta estado sano (estructura y capas).
|
|
17
|
+
- Si el cambio toca el CLI o la estructura: `logsayer fremen verify` sano.
|
|
18
|
+
- Se incrementa el contador de HUs en `project_state.md` y se registra la entrada de logbook.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Checklist de merge — logsayer
|
|
2
|
+
|
|
3
|
+
Protocolo de integración (Capa 5 — Fremen). Convención del repo: feature branches convergen en `develop`; los releases llevan tag semver.
|
|
4
|
+
|
|
5
|
+
## Antes de mergear a `develop`
|
|
6
|
+
|
|
7
|
+
- [ ] Rama originada desde `develop` actualizado.
|
|
8
|
+
- [ ] `pytest` en verde.
|
|
9
|
+
- [ ] `ruff check src tests` en verde.
|
|
10
|
+
- [ ] `mypy src` (strict) en verde.
|
|
11
|
+
- [ ] `logsayer check` sano sobre el repo (dogfooding).
|
|
12
|
+
- [ ] Si corresponde, bump de versión sincronizado entre `pyproject.toml` y `src/logsayer/__init__.py`.
|
|
13
|
+
- [ ] Commit(es) con mensaje conventional (`feat`, `fix`, `docs`, `chore`, `test`, `merge`).
|
|
14
|
+
- [ ] Merge `--no-ff` con mensaje `merge(<fase>): <resumen>`.
|
|
15
|
+
|
|
16
|
+
## Publicación (PyPI)
|
|
17
|
+
|
|
18
|
+
- [ ] `python -m build` genera wheel + sdist sin errores.
|
|
19
|
+
- [ ] Instalación en venv limpio: `init` + `check` OK.
|
|
20
|
+
- [ ] Tag semver (`vX.Y.Z`) y push a `origin`.
|
|
21
|
+
- [ ] `uv publish` / `twine upload` con token de `3m1l10j4v13r4qu1n0` (manual).
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# HU-01 — `logsayer init` y scaffold de la estructura de capas
|
|
2
|
+
|
|
3
|
+
> Fase 1 del roadmap (MVP). Cerrada: merge `78ad74c` en develop, tag `v0.1.0`.
|
|
4
|
+
|
|
5
|
+
## Qué hay que construir
|
|
6
|
+
|
|
7
|
+
El comando `logsayer init <project-name>` (y `init --here`) que scaffoldee, sobre un destino vacío:
|
|
8
|
+
|
|
9
|
+
- `docs/` con las 7 carpetas de capas (`01_global`, `02_technical`, `03_process`, `04_user_stories`, `05_agile_methodology`, `06_audits`, `logbooks`), cada una con `.gitkeep`.
|
|
10
|
+
- `docs/project_state.md` (Capa 2), `docs/logbooks/00_index.md` (Capa 3, índice vacío).
|
|
11
|
+
- `AGENTS.md` coordinador con los umbrales renderizados del `logsayer.toml`.
|
|
12
|
+
- `logsayer.toml` con los 3 umbrales definidos (spec §4): `session_close_context_threshold = 0.70`, `bitacora_max_lines = 400`, `audit_threshold_hus = 3`.
|
|
13
|
+
|
|
14
|
+
Validación de entrada: nombre requerido salvo `--here`; slug válido (`[A-Za-z0-9._-]+`); destino no vacío rechazado.
|
|
15
|
+
|
|
16
|
+
## Cómo se valida
|
|
17
|
+
|
|
18
|
+
- `pytest` cubre config (`test_config`), scaffold (`test_scaffold`) y CLI (`test_cli`): estructura completa, umbrales renderizados, rechazo de slug inválido y de destino ocupado.
|
|
19
|
+
- `ruff check` y `mypy --strict` pasan.
|
|
20
|
+
- `logsayer check` sobre un proyecto recién scaffoldeado reporta estado sano.
|
|
21
|
+
|
|
22
|
+
## Log
|
|
23
|
+
|
|
24
|
+
- `2026-09-24` — merge de fase 1 en `develop` (`78ad74c`). Bump a `v0.1.0`.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# HU-02 — Comandos core (spec, log, audit) con alias plano
|
|
2
|
+
|
|
3
|
+
> Fase 2 del roadmap (comandos core). Cerrada: merge `eae09ec` en develop, tag `v0.2.0`.
|
|
4
|
+
|
|
5
|
+
## Qué hay que construir
|
|
6
|
+
|
|
7
|
+
- `logsayer spec new <hu>` — crea la carpeta `04_user_stories/HU-XX/` con un template mínimo de HU (spec §10, sin documentos de cientos de líneas).
|
|
8
|
+
- `logsayer log add "…"` — append en el logbook activo (`docs/logbooks/logbook_<fase>_NN.md`); si supera `bitacora_max_lines`, particiona en `NN+1`.
|
|
9
|
+
- `logsayer log index` — reconstruye `docs/logbooks/00_index.md` desde los archivos reales.
|
|
10
|
+
- `logsayer audit run` — genera la estructura del reporte + prompt semántico en `06_audits/` (el juicio lo produce la Decidora; ver riesgo §10).
|
|
11
|
+
- `logsayer audit status` — contador de HUs vs umbral y último reporte.
|
|
12
|
+
- Registro de los comandos bajo el grupo de rol (`mentat spec new`, `navigator state show`, `reverend-mother log add`, `truthsayer audit run`) Y con alias plano en la raíz (`spec new`, `state show`, `log add`, `audit run`).
|
|
13
|
+
|
|
14
|
+
## Cómo se valida
|
|
15
|
+
|
|
16
|
+
- `pytest` cubre specs (`test_specs`), logbook con partición (`test_logbook`), audit (`test_audit`) y los alias por CLI (`test_cli_commands`).
|
|
17
|
+
- `ruff check` y `mypy --strict` pasan.
|
|
18
|
+
|
|
19
|
+
## Log
|
|
20
|
+
|
|
21
|
+
- `2026-09-24` — merge de fase 2 en `develop` (`eae09ec`). Bump de versión a `0.2.0` (`b193158`).
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# HU-03 — Adaptadores multi-agente (opencode y claude)
|
|
2
|
+
|
|
3
|
+
> Fase 3 del roadmap (adaptadores). Cerrada: merge `196d9eb` en develop, tag `v0.3.0`.
|
|
4
|
+
|
|
5
|
+
## Qué hay que construir
|
|
6
|
+
|
|
7
|
+
`logsayer agent add <opencode|claude>` que genere, en la convención nativa de cada herramienta, subagentes por rol (mentat, navigator, reverend-mother, truthsayer) como **wrappers finos**: archivos que invocan al CLI (`logsayer log add "…"`, etc.), sin duplicar lógica del framework (spec §6 y §10 — todo el juicio vive en `logsayer/core/`).
|
|
8
|
+
|
|
9
|
+
- opencode → `.opencode/agents/<rol>.md`
|
|
10
|
+
- claude → `.claude/agents/<rol>.md`
|
|
11
|
+
|
|
12
|
+
Registro por agente en un registry desacoplado (`adapters/registry.py`) para permitir sumar agentes nuevos sin tocar el motor. La convención estándar (`AGENTS.md`) queda como el punto de coordinación universal (spec §6).
|
|
13
|
+
|
|
14
|
+
## Cómo se valida
|
|
15
|
+
|
|
16
|
+
- `pytest` cubre los adapters (`test_adapters`): registro por nombre, generación de archivos en la ruta nativa, falla controlada para agentes desconocidos.
|
|
17
|
+
- `ruff check` y `mypy --strict` pasan.
|
|
18
|
+
|
|
19
|
+
## Log
|
|
20
|
+
|
|
21
|
+
- `2026-09-24` — merge de fase 3 en `develop` (`196d9eb`), poblando primero los entornos propios (opencode y Claude Code), resto por demanda (spec §9).
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# HU-04 — Validación mecánica (Suk Doctor) y de proceso (Fremen)
|
|
2
|
+
|
|
3
|
+
> Fase 4 del roadmap (validación). Cerrada: merge `c5fdf66` en develop, tag `v0.4.0`.
|
|
4
|
+
|
|
5
|
+
## Qué hay que construir
|
|
6
|
+
|
|
7
|
+
- `logsayer suk doctor` (alias `logsayer check`) — chequeo mecánico determinístico (bot, spec §2): marca de raíz, estructura completa de capas, estado de Capa 2 presente, índice de bitácora, ubicación de las HUs, y **detección de capas mezcladas** (un documento en la capa equivocada). Exit code 1 si algo falla.
|
|
8
|
+
- `logsayer fremen verify` (alias `logsayer process check`) — chequeo de proceso: estado documentado, proceso desplegado, acuerdo de coordinación y Definition of Ready.
|
|
9
|
+
|
|
10
|
+
Ambos comparten el mismo motor de chequeos (`core/checks.py`) y renderización (`_render_checks` en `cli.py`).
|
|
11
|
+
|
|
12
|
+
## Cómo se valida
|
|
13
|
+
|
|
14
|
+
- `pytest` cubre `checks` (`test_checks`), `suk` y `fremen` (`test_cli_commands`): sano con estructura correcta, falla con capas mezcladas o ausentes, exit code 1.
|
|
15
|
+
- `ruff check` y `mypy --strict` pasan.
|
|
16
|
+
|
|
17
|
+
## Log
|
|
18
|
+
|
|
19
|
+
- `2026-09-24` — merge de fase 4 en `develop` (`c5fdf66`). Bump a `v0.4.0`.
|