Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,31 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [1.6.0] - 2026-09-23

### Added

- Channels can opt into Session presentation, per-channel Default/Comfy/Compact density, and Default/By active ordering without changing the underlying conversation model.
- Board now uses authoritative operational lanes—Working, Needs you, Scheduled, Failed, and Complete—with idle and archived sessions kept in collapsed history.
- Messages expose a direct Copy action, and ordinary Work Log steps show user-local timestamps.
- Native vision sends supported human image uploads to compatible models as image content and lets resident agents inspect workspace images through the bounded `view_image` tool.
- Clients record the user's IANA time zone so agent invocations receive both user-local time and the exact UTC instant.

### Changed

- Thread navigation is latest-intent-wins, deduplicates duplicate destinations, paints bounded cached snapshots immediately, loads channel and thread data concurrently, and server-paginates long threads while preserving the visible anchor when older replies load.
- Board and thread listings use lightweight bounded payloads so large channels avoid unnecessary database, transfer, and browser work.
- Provider cache policy is applied after the actual route is selected. Claude receives reusable stable and rolling breakpoints; ChatGPT and xAI receive stable thread-scoped cache keys; provider usage is normalized into cache reads, cache writes, uncached input, and logical input.
- Embedded ReRouted advances to 0.5.15 with bounded model validation, Claude Code 2.1.280 OAuth compatibility, cross-turn Claude cache reuse, and valid atomic serialization of parallel Claude tool results.

### Fixed

- Reader-controlled conversation and Work Log scrolling remains stable through live updates, sidebar changes, message expansion, reconnects, foreground recovery, and growing streamed replies.
- Stopping or cancelling a running scheduled wake authoritatively cancels its durable follow-up, prevents finalization from re-arming it, and keeps cancellation controls visible while it runs.
- Manual provider model tests time out cleanly instead of remaining indefinitely in a testing state.
- Photon outages no longer restart the entire 1Helm service.
- Saved channel density is authoritative on rendered session cards.

## [1.5.0] - 2026-09-06

### Added
Expand Down
35 changes: 14 additions & 21 deletions config/module-budgets.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,37 +6,30 @@
},
"legacy": {
"lines": {
"src/client/app.ts": 3672,
"src/client/channel.ts": 1202,
"src/client/cowork.ts": 879,
"src/client/routing.ts": 864,
"src/client/settings.ts": 812,
"src/server/agents.ts": 1353,
"src/server/bots.ts": 2189,
"src/client/app.ts": 3907,
"src/client/channel.ts": 1056,
"src/client/cowork.ts": 878,
"src/client/routing.ts": 821,
"src/server/agents.ts": 1347,
"src/server/bots.ts": 2176,
"src/server/channel-computers.ts": 2217,
"src/server/db.ts": 1158,
"src/server/index.ts": 2284,
"src/server/routing.ts": 1303
"src/server/index.ts": 2334,
"src/server/routing.ts": 1247,
"src/server/store.ts": 808
},
"fanIn": {
"src/client/api.ts": 11,
"src/client/dom.ts": 9,
"src/client/api.ts": 12,
"src/client/dom.ts": 10,
"src/server/agents.ts": 10,
"src/server/db.ts": 30,
"src/server/db.ts": 32,
"src/server/store.ts": 9
},
"fanOut": {
"src/server/bots.ts": 23,
"src/server/index.ts": 33
"src/server/bots.ts": 24,
"src/server/index.ts": 35
},
"cycles": [
[
"src/client/app.ts",
"src/client/channel.ts",
"src/client/cowork.ts",
"src/client/settings.ts",
"src/client/term.ts"
],
[
"src/server/bots.ts",
"src/server/followups.ts"
Expand Down
11 changes: 11 additions & 0 deletions docs/VISION.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,17 @@ sole visual home for recurring work and its chronological run history; workflow
runs do not spill into Chat, Board, or Threads, while each run remains a normal
interactive thread when opened.

## Session presentation and operational truth

Channels may opt into Session mode without changing navigation or information
architecture. The same Chat tab, sessions, order, content, labels, colors, and
thread behavior remain; only top-level Chat rows receive a compact bordered-card
presentation. Turning the mode off restores the standard Chat presentation.

Board uses operational states for every channel, regardless of Session mode.
Runtime records—not generated prose or the ambiguous database `open` value—own
Working, Needs you, Scheduled, Failed, Complete, Idle, and Archived.

## Honest model usage

A thread's primary token indicator answers how much input context the latest model call processed, not how many repeated prompt-token encounters accumulated across an agent loop. 1Helm calculates this itself from the structured messages and tool schemas it sends, using one stable provider-neutral approximation. Cached is the unchanged leading context shared with the preceding call; output counts response text and tool-call payloads received by 1Helm; calls count successful invocations. These product metrics never depend on provider usage reports. Lifetime output and model-call count remain cumulative because they represent newly generated work and actual invocations; cumulative prompt traffic is never presented as the size of a conversation.
Expand Down
11 changes: 6 additions & 5 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "1helm",
"productName": "1Helm",
"version": "1.5.0",
"version": "1.6.0",
"private": true,
"type": "module",
"license": "AGPL-3.0-only",
Expand Down Expand Up @@ -87,7 +87,7 @@
"@codemirror/lang-sql": "6.10.0",
"@codemirror/lang-yaml": "6.1.3",
"@excalidraw/excalidraw": "0.18.1",
"@gitcommit90/rerouted": "github:gitcommit90/rerouted#e200e457ad2c6abe17f8f6c2e00d8026ea027e09",
"@gitcommit90/rerouted": "github:gitcommit90/rerouted#df7fd909f2f0d499f7d3e4657df93b780c3837ac",
"@opencoredev/loginwithchatgpt-server": "^0.2.0",
"codemirror": "6.0.2",
"docx": "9.7.1",
Expand Down
4 changes: 2 additions & 2 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@
document.querySelectorAll('meta[name="theme-color"]').forEach(function (m) { m.setAttribute("content", color); });
})();
</script>
<link rel="stylesheet" href="/app.css?v=1d58393a8deb" />
<link rel="stylesheet" href="/app.css?v=0945b06381eb" />
</head>
<body class="h-screen w-screen overflow-hidden antialiased">
<div id="app" class="h-full w-full"></div>
<script type="module" src="/bundle.js?v=22e6e103acb2"></script>
<script type="module" src="/bundle.js?v=0e3fe58a8f17"></script>
</body>
</html>
2 changes: 1 addition & 1 deletion scripts/run-test-suite.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ delete env.HELM_APP_ROOT;
const suites = [
["test/native-world.mjs"],
["--test", "--test-concurrency=1",
"test/phase6-modules.mjs", "test/provider-prompt-cache.mjs", "test/output-truncation.mjs",
"test/phase6-modules.mjs", "test/provider-prompt-cache.mjs", "test/chatgpt-stream.mjs", "test/vision-runtime.mjs", "test/output-truncation.mjs",
"test/provider-model-refresh.mjs", "test/routing.mjs", "test/routing-disabled-account.mjs", "test/routing-antigravity.mjs", "test/desktop.mjs", "test/update-service.mjs",
"test/channel-computers.mjs", "test/channel-computers-isolated-backends.mjs", "test/event-loop-unblocking.mjs", "test/read-state.mjs",
"test/cloudflare-worker.mjs", "test/connectors.mjs", "test/chatgpt-image.mjs", "test/autonomy-platform.mjs",
Expand Down
25 changes: 17 additions & 8 deletions src/client/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export type ChannelComputer = {
obligations: Array<{ kind: string; ref: string; mode: "resident" | "wakeable"; details: string; due_at?: number | null }>;
};
export type ChannelMember = { id: number; username: string; display: string; avatar: string };
export type Channel = { id: number; name: string; slug: string; kind: string; topic: string; purpose: string; status: "active" | "archived"; unread: number; favorite?: boolean; members?: ChannelMember[]; agent: ResidentAgent | null; computer?: ChannelComputer | null; personal_main?: boolean; can_manage?: boolean; detailed?: boolean; call_skipper_without_confirmation?: boolean };
export type Channel = { id: number; name: string; slug: string; kind: string; topic: string; purpose: string; status: "active" | "archived"; unread: number; favorite?: boolean; members?: ChannelMember[]; agent: ResidentAgent | null; computer?: ChannelComputer | null; personal_main?: boolean; can_manage?: boolean; detailed?: boolean; call_skipper_without_confirmation?: boolean; session_mode?: boolean; session_sort?: "default" | "active"; session_density?: "default" | "comfy" | "compact" };
export type Bot = { id: number; name: string; model: string; avatar: string; provider_id: number | null; provider_name: string | null; provider_kind: string | null; computers: number[]; prefs: Record<string, string>; agent_id?: number | null; agent_kind?: string | null; agent_status?: string | null; resident_channel_id?: number | null };
export type ThreadFollowup = {
id: number;
Expand All @@ -57,9 +57,10 @@ export type ThreadState = {
status: "open" | "waiting" | "resolved" | "failed" | "archived";
title: string;
summary: string;
operational_state?: "working" | "needs_you" | "scheduled" | "failed" | "complete" | "idle" | "archived";
opened_at: number;
updated_at: number;
root: Message;
root: Pick<Message, "id">;
/** Active durable agent wake, pending or currently running (Board Scheduled lane). */
followup?: ThreadFollowup | null;
};
Expand Down Expand Up @@ -147,11 +148,13 @@ export type RoutingCombo = { id: string; storageId?: string | null; name: string
export type RoutingUsageEntry = {
at?: number; model?: string; provider?: string; providerName?: string; providerType?: string;
accountAlias?: string | null; status?: number; requests?: number; prompt_tokens?: number;
completion_tokens?: number; cached_tokens?: number; total_tokens?: number; error?: unknown;
completion_tokens?: number; cached_tokens?: number; cache_read_tokens?: number; cache_write_tokens?: number;
uncached_input_tokens?: number; logical_input_tokens?: number; token_semantics?: string; total_tokens?: number; error?: unknown;
};
export type RoutingUsage = {
requests: number; ok: number; errors: number; prompt_tokens: number; completion_tokens: number;
cached_tokens: number; total_tokens: number; byModel: RoutingUsageEntry[];
cached_tokens: number; cache_read_tokens: number; cache_write_tokens: number; uncached_input_tokens: number;
logical_input_tokens: number; token_semantics?: string; total_tokens: number; byModel: RoutingUsageEntry[];
byProvider: RoutingUsageEntry[]; recent: RoutingUsageEntry[];
};
export type RoutingQuotaWindow = { id: string; label: string; usedPercent: number; remainingPercent: number; resetsAt?: number | null };
Expand All @@ -168,8 +171,8 @@ export type RoutingState = {
keyedPresets: Array<{ id: string; name: string; baseUrl: string; needsAccountId?: boolean }>;
};

export async function routingAction<T = Record<string, unknown>>(action: string, payload?: unknown): Promise<T> {
return api<T>("/api/routing/action", { body: { action, payload } });
export async function routingAction<T = Record<string, unknown>>(action: string, payload?: unknown, options: { signal?: AbortSignal } = {}): Promise<T> {
return api<T>("/api/routing/action", { body: { action, payload }, signal: options.signal });
}
export type Skill = {
id?: number; slug: string; name: string; description: string; category: string; instructions?: string; assigned?: boolean;
Expand Down Expand Up @@ -213,11 +216,17 @@ export function workspacePhotoSrc(photoUrl: string | null | undefined, cacheBust
export const setToken = async (t: string): Promise<void> => { token = t; setAuthenticatedAssetToken(t); await persistSecureSession(t); };
export const clearToken = async (): Promise<void> => { token = ""; setAuthenticatedAssetToken(""); await removeSecureSession(); };

export async function api<T = any>(path: string, opts: { method?: string; body?: unknown; headers?: Record<string, string> } = {}): Promise<T> {
const browserTimeZone = (() => {
try { return Intl.DateTimeFormat().resolvedOptions().timeZone || ""; }
catch { return ""; }
})();

export async function api<T = any>(path: string, opts: { method?: string; body?: unknown; headers?: Record<string, string>; signal?: AbortSignal } = {}): Promise<T> {
const res = await fetch(apiUrl(path), {
method: opts.method || (opts.body !== undefined ? "POST" : "GET"),
headers: { ...(opts.body !== undefined ? { "content-type": "application/json" } : {}), ...(token ? { authorization: `Bearer ${token}` } : {}), ...(opts.headers || {}) },
headers: { ...(opts.body !== undefined ? { "content-type": "application/json" } : {}), ...(token ? { authorization: `Bearer ${token}` } : {}), ...(browserTimeZone ? { "x-1helm-time-zone": browserTimeZone } : {}), ...(opts.headers || {}) },
body: opts.body !== undefined ? JSON.stringify(opts.body) : undefined,
signal: opts.signal,
});
const data = await res.json().catch(() => ({}));
if (!res.ok) throw new Error((data as { error?: string }).error || `HTTP ${res.status}`);
Expand Down
Loading
Loading