@vinihcrosa/lumem-os 0.1.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.
Files changed (55) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +107 -0
  3. package/bin/lumem.mjs +4605 -0
  4. package/bin/postinstall.mjs +55 -0
  5. package/dist/server/main.mjs +95446 -0
  6. package/dist/web/assets/codemirror-setup-Csmyc9rQ.js +18 -0
  7. package/dist/web/assets/core-rofTMs1b.js +12 -0
  8. package/dist/web/assets/css-CLj8gQPS.js +1 -0
  9. package/dist/web/assets/diff-D97Zzqfu.js +1 -0
  10. package/dist/web/assets/docker-BcOcwvcX.js +1 -0
  11. package/dist/web/assets/engine-javascript-DBd1bXLz.js +141 -0
  12. package/dist/web/assets/html-pp8916En.js +1 -0
  13. package/dist/web/assets/index-BlWx0v0O.js +101 -0
  14. package/dist/web/assets/index-jS7lSqBc.css +32 -0
  15. package/dist/web/assets/inter-latin-wght-normal-Dx4kXJAl.woff2 +0 -0
  16. package/dist/web/assets/javascript-wDzz0qaB.js +1 -0
  17. package/dist/web/assets/jetbrains-mono-latin-400-normal-V6pRDFza.woff2 +0 -0
  18. package/dist/web/assets/json-Cp-IABpG.js +1 -0
  19. package/dist/web/assets/jsx-g9-lgVsj.js +1 -0
  20. package/dist/web/assets/make-CHLpvVh8.js +1 -0
  21. package/dist/web/assets/markdown-Cvjx9yec.js +1 -0
  22. package/dist/web/assets/python-B6aJPvgy.js +1 -0
  23. package/dist/web/assets/shellscript-Yzrsuije.js +1 -0
  24. package/dist/web/assets/sql-CRqJ_cUM.js +1 -0
  25. package/dist/web/assets/toml-vGWfd6FD.js +1 -0
  26. package/dist/web/assets/tsx-COt5Ahok.js +1 -0
  27. package/dist/web/assets/typescript-BPQ3VLAy.js +1 -0
  28. package/dist/web/assets/yaml-Buea-lGh.js +1 -0
  29. package/dist/web/index.html +13 -0
  30. package/drizzle/0000_initial.sql +68 -0
  31. package/drizzle/0001_adorable_joshua_kane.sql +71 -0
  32. package/drizzle/0002_striped_trish_tilby.sql +1 -0
  33. package/drizzle/0003_memoria_do_workspace.sql +127 -0
  34. package/drizzle/0004_memoria_no_nucleo.sql +1 -0
  35. package/drizzle/0005_playbooks.sql +21 -0
  36. package/drizzle/0006_consumo_por_turno.sql +15 -0
  37. package/drizzle/0007_project_origin_and_management.sql +2 -0
  38. package/drizzle/0008_sessao_de_script.sql +40 -0
  39. package/drizzle/0009_porta_por_checkout.sql +13 -0
  40. package/drizzle/0010_confianca_no_scripts.sql +1 -0
  41. package/drizzle/0011_fase_de_teste.sql +40 -0
  42. package/drizzle/meta/0000_snapshot.json +450 -0
  43. package/drizzle/meta/0001_snapshot.json +515 -0
  44. package/drizzle/meta/0002_snapshot.json +522 -0
  45. package/drizzle/meta/0003_snapshot.json +1292 -0
  46. package/drizzle/meta/0004_snapshot.json +1300 -0
  47. package/drizzle/meta/0005_snapshot.json +1445 -0
  48. package/drizzle/meta/0006_snapshot.json +1544 -0
  49. package/drizzle/meta/0007_snapshot.json +1559 -0
  50. package/drizzle/meta/0008_snapshot.json +1570 -0
  51. package/drizzle/meta/0009_snapshot.json +1649 -0
  52. package/drizzle/meta/0010_snapshot.json +1656 -0
  53. package/drizzle/meta/0011_snapshot.json +1656 -0
  54. package/drizzle/meta/_journal.json +90 -0
  55. package/package.json +47 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Vinicius Rosa
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.
package/README.md ADDED
@@ -0,0 +1,107 @@
1
+ # Lumem-OS
2
+
3
+ > πŸ‡§πŸ‡· [Leia em portuguΓͺs](README.pt-BR.md) β€” the product's interface and all
4
+ > documentation under `docs/` are in Portuguese today.
5
+
6
+ A local harness for running AI coding agents across git worktrees. One daemon on
7
+ your machine, one browser tab, and a hierarchy that matches how the work is
8
+ actually organized: **workspace β†’ project (a git repo) β†’ worktree**.
9
+
10
+ ![The worktree screen: sidebar of projects, a worktree cut from the current branch, and its setup script already run](docs/assets/screenshot.png)
11
+
12
+ Each worktree is a real `git worktree` on disk with its own branch, its own agent
13
+ conversation, its own terminal and its own reserved ports β€” so several tasks run
14
+ side by side without stepping on each other.
15
+
16
+ ## Install
17
+
18
+ ```sh
19
+ npm i -g @vinihcrosa/lumem-os
20
+ lumem
21
+ ```
22
+
23
+ The daemon starts on `http://127.0.0.1:4317` and serves the interface from the
24
+ same port. `lumem --open` opens a browser too.
25
+
26
+ The name is neither short nor pretty for a reason: npm refuses the bare `lumem`
27
+ as too similar to `mem`, and `@vinihcrosa/lumem` is already a different project.
28
+ The command is still `lumem` β€” and `lumem-os` is installed as a second name for
29
+ the same binary, for machines that have both packages.
30
+
31
+ From a clone, if you would rather build it yourself:
32
+
33
+ ```sh
34
+ pnpm install
35
+ pnpm build
36
+ npm i -g ./packages/cli
37
+ ```
38
+
39
+ **What the machine needs:**
40
+
41
+ | | |
42
+ |---|---|
43
+ | Node | 22 or newer |
44
+ | git | 2.30 or newer β€” the whole product is worktrees |
45
+ | An ACP agent | the `claude` CLI, for the agent conversation. The first-run screen installs the adapter for you |
46
+ | OS | macOS and Linux. Windows is not supported ([why](docs/project/backlog.md)) |
47
+
48
+ Nothing else: the two native dependencies (`better-sqlite3`, `node-pty`) ship
49
+ prebuilt binaries, so a global install compiles nothing on the common platforms.
50
+ Verified on macOS arm64 and Linux x64; other architectures are untested.
51
+
52
+ Everything Lumem writes lives under `~/.lumem` β€” SQLite registry, worktrees,
53
+ conversations, memory. `--state-dir` moves it.
54
+
55
+ ## What it does
56
+
57
+ | | |
58
+ |---|---|
59
+ | [Projects and worktrees](docs/prd/walking-skeleton/prd.md) | register a repo by path or [clone it from a URL](docs/prd/project-from-url/prd.md); cut worktrees from the product instead of the terminal |
60
+ | [Agent conversations over ACP](docs/prd/acp-sessions/prd.md) | plan, usage and cost, slash commands, an embedded terminal, and the conversation **on disk** β€” closing Lumem does not lose it |
61
+ | [Files, diff and an editor](docs/prd/file-editor/prd.md) | browse the checkout, read the diff against the base branch, and edit with autosave |
62
+ | [Project scripts](docs/prd/project-scripts/prd.md) | `setup`, `run` and `test` live in `<repo>/.lumem/project.toml`; a new worktree is born prepared, and one click brings the app up on a port reserved for that checkout |
63
+ | [Workspace memory](docs/prd/workspace-memory/prd.md) | what the harness learned, versioned in git, behind a write gate and an inbox of proposals. The three switches that spend tokens ship **off** |
64
+ | [Pull request status](docs/prd/pull-request-status/prd.md) | designed, not built: which of your worktrees is actually mergeable |
65
+
66
+ ## How it works
67
+
68
+ - a **daemon** (Fastify + tRPC + WebSocket) owns every process, every worktree
69
+ and the database; it is the only thing that touches the disk;
70
+ - a **React** client, served by the daemon in production and by vite in
71
+ development, speaking to it in relative paths;
72
+ - **SQLite** under `~/.lumem` for the registry, plus one file per conversation;
73
+ - **real git worktrees** β€” no virtual checkouts, no shadow copies. What you see
74
+ in Lumem is what `git worktree list` sees;
75
+ - **ACP** ([Agent Client Protocol](docs/project/pty-vs-acp.md)) for the agent, and
76
+ a PTY for shells. The decision, and what it cost, is written down.
77
+
78
+ ## Develop
79
+
80
+ ```sh
81
+ pnpm install
82
+ pnpm dev # daemon on :4317, vite on :4318
83
+ ```
84
+
85
+ | Command | What it runs |
86
+ |---|---|
87
+ | `pnpm gate:quick` | the tests affected by the current work |
88
+ | `pnpm gate:full` | the whole suite plus e2e |
89
+ | `pnpm gate:build` | typecheck everything, then build |
90
+ | `pnpm smoke:install` | packs the tarball, installs it into a throwaway prefix, and boots it |
91
+
92
+ The documentation is the map: [docs/README.md](docs/README.md) indexes every
93
+ feature's PRD, the design decisions, the [testing matrix](docs/project/testing.md)
94
+ and the [backlog](docs/project/backlog.md).
95
+
96
+ ## Status
97
+
98
+ **0.1.0.** Eleven features stand up and the product goes from an empty `~/.lumem`
99
+ to an answered agent turn without touching a config file. It is a personal
100
+ project, used daily by its author, and it promises no API stability yet.
101
+
102
+ Interface and documentation are in Portuguese; [moving everything to
103
+ English](docs/project/backlog.md) is on the backlog.
104
+
105
+ ## License
106
+
107
+ [MIT](LICENSE).