pi-studio 0.5.13 → 0.5.15
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 +21 -0
- package/WORKFLOW.md +21 -15
- package/client/studio-client.js +4079 -0
- package/client/studio.css +1026 -0
- package/index.ts +638 -5044
- package/package.json +2 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,27 @@ All notable changes to `pi-studio` are documented here.
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [0.5.15] — 2026-03-16
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
- Per-pane **Focus pane** controls for both the editor and response panes, matching the current Ghostty/cmux split-browser workflow more directly.
|
|
11
|
+
- cmux-aware Studio completion notifications with safer workspace-level targeting, a running/compacting sidebar status pill, stale-notification clearing when a new Studio request starts, and suppression when the Studio browser surface is already focused.
|
|
12
|
+
|
|
13
|
+
### Fixed
|
|
14
|
+
- Active **Focus pane** buttons now keep their accent-coloured hover state instead of switching to a dark hover style.
|
|
15
|
+
- PDF export now defines the LaTeX `Highlighting` environment when Pandoc has not already created it, fixing exports that previously failed with `Environment Highlighting undefined`.
|
|
16
|
+
|
|
17
|
+
## [0.5.14] — 2026-03-15
|
|
18
|
+
|
|
19
|
+
### Fixed
|
|
20
|
+
- Studio PDF export now carries the editor language to the server and defensively re-wraps non-markdown editor content there before Pandoc export, reducing brittle diff/code export failures when the editor contains raw git diffs or code-like text.
|
|
21
|
+
- Studio PDF export now also auto-detects both raw **and already-fenced** git-diff content server-side even if the client-side editor language was lost or stale.
|
|
22
|
+
- Editor-preview PDF export no longer classifies diff/code text as LaTeX just because the content happens to mention strings like `\documentclass` or `\begin{document}` inside a diff/code block.
|
|
23
|
+
- Diff-language editor PDF exports now first try the normal highlighted Pandoc path, but fall back to a literal-text LaTeX export when highlighted diff export fails on large or markdown-like git diffs.
|
|
24
|
+
- Highlighted PDF code/diff blocks now enable LaTeX-side line wrapping, reducing long diff/code lines running off the page.
|
|
25
|
+
- Non-markdown editor preview panes such as diff/code now wrap long lines instead of forcing horizontal overflow.
|
|
26
|
+
- Passive Studio browsing controls such as response-history navigation and left/right view switching remain available while a model request is running.
|
|
27
|
+
|
|
7
28
|
## [0.5.13] — 2026-03-15
|
|
8
29
|
|
|
9
30
|
### Fixed
|
package/WORKFLOW.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# pi-studio workflow
|
|
1
|
+
# pi-studio workflow/spec note
|
|
2
2
|
|
|
3
3
|
## Goal
|
|
4
4
|
|
|
@@ -7,9 +7,9 @@ Keep Studio simple while supporting both loops:
|
|
|
7
7
|
1. **User → model feedback** (annotated reply)
|
|
8
8
|
2. **Model → user critique** (structured critique package)
|
|
9
9
|
|
|
10
|
-
Studio uses a **single workspace
|
|
10
|
+
Studio uses a **single workspace**:
|
|
11
11
|
- left pane: **Editor**
|
|
12
|
-
- right pane: **Response**
|
|
12
|
+
- right pane: **Response / Thinking / Editor Preview**
|
|
13
13
|
|
|
14
14
|
---
|
|
15
15
|
|
|
@@ -46,17 +46,23 @@ Critiques current editor text and expects/handles structured output:
|
|
|
46
46
|
|
|
47
47
|
## Response handling
|
|
48
48
|
|
|
49
|
-
|
|
49
|
+
By default, the right pane follows the latest assistant response, but Studio can also:
|
|
50
|
+
- browse older assistant responses via response history
|
|
51
|
+
- show **Thinking (Raw)** for the currently selected response when available
|
|
52
|
+
- show **Editor (Preview)** for the current editor text
|
|
50
53
|
|
|
51
|
-
When response is structured critique, Studio enables additional helpers:
|
|
54
|
+
When the selected response is structured critique, Studio enables additional helpers:
|
|
52
55
|
- **Load critique (notes)** (`## Assessment` + `## Critiques`)
|
|
53
56
|
- **Load critique (full)** (`## Assessment` + `## Critiques` + `## Document`)
|
|
54
57
|
|
|
55
58
|
For non-critique responses:
|
|
56
59
|
- **Load response into editor**
|
|
57
60
|
|
|
58
|
-
|
|
59
|
-
- **
|
|
61
|
+
In Thinking view (when available):
|
|
62
|
+
- **Load thinking into editor**
|
|
63
|
+
- **Copy thinking text**
|
|
64
|
+
|
|
65
|
+
Otherwise, Studio supports copying the currently viewed response text.
|
|
60
66
|
|
|
61
67
|
---
|
|
62
68
|
|
|
@@ -75,11 +81,11 @@ Rules:
|
|
|
75
81
|
|
|
76
82
|
## Required UI elements
|
|
77
83
|
|
|
78
|
-
- Header actions: **Save As…**, **Save file** (file-backed), **Load file
|
|
79
|
-
- Header view toggles: `Left: Editor (Raw|Preview)`, `Right: Response (Raw|Preview) | Editor (Preview)`
|
|
84
|
+
- Header actions: **Save As…**, **Save file** (file-backed), **Load file content**
|
|
85
|
+
- Header view toggles: `Left: Editor (Raw|Preview)`, `Right: Response (Raw|Preview) | Thinking (Raw) | Editor (Preview)`
|
|
80
86
|
- Preview mode uses server-side `pandoc` rendering (math-aware) with plain-markdown fallback when renderer is unavailable.
|
|
81
87
|
- Editor actions: **Insert/Remove annotated reply header**, **Annotations: On|Hidden**, **Strip annotations…**, **Run editor text**, **Critique editor text** (+ critique focus), **Send to pi editor**, **Copy editor text**, **Save .annotated.md**
|
|
82
|
-
- Response actions include `Auto-update response: On|Off`, **Fetch latest response**, response-history browse (`Prev/Next/Last`), **Load response into editor**,
|
|
88
|
+
- Response actions include `Auto-update response: On|Off`, **Fetch latest response**, response-history browse (`Prev/Next/Last`), **Load response into editor**, **Load response prompt into editor**, and thinking-aware load/copy actions when Thinking view is active
|
|
83
89
|
- Source badge: `blank | last model response | file <path> | upload`
|
|
84
90
|
- Response badge: `none | assistant response | assistant critique` (+ timestamp)
|
|
85
91
|
- Sync badge: shown only when the editor exactly matches the currently viewed response/thinking (`In sync with response | In sync with thinking`)
|
|
@@ -89,13 +95,13 @@ Rules:
|
|
|
89
95
|
|
|
90
96
|
## Escaping pitfalls (implementation note)
|
|
91
97
|
|
|
92
|
-
|
|
98
|
+
Studio is less fragile than before because browser JS/CSS now live in extracted client files, but `index.ts` still builds the HTML shell and injects boot/theme/source values. Incorrect escaping can still break Studio boot.
|
|
93
99
|
|
|
94
100
|
Rules of thumb:
|
|
95
|
-
-
|
|
96
|
-
-
|
|
97
|
-
-
|
|
98
|
-
- After touching
|
|
101
|
+
- Prefer `JSON.stringify(value)` when injecting arbitrary text into boot data or script-adjacent HTML.
|
|
102
|
+
- Be careful with HTML attribute escaping for injected values.
|
|
103
|
+
- After touching the HTML shell / boot-data wiring in `index.ts`, do a `/studio` boot smoke test immediately.
|
|
104
|
+
- After touching `client/studio-client.js` or `client/studio.css`, smoke test the main workflows: boot, websocket connect/reconnect, file load, run/critique, preview, and response history.
|
|
99
105
|
|
|
100
106
|
## Acceptance criteria
|
|
101
107
|
|