Commit Graph
21 Commits
Author SHA1 Message Date
blumia 83e09e8e25 feat: archive filter uses the shared project sheet, with search
- the archive page's horizontal project chips become the same project
  scope row as new-session / scheduled tasks / stats: tapping it opens the
  shared project bottomsheet (all projects, chat, every project with its
  icon, path and checkmark) and filters the archive
- the shared project sheet gains a search field over project name and path,
  so a long project list can be narrowed; it shows "no matching projects"
  when nothing matches
- version 0.6.1+601
- archive test covers filtering through the sheet
2026-11-27 12:14:44 +08:00
blumia c6b5a870c6 feat: add a project from the picker, and keep the context ring
- the project picker has an "Add project" action: a folder browser starts
  at the server user's home, navigates (typed path, up, new folder) and
  adds the chosen folder through POST /api/openchamber/directory; the new
  project becomes the draft's target at once
- refreshProjects merges settings-only projects (newest added first), so a
  project added before its first session still appears in the picker; the
  first session moves it into /api/project as usual
- usageReading no longer hides the composer's context ring when the
  session's model has left the server catalog: a 200K window is assumed,
  the percentage is prefixed with "~", and the usage sheet says the window
  is estimated. A failed model fetch at connect is retried when a chat
  opens, so a normal session shows the real percentage
- tests: the add-project browser flow, settings-only projects, and the
  estimated/known context readings
2026-11-27 09:26:14 +08:00
blumia b65498d73e feat: stats page, and the client becomes Chamber Go
- 全部功能 gains 统计 (Stats): ranges Today/7/30/90 days/all time, a
  project scope (reusing the shared project sheet, plus "All projects"),
  session/prompt/token/cost/active-days/streak tiles, a daily activity
  chart (weekly past 92 days), token composition, efficiency tiles, model
  ranking by tokens/cost/steps and on-request tool-call stats; data comes
  from /api/experimental/session/stats and the day buckets use the device's
  IANA zone (a small platform channel; desktop falls back to UTC)
- the model bars draw a full-width track with a left-aligned fill, so a
  small token share reads as a sliver instead of an empty bar
- AI token strings read 词元 (not 令牌) in Chinese
- the client's display name is Chamber Go (launcher, iOS, Linux window,
  About), package unchanged; pairing/login labels and the user-agent
  follow, so a newly paired device shows "Chamber Go" on the web client's
  "Connect to this server" list
- bump to 0.5.6
2026-11-26 17:18:09 +08:00
blumia a70e9290ef feat: one project sheet for sessions and scheduled tasks
- the scheduled-task scope dropdown becomes the same project sheet the
  new-session composer opens: Chat row, project icons, paths, the current
  check mark, and one row per checkout
- a filesystem root ("/") no longer reads as a blank row: pathLeaf falls
  back to the path itself instead of an empty last segment
- the sheet opens at once and refreshes the project list behind it; an
  empty list shows "Loading projects…" until the answer arrives, so the
  project chip no longer waits before anything appears
- bump to 0.5.5
2026-11-26 14:00:35 +08:00
blumia 511c3b006b feat: write the UI in English, select only conversation content
- source strings are English again; Chinese comes from lib/l10n/zh.dart
  through tr()/trArgs() and AppText, and a language without a table
  (Spanish, ...) reads English instead of Chinese
- server and user data (titles, messages, file names, notes, task names)
  is drawn with plain Text, so it is never looked up in the table
- SelectionArea moved from the whole message list to the messages, the
  answer text, an opened tool call's details and the turn footer; status
  lines and folded tool rows no longer start a selection
- a message the transcript does not know (its start event was lost while
  the stream was down) fetches the tail once, so a turn continued from
  another client comes in with its prompt
- bump to 0.5.3
2026-11-26 11:48:16 +08:00
blumia 7b5bccf28f feat: English and Chinese, and selectable chat text
- settings → general → language picks system, Chinese or English; the
  choice is stored on the device and read before the first frame
- our Chinese strings are translated through tr()/trArgs() and AppText,
  with the English in lib/l10n/en_*.dart; a missing entry falls back to
  Chinese and a test checks that every literal in lib has one
- AppText rebuilds on a language change (it depends on the resolved
  locale), so const text and whole pages switch at once; the built-in
  date/time pickers and selection menu follow the same language
- server and user data (titles, messages, prompts, paths) is never
  translated
- the chat list sits in a SelectionArea: long-press selects message text
  and shows the copy/select-all menu
- bump to 0.5.2
2026-11-26 09:04:25 +08:00
blumia da4bfb6826 feat: add scheduled tasks behind a 全部功能 button
- the sidebar footer gains 全部功能 left of 设置; its page lists the
  features the server offers, planned tasks for now
- 计划任务 follows the web client: a project (or the chats scope) picked
  at the top, then its tasks with schedule, last result, next run, model
  and error; the switch pauses, the menu runs now, edits or deletes
- the editor covers name, prompt, daily/weekly/once/cron schedules
  (Chinese date and time pickers), several times a day, weekdays, cron
  examples, enabled, and either the session defaults or a fixed model
  and agent
- the same /api/projects/:id/scheduled-tasks endpoints the web uses; a
  server without them says so instead of failing silently
- the app now pins zh_CN localizations, so the built-in pickers and
  menus are Chinese too
- bump to 0.5.1
2026-11-26 00:36:27 +08:00
blumia 9564019a91 fix: match the background task bar to the activity strip
- draw the task bar in the activity strip's capsule (8px margins, 14px
  padding, 36px min height, stadium radius) so the two read as one stack
- drop the stop button from the bar: its padding pushed the clock off the
  right edge shared with the strip above; the row opens the sheet instead
- in the sheet, show only the clock while running, a stop button with a
  stop icon, and "已结束" once the command ends; no "运行中" label and no
  close x (the drag handle and the scrim already close it)
- say "读取输出…" while the first page loads instead of claiming the
  command has printed nothing
- rest the pet's feet on the status capsule's edge (4px top margin)
  instead of sinking 2px into it
2026-11-24 23:19:47 +08:00
blumia c4de5e84d8 feat: watch background commands, open their output and stop them
A command the agent detached keeps running after its tool call returns;
the chat now shows it above the composer: one row per command with its
clock and a stop, folded under "正在执行 N 条命令" when there are
several, with a subagent tag for a child session's command.

Tapping a row opens the live output in a sheet (a page a second from
shell.output, tail kept), following the tail with a way back to the
newest line. The tool row that started it carries a 后台 tag and shows
the same output when expanded, falling back to the completion note once
the shell is gone; a command stopped from the app says so instead of
showing the Shell.NotFoundError it leaves behind.

The list comes from opencode's own shell jobs (experimental/job,
descendants included), so a foreground command never appears, and an
older server falls back to the shell list narrowed by the detached
calls in the transcript. Stopping confirms, removes the shell, and
leaves the model a note that the stop was the user's, as the
first-party client does.

0.4.14 (414).
2026-11-24 19:31:22 +08:00
blumia d533bc95ef feat: show edit and write tools as line diffs
Expanding an edit, write or patch call now renders the change as tinted
diff lines instead of an old/new text blob: added lines green, removed
lines red, @@ hunk headers marked, and file header noise hidden. The
patch comes from the server's metadata.files[].patch; older servers fall
back to a line diff of the edit's old/new strings, and a write with only
content shows as added lines.

The tool row also shows +N −M for these calls, as dsh-Go does, and a
phone-sized preview stops at 600 lines.

0.4.12 (412).
2026-11-23 22:36:05 +08:00
blumia 79221e57d7 feat: group the server's chats and use OpenChamber's project icons
Sessions under the server's managed chats root (chats/<date>/session-…) were
grouped per directory, so each one appeared as its own session-xxxxx band.
GET /api/fs/home now supplies the chats root plus its canonical and legacy
aliases; every chat folder becomes the single 聊天 group. The new-session
picker can target 聊天 too: the first send creates a fresh chat directory
before creating the session, and a new session started from an existing chat
gets a new one instead of sharing its folder.

Projects merge their OpenChamber settings row (label, icon key, colour,
iconBackground and uploaded/auto icon image) with /api/project. Group
headers, the picker and the draft chip draw the chosen icon in its colour,
and custom images are fetched through the client transport (SVG included)
with a themed fallback to the glyph. The chat group uses a chat bubble rather
than a folder.

0.4.8 (408).
2026-11-23 17:42:49 +08:00
blumia d25167de58 fix: float the pet over the messages and let it be dragged
The pet used to sit in the column above the composer, reserving a strip of
its own: the message list ended there, which read as an opaque band cutting
off the last row. It is now a layer over the message area, so the list keeps
its full height and shows through around the sprite. Only the body of the
sheet takes touches (contentBox, 4dp out); taps and drags on the transparent
canvas still reach the messages underneath.

Dragging the body moves the pet along the composer's top edge (or the
activity cap's) with a small lift while held and the pack's drag reaction.
The spot is stored as a fraction of the width in pet.x.v1, so a restart or a
change in width puts it back in the same place. Taps now react on tap-up so a
drag does not fire a left/right reaction.

0.4.1 (401).
2026-11-22 14:30:30 +08:00
blumia d72af036a1 feat: imported input-box pets, with dsh-Go's sprite packs
Nothing is built in: Settings → 宠物 shows "尚未导入宠物" until a zip is
picked. The zip holds a dsh-Go pack.json and PNG sheets; it is validated
(pack.json, every named sheet) and unpacked under the app's private files
directory, with enable, size (40/52/64) and remove kept on the device.

A pack's canvas, anchor, per-animation box and frame list drive rendering:
PetSlot reserves the area above the baseline and stands the sprite on the
composer's top edge (or on the activity cap while a turn runs). Idle,
thinking, working and error follow the chat's state, and a tap plays the
pack's react-left/react-right. Only one sheet is decoded at a time.

path_provider's JNI binding does not load on this engine, so MainActivity
exposes the files directory over a tiny method channel instead.

dist/deepy-whale-pet.zip is the Deepy whale for testing. Tests cover the
real pack manifest, frame/state mapping and zip import.

0.4.0 (400).
2026-11-22 13:39:49 +08:00
blumia 6ced914757 fix: centre the context ring, show a live status while running, and settle project rows
- The folded composer aligns to its bottom edge, so the 16px usage ring sat
  below the 36px keys; a 10px bottom padding puts it on their centre line (the
  two-row layout was already centred).
- A running turn no longer shows the finished turn's footer (model · mode ·
  time, with its copy/fork menu). Above the input there is now an activity
  strip like dsh-Go's: "思考中 / 正在回复 / 正在读取 · …" with the current
  step's summary and a clock that ticks each second.
- Project headers in the sidebar are tinted bands at least a session row tall,
  with a folder icon, a bolder name and the path beneath, so the project and
  its sessions read as different levels.
- Project names take the last path segment with either separator, and path
  comparisons unify `\`/`/` (case-insensitively for drive-letter paths); the
  grouping key does too, so a Windows server no longer shows a full path or
  splits one project in two.
- 0.3.19 (319).
2026-11-22 11:59:33 +08:00
blumia 1aa84a53e5 feat: queue a message for the running turn, and fold the composer when the IME closes
- A send while a turn runs joins it (delivery "steer") on a short press; a
  long press offers steer or queue. Queue/steer prompts wait in the server's
  inbox and show as a pending bubble at the end of the transcript, with
  改为排队/转为转向 and 撤回 (which puts the text back into the composer).
  The inbox is read on open and resume and kept current by the
  session.inbox.* events; delivery reloads the tail.
- The send key is stop only while running with an empty draft; with text it
  sends (as dsh-Go does), leaving the long press for the delivery choice.
- The composer also folds to one line when the phone's back gesture closes
  the keyboard while the field keeps focus: the page passes the keyboard
  height (a Scaffold strips the bottom inset from its body) and the composer
  treats a fall below half the peak as a dismissal.
- The Build/Plan chip now opens a bottom sheet with icons, hints and a check,
  instead of a popup menu.
- Tests: composer_box_test (focus opens, IME dismissal folds, typing reopens)
  and inbox_item_test (list items, enqueued events, delivery changes).
- 0.3.16 (316).
2026-11-21 18:32:57 +08:00
blumia ea3b1f0f5e ui: fold the composer to one line until it has focus
dsh-Go opens the input into two rows only while focused: the text above, the
model / mode / keys below, folding back when focus leaves. ComposerBox keeps
the field across the two layouts with a GlobalKey and animates the swap.

Model and thinking level are now one control (ModelPill shows "model · effort"
and the sheet offers the level after choosing a model); Build/Plan is a
separate ModeChip. The draft page uses the same box, with its project chip
above it. 0.3.15 (315).
2026-11-21 17:47:04 +08:00
blumia 7f2f454539 fix: switching a session's model, and put the model row in the composer
- POST /api/session/:id/model takes the reference under `model`; sending it
  at the top level was rejected with "Missing key at [model]".
- The chat now shows the model/agent row above the input (revealed while
  typing or running, as dsh-Go does) instead of in the app bar; the draft
  keeps the same row, with its project chip first.
- Thinking levels: /api/model's variants become a 思考 chip and sheet; the
  choice travels as ModelRef.variant on the switch or the create, and the
  last level per model is remembered on the device.
- The model picker groups providers, adds 收藏 and 最近 (device-local), shows
  each model's context size and reasoning mark, and collapses sections.
- The `/` palette is shared by the chat and the draft (new slash_palette
  widget); the draft lists commands and skills but not the client-local
  /compact, which needs an existing session.
- 0.3.14 (314).
2026-11-21 17:03:22 +08:00
blumia fff6562cbc feat: a new-session draft and a sidebar grouped by project
- Starting a session opens NewSessionScreen instead of a title sheet: a
  project chip (GET /api/project, one row per canonical), a model/agent
  chip, attachments and the composer. Nothing is created on the server
  until the first send, which posts the session with its directory, model
  and agent and then sends that message.
- The draft lives in AppState (memory only): leaving it keeps it; the
  sidebar shows a draft row with its first line and a discard button; a
  failed create stays on the draft with its text.
- The session list groups by project (chat folders under 聊天), dates the
  rows (今天/昨天/本周早些时候/更早), pins through
  session.metadata.openchamber.pinned, archives on demand, pages with
  "载入更多", and swipes to pin/archive/delete (flutter_slidable).
- Child sessions are hidden; a parent's row shows its children's activity.
- The chat app bar follows the live session list, so the title the server
  generates from the first message appears at once.
- Attachments and the model picker move to shared widgets, used by the
  chat and the draft.
- 0.3.13 (313).
2026-11-21 14:29:52 +08:00
blumia 5f95e2da97 feat: the terminal, project knowledge, and downloads that can be cancelled
- lib/api/terminal.dart: the PTY protocol (create/resize/restart/close, and
  the /api/terminal/ws binary control frames) with a reconnecting socket
  that replays the server snapshot at the size it was drawn for.
- lib/terminal_state.dart: an xterm model plus that socket, kept per
  workspace on AppState, so closing the panel or switching tabs keeps the
  shell; the app reattaches when it returns from the background.
- lib/screens/terminal_panel.dart: TerminalView, a status bar (keyboard,
  restart, clear, close) and a Termux-style key bar whose CTRL/ALT/SHIFT
  modifiers also apply to what the phone keyboard types.
- lib/screens/knowledge_panel.dart: notes, todos and plans from
  /api/project-context, searchable, with a full page for a plan's Markdown
  and its raw editor.
- Downloads stream with a progress dialog (bytes, total, percent) and a
  cancel that aborts the request; the save dialog only opens on success.
  The request asks for `accept-encoding: identity` so Content-Length exists.
- MarkdownView renders task lists as ✅/⬜ instead of material_ui's
  Checkbox, which wants a material_ui Material ancestor the app lacks.
- Dialogs own their TextEditingControllers, so closing one no longer
  trips a framework assertion in debug builds.
- 0.3.11 (311).
2026-11-21 02:49:07 +08:00
blumia 9b53338908 feat: the files sidebar, Markdown thinking, a banner that clears
- The chat's top-right menu only repeated the per-turn menu. It now opens a
  files sidebar that slides in from the right, the way the official client's
  right panel does: browse the session directory with a breadcrumb and an up
  key, filter the current directory, search its subdirectories (bounded,
  skipping .git/node_modules/build and friends), preview text/code/Markdown/
  images, edit and save text files, create files and folders, and download
  any file through the system save dialog.
- The panel's "..." menu carries the official client's "显示被 git 忽略的文件"
  toggle (the listing asks the server to respect gitignore by default) and a
  refresh. 项目知识 and 终端 have their tabs, marked as coming later.
- Thinking blocks are Markdown too (headings, lists, inline code), rendered
  with the shared MarkdownView at a smaller, quieter size.
- The reconnect banner stayed forever: the stream loop sets it when the SSE
  connection drops and nothing cleared it. Any event proves the stream is
  back (the server greets every connection with server.connected), so it now
  clears the message then.
- Markdown rendering moved to lib/widgets/markdown_view.dart, shared by
  messages, thinking, compaction summaries and file previews.
Version 0.3.9 (code 309).
2026-11-20 18:25:28 +08:00
blumia aee560172c feat: port the client to Flutter (0.3.0)
Replace the MyGo/Go app with a Flutter client that keeps the feature set:

- servers: saved servers, passwordless and password login, HTTP/SOCKS5
  proxy via dart:io, self-signed certificates and pinning, tokens in
  flutter_secure_storage (Keystore)
- sessions: list with live events, search, new/rename/archive/delete,
  instance sheet
- chat: streaming Markdown (flutter_markdown), reasoning and tool rows,
  image previews, context usage ring and sheet, model/agent switching,
  fork/revert, attachments (file_picker), permissions
- Android 7.0 (API 24)+, plain http:// works in release (Dart dials
  sockets directly)
- build: China mirrors for Gradle/NDK, Aliyun Maven repositories, and the
  Gradle distribution pre-seeded; release signed with the test keystore

Read-aloud is dropped as requested. Version 0.3.0.
2026-11-18 19:08:06 +08:00