Skip to content

Commit 588b547

Browse files
authored
fix(tui): reserve the commit glyph, switch output tokens to arrows (#75)
* fix(tui): reserve the commit glyph, switch output tokens to arrows * docs: document provider env keys for odek v2
1 parent 6b03f64 commit 588b547

5 files changed

Lines changed: 18 additions & 16 deletions

File tree

‎README.md‎

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ behaviour (tools, danger gating, sandbox, skills, memory, sessions) comes from
2828
go install github.com/BackendStack21/odek/cmd/odek@latest
2929
go install github.com/BackendStack21/bodek/cmd/bodek@latest
3030

31-
# 2 · Provide an LLM key (any OpenAI-compatible provider)
32-
export ODEK_API_KEY=<your-key>
31+
# 2 · Provide an LLM key (odek v2: provider env key)
32+
export DEEPSEEK_API_KEY=<your-key>
3333

3434
# 3 · Chat
3535
bodek
@@ -75,7 +75,7 @@ bodek reuses that exact protocol from the terminal, which means:
7575

7676
**Prerequisite:** bodek is only the front-end — you also need the `odek`
7777
engine. See [odek's install instructions](https://github.com/BackendStack21/odek)
78-
(any OpenAI-compatible provider key via `ODEK_API_KEY`).
78+
(provider env key such as `DEEPSEEK_API_KEY` / `ZAI_API_KEY` — see odek's [PROVIDERS.md](https://github.com/BackendStack21/odek/blob/main/docs/PROVIDERS.md)).
7979

8080
### Prebuilt binaries
8181

@@ -105,8 +105,8 @@ releases page and put `bodek.exe` on your `PATH`.
105105
go install github.com/BackendStack21/odek/cmd/odek@latest
106106
go install github.com/BackendStack21/bodek/cmd/bodek@latest
107107

108-
# Provide an LLM key (any OpenAI-compatible provider)
109-
export ODEK_API_KEY=<your-key>
108+
# Provide an LLM key (odek v2: provider env key)
109+
export DEEPSEEK_API_KEY=<your-key>
110110

111111
bodek
112112
```
@@ -281,7 +281,9 @@ own front-end settings are separate; see [Configuration](#configuration).
281281
`plan N/M` and `● N jobs` / `✗ job` instruments ride the same bar when
282282
a plan or background job is active.
283283
- **Per-turn footers & `/stats`** — token counts and latency ride every turn
284-
head; `/stats` opens a sheet that rolls up the session (cost, cache, context).
284+
head (`⚡` latency, `⌂` context, `↳` output tokens, `⚒` tools); `/stats`
285+
opens a sheet that rolls up the session (cost, cache, context). The `⎇`
286+
glyph is reserved for git commits in the transcript.
285287
- **Cost tracking** — when odek has token prices configured, the header shows
286288
the running session spend, each turn footer its estimated cost, and
287289
`/stats` adds the `max_cost_usd` cap when set; hidden entirely otherwise.

‎docs/CONFIGURATION.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,13 @@ left off unless a flag or `BODEK_THEME` overrides it.
5252
| `BODEK_CONFIG` | settings path | Alternative path for the settings file (used by tests and shared-dotfile setups). |
5353
| `NO_COLOR` | all rendering | Any non-empty value degrades the color profile to plain text in every mode — standard nocolor.org semantics. |
5454
| `NO_MOTION` | animations | Any non-empty value replaces animated spinners/progress with single static frames. |
55-
| `ODEK_API_KEY` | odek (not bodek) | Read by the `odek serve` engine bodek spawns — any OpenAI-compatible provider key. |
55+
| `DEEPSEEK_API_KEY` / `OPENAI_API_KEY` / `ZAI_API_KEY` / … | odek (not bodek) | Provider keys read by the `odek serve` engine bodek spawns. Set `ODEK_PROVIDER` to match. `ODEK_API_KEY` is a v1 selected-provider override only. |
5656

5757
## odek-side configuration
5858

5959
Everything the agent does is configured on the odek side
60-
(`~/.odek/config.json` → `./odek.json` → `ODEK_*` env vars): model, base
61-
URL, API keys, MCP servers, memory, skills, sandbox. bodek inherits it
60+
(`~/.odek/config.json` → `./odek.json` → `ODEK_*` env vars): provider, model,
61+
provider keys, MCP servers, memory, skills, sandbox. bodek inherits it
6262
unchanged — see the
6363
[odek repository](https://github.com/BackendStack21/odek) for the full
6464
server configuration reference.

‎internal/tui/commands.go‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,7 @@ func (m *Model) statsBody() string {
428428

429429
rows = []row{
430430
{"⌂", th.statCtx, "context", ctxVal},
431-
{"⎇", th.statCtx, "output", th.statsValue.Render(human(m.sessOutTok))},
431+
{"↳", th.statCtx, "output", th.statsValue.Render(human(m.sessOutTok))},
432432
{"↻", th.statsLabel, "turns", th.statsValue.Render(fmt.Sprintf("%d", len(m.turnStats)))},
433433
{"⚒", th.statTool, "tools", th.statsValue.Render(fmt.Sprintf("%d", m.toolTotal))},
434434
{"⚡", th.statTime, "latency", latVal},

‎internal/tui/stats_test.go‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ func TestTurnStatLine(t *testing.T) {
6767
}
6868

6969
out := plain(m.View())
70-
for _, want := range []string{"⚡ 2.5s", "⌂ 1.2k", "⎇ 340", "⚒ 1", "✳"} {
70+
for _, want := range []string{"⚡ 2.5s", "⌂ 1.2k", "↳ 340", "⚒ 1", "✳"} {
7171
if !strings.Contains(out, want) {
7272
t.Errorf("stat line missing %q in:\n%s", want, out)
7373
}
@@ -238,11 +238,11 @@ func TestContextGauge(t *testing.T) {
238238
}
239239
}
240240
// The gauge is the header's sole token metric: the cumulative session
241-
// summary (∑ ⌂ … · ⎇ …) lives in /stats and the per-turn stat line, not
241+
// summary (∑ ⌂ … · ↳ …) lives in /stats and the per-turn stat line, not
242242
// here — a fresh session must not flash placeholder zeros in the bar.
243243
m.sessCtxTok, m.sessOutTok = 0, 0
244244
out = plain(m.header())
245-
for _, banned := range []string{"∑", "⌂ 0", "⎇ 0"} {
245+
for _, banned := range []string{"∑", "⌂ 0", "↳ 0"} {
246246
if strings.Contains(out, banned) {
247247
t.Errorf("header still carries session summary %q:\n%s", banned, out)
248248
}
@@ -370,7 +370,7 @@ func TestStatLineWidthDegradation(t *testing.T) {
370370
// At a comfortable width all three essentials survive.
371371
m := newTestModel()
372372
m.resize(80, 20)
373-
if line := plain(m.statLine(ts)); !strings.Contains(line, "⌂") || !strings.Contains(line, "⎇") {
373+
if line := plain(m.statLine(ts)); !strings.Contains(line, "⌂") || !strings.Contains(line, "↳") {
374374
t.Errorf("essentials missing at width 80: %q", line)
375375
}
376376
}

‎internal/tui/view.go‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -777,7 +777,7 @@ func (m *Model) statSegments(ts turnStats) []statSeg {
777777
// wall-clock lives on the /stats card — the head stays quiet
778778
// context + output tokens — always present
779779
add(th.statCtx.Render("⌂")+th.statLine.Render(" "+human(ts.ctxTok)), 0)
780-
add(th.statCtx.Render("⎇")+th.statLine.Render(" "+human(ts.outTok)), 0)
780+
add(th.statCtx.Render("↳")+th.statLine.Render(" "+human(ts.outTok)), 0)
781781
// tools — count plus the deduped glyph cluster
782782
if ts.toolCount > 0 {
783783
tools := th.statTool.Render("⚒") + th.statLine.Render(" "+fmt.Sprintf("%d", ts.toolCount))
@@ -1565,7 +1565,7 @@ func (m *Model) footer() string {
15651565
if m.lastLatency > 0 {
15661566
seg := th.statTime.Render("⚡") + th.footer.Render(fmt.Sprintf(" %.1fs", m.lastLatency))
15671567
if n := len(m.turnStats); n > 0 {
1568-
seg += th.footerSep.Render(" · ") + th.statCtx.Render("⎇") +
1568+
seg += th.footerSep.Render(" · ") + th.statCtx.Render("↳") +
15691569
th.footer.Render(" "+human(m.turnStats[n-1].outTok))
15701570
}
15711571
segs = append(segs, seg)

0 commit comments

Comments
 (0)