Commit Graph

143 Commits

Author SHA1 Message Date
Agents
e549200f5d test(web): add playwright e2e for Dreams + docs screenshots
- packages/web/e2e/dreams.spec.ts: 4 tests covering sidebar entry,
  heading/breadcrumb resolution, mocked-API clustering into rows with
  count chips, and the premise-tree expansion path. Uses a function
  matcher for context.route so the trailing ?page=&page_size= query
  string doesn't break a glob.
- docs/screenshots/: dark + light mode list and expanded-detail PNGs
  captured at 2880x1800 (retina) via playwright against the dev
  server with a tiny mock Honcho.
- DreamList.tsx: add a literal space to CountChip's label fragment so
  the rendered text reads "3 explicit" instead of "3explicit" (gap-1
  styles the visual layout but doesn't add a text-node space). Better
  for screen readers, copy/paste, and assertion via toContainText.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-28 14:07:22 -05:00
Agents
f318555c82 feat(web): add Dream Output Viewer
Dreams are currently a black box — to benchmark Tier L models on dreamer
induction quality we need to see what each model produced. This adds a
workspace-scoped /dreams route that surfaces every dream run as a
group of conclusions split into explicit / deductive / inductive
columns, with click-to-expand premise trees.

What's here:

- `lib/dreams.ts`: pure helpers. `clusterConclusionsIntoDreams` groups a
  raw conclusions list into per-pair bursts using a configurable time
  window (default 60s). `expandPremiseTree` walks `reasoning_tree` first
  and falls back to a flat `premises` ID list, with cycle detection and
  a depth cap. Defines an `ExtendedConclusion` type that augments the
  generated schema with `conclusion_type`, `premises`, and
  `reasoning_tree` — Honcho's migration f1a2b3c4d5e6 added those
  columns but `schema.d.ts` doesn't expose them yet, so the UI degrades
  gracefully (unknown types fall into "explicit").

- `api/queries.ts`: new `useDreams` hook that paginates the conclusions
  list endpoint up to a configurable cap (default 400) and hands the
  raw list to the UI for clustering. New `dreams` query key.

- `components/dreams/`:
  - `DreamList.tsx` — route entry. Shows recent dreams as rows with
    timestamp, observer→observed pair, and per-type counts. Selecting
    a row expands an inline detail panel above the list.
  - `DreamDetail.tsx` — three-column view (explicit / deductive /
    inductive). Each inductive conclusion has a "Show premises" button
    that expands the reasoning chain.
  - `PremiseTree.tsx` — recursive premise renderer with type badges,
    cycle indicator, and graceful handling of premises that fall
    outside the loaded page.

- Routing: `routes/workspaces_.$workspaceId_.dreams.tsx` registers the
  page; routeTree.gen.ts regenerated.

- Sidebar: new "Dreams" entry between Conclusions and Webhooks
  (MoonStar icon to distinguish from the dark-mode Moon).

- Breadcrumb: "dreams" added to SECTION_LABELS so the trail resolves.

Tests (vitest, 14 new):
- clustering: empty input; same-pair burst within window; gap exceeds
  threshold → split; different pairs don't merge even with overlapping
  timestamps; custom gap window; newest-first ordering; counts default
  unknown types to explicit.
- premise tree: empty children for no premises; flat list → direct
  children; multi-level reasoning_tree recursion; missing premise
  flagged (not in loaded page); cycle detection halts recursion;
  maxDepth cap; reasoning_tree preferred over flat premises.

Verified manually in the preview: route mounts, sidebar/breadcrumb
resolve, error path renders cleanly, typecheck + lint + dream tests
all clean. The unrelated `app.test.tsx` failure is pre-existing on
main.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-28 14:06:46 -05:00
BenSheridanEdwards
e809409fa3 ci(deps): add grouped Dependabot config
Weekly npm (pnpm workspace), cargo (Tauri shell), and github-actions
updates, grouped by family (TanStack, Tauri, React, test stack, build
tooling, semantic-release, commitlint) to keep related bumps in one PR.

Co-authored-by: Ben Sheridan-Edwards <BenSheridanEdwards@users.noreply.github.com>
2026-05-28 14:02:08 -05:00
BenSheridanEdwards
86bb9d6be0 chore(hooks): pre-push gate, secret scan, pr:evidence drafter
Phase A of the quality-gate rollout — local + pre-push gates that stop
slop before it leaves the laptop. Preventative controls, per the
architect playbook.

- .husky/pre-commit — adds scripts/secret-scan.sh as the first check
  before the existing Biome format/lint. Blocks the commit when a
  likely secret is found in staged additions. Existing Biome behaviour
  is preserved.
- .husky/pre-push (new) — runs `pnpm check` (lint + typecheck + test)
  before the branch leaves the laptop. Mirrors the `check` job in
  .github/workflows/ci.yml so PR-blocking issues surface locally first.
  Bypassable for genuine emergencies with `git push --no-verify`.
- scripts/secret-scan.sh (new) — regex scan over staged additions for
  the common accidents: AWS keys, Anthropic/OpenAI/GitHub/Slack/Google/
  Stripe tokens, JWTs, PEM private key blocks, hardcoded password
  literals. Validated against synthetic leaks of each type. No external
  tool dependency — pure bash + grep, runs in <100ms typical.
- scripts/pr-evidence.sh (new) — drafts a PR_BODY.md from the diff vs
  origin/main: file lists (added/modified/deleted), commit summaries,
  and the QA checklist. Flags screenshots as REQUIRED when the diff
  touches packages/web/src/{components,routes} or packages/desktop.
  Wired as `pnpm pr:evidence` so it runs from anywhere in the
  workspace.
- .gitignore — adds PR_BODY.md so drafts don't get committed by
  accident.

Pre-commit stays fast (<2s typical). Heavy checks (typecheck, full
test run) live in pre-push.
2026-05-28 14:01:20 -05:00
Offending Commit
cfe07f1900 feat(docker): add containerized web build with CORS guidance
Multi-stage Dockerfile (node:22-alpine + pnpm build -> nginx-unprivileged
serve) producing a non-root image that runs under read-only fs + cap_drop
ALL. nginx.conf does SPA-fallback routing, /healthz, immutable asset cache,
and gzip, plus an opt-in same-origin reverse-proxy block.

docs/docker.md documents build/run and the two ways to handle browser CORS
on the web build (configure Honcho's CORSMiddleware, or the nginx proxy).

The Dockerfile and nginx.conf are adapted from @zmarakjanbangash's fork.

Co-authored-by: zmarakjanbangash <zmarakjanbangash@users.noreply.github.com>
2026-05-28 13:59:47 -05:00
batumilove
5cfbae6248 fix: harden token and URL handling
* fix: harden token and URL handling

* test: restore full web test suite

---------

Co-authored-by: batumilove <batumilove@users.noreply.github.com>
2026-05-28 13:54:48 -05:00
Agents
866dab39fe docs(seed-kits): add dark-mode screenshots alongside light
- Moves docs/seed-kits/*.png into docs/seed-kits/light/.
- Adds docs/seed-kits/dark/ with the same three panels rendered in
  the dark theme.
- Updates the capture script to loop over both themes by setting
  openconcho:theme in localStorage and the matching colorScheme on
  the browser context.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-28 13:53:51 -05:00
Agents
650bfd7b28 feat(web): add Peer Card Seed Kits
Adds a /seed-kits page where users can author named "kits" of card
lines (e.g. "Personal core", "Work context") and one-click apply them
to any peer across any registered instance. Removes the chore of
manually re-typing the same identity facts into multiple agents.

Built-in starter kits are read-only but forkable. User kits live in
localStorage. The apply flow shows a side-by-side merge preview that
dedupes by the line's prefix (text before the first ":"), so applying
a kit with "Name: Ben Sheridan-Edwards" to a peer whose card already
has "Name: Ben" replaces the line rather than duplicating it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-28 13:53:50 -05:00
BenSheridanEdwards
de8db4b7aa feat(api): add scoped multi-instance query client
Adds createScopedClient() — an openapi-fetch client bound to a specific
Instance (rather than the active one in localStorage) — and the
useScoped* TanStack Query hooks (workspaces, peers, peer representation,
peer card) with per-instance query-key isolation so caches never collide
across instances.

Foundation for multi-instance features (seed kits, desktop
auto-discover) that read from non-active instances.

Co-authored-by: Ben Sheridan-Edwards <BenSheridanEdwards@users.noreply.github.com>
2026-05-28 13:52:15 -05:00
HunterSThompson
7cf94aa03f feat(web): show sidebar last updated status 2026-05-28 13:46:48 -05:00
github-actions[bot]
2d7937e275 chore(release): 0.9.0 [skip ci]
# [0.9.0](https://github.com/offendingcommit/openconcho/compare/v0.8.0...v0.9.0) (2026-05-28)

### Features

* **web:** add global metadata visibility toggle ([e490d91](e490d911fc))
* **web:** add shared Breadcrumb component for workspace pages ([c6afc80](c6afc80fda))
* **web:** add workspace contextual sub-nav to sidebar ([62cae68](62cae68d05))
2026-05-28 18:46:42 +00:00
Offending Commit
6960bf4ffe Merge pull request #17 from offendingcommit/test/wrap-harness-metadata-provider
test(web): wrap test harness in MetadataProvider to match production
2026-05-28 13:45:46 -05:00
Offending Commit
1094904a03 test(web): wrap test harness in MetadataProvider to match production
main.tsx wraps the app in DemoProvider > MetadataProvider, but the
app.test.tsx render helpers only wrapped with DemoProvider. Since
e490d91 added useMetadata() to Sidebar, the routed app threw
"useMetadataContext must be used within MetadataProvider" in tests;
the error boundary swallowed the tree and the first-load assertion
failed. CI has been red on main since that commit.

Mirror the production provider nesting in both render sites.
2026-05-28 13:43:31 -05:00
Offending Commit
e490d911fc feat(web): add global metadata visibility toggle
Introduce MetadataContext + useMetadata hook backed by localStorage and
wire a Braces button into the sidebar footer that toggles raw metadata
visibility across the app. Replace per-page collapsible metadata in
PeerDetail and WorkspaceDetail with a global animated reveal styled
distinctly (warning-colored card) to signal raw payload. Also adopts
the shared Breadcrumb in both detail pages.
2026-05-15 14:27:53 -05:00
Offending Commit
62cae68d05 feat(web): add workspace contextual sub-nav to sidebar
Detect active workspace via fuzzy matchRoute against /workspaces/$workspaceId
and reveal an animated sub-nav with links to Peers, Sessions, Conclusions,
and Webhooks for that workspace. Sub-nav collapses smoothly when leaving
the workspace context.
2026-05-15 14:25:42 -05:00
Offending Commit
c6afc80fda feat(web): add shared Breadcrumb component for workspace pages
Replace ad-hoc back-arrow and inline breadcrumb markup in PeerList,
SessionList, SessionDetail, ConclusionBrowser, and WebhookManager with a
single router-aware Breadcrumb. Demo-aware via useDemo() so workspace
and entity IDs render masked when demo mode is active.
2026-05-15 14:25:41 -05:00
Offending Commit
f38ef4f4ee docs(agents): add codex agents guide
Mirror CLAUDE.md as AGENTS.md so Codex-family agents pick up the same
commands, structure, and constraints (sans CLAUDE-specific rule paths).
2026-05-15 14:25:41 -05:00
Offending Commit
96d96a7341 chore(fire-tools): upgrade stamp to v1.14.0
- Bump fire_tools_version from 1.13.2 to 1.14.0
- Upgrade pnpm/action-setup@v4 to @v6 in composite setup action
2026-05-15 14:24:01 -05:00
github-actions[bot]
e5349ed6e3 chore(release): 0.8.0 [skip ci]
# [0.8.0](https://github.com/offendingcommit/openconcho/compare/v0.7.1...v0.8.0) (2026-05-15)

### Features

* add health indicator and localhost auto-detect ([38e76d3](38e76d33de))
* add Honcho Cloud connection preset ([f071762](f0717624eb))
2026-05-15 03:07:43 +00:00
Offending Commit
403ee48b93 Merge pull request #11 from offendingcommit/claude/add-honcho-cloud-option-vk93o 2026-05-14 22:06:47 -05:00
Claude
38e76d33de feat: add health indicator and localhost auto-detect
Surfaces live connection health for the active instance in the sidebar
and probes localhost:8000 on the first-run choose-type screen so users
running Honcho locally can connect in one tap.

- useHealthStatus hook polls checkConnection every 30s via TanStack Query
- HealthDot component renders a colored status dot with tooltip
- choose-type screen silently probes http://localhost:8000 once; on
  success it surfaces a "Detected Honcho at localhost:8000 — tap to
  connect" banner that opens the self-hosted form
2026-05-14 23:50:03 +00:00
Claude
f0717624eb feat: add Honcho Cloud connection preset
Adds a "choose-type" step to the settings flow so users can pick between
Honcho Cloud (https://api.honcho.dev, API key required) and Self-Hosted
(URL + optional token) when creating a connection. Multi-instance support
already exists in the data layer, so cloud and self-hosted instances can
coexist.

- new HONCHO_CLOUD_URL constant and isCloudInstance helper in config.ts
- SettingsForm accepts a preset prop; cloud variant locks the endpoint
  and enforces an API key
- InstancesManager gains a ConnectionTypeChooser entry point and renders
  a Cloud icon for cloud instances in the list
- unit tests for both preset paths and cloud edit-mode detection
2026-05-14 23:21:28 +00:00
github-actions[bot]
4fc54a3581 chore(release): 0.7.1 [skip ci]
## [0.7.1](https://github.com/offendingcommit/openconcho/compare/v0.7.0...v0.7.1) (2026-05-12)

### Bug Fixes

* improve dark mode accessibility contrast ([7827438](7827438d92))
* show structured page placeholders while loading ([3075e4a](3075e4a005))
2026-05-12 16:07:18 +00:00
Offending Commit
1008e97683 Merge pull request #10 from offendingcommit/codex/page-loading-placeholders
[codex] Show structured page placeholders while loading
2026-05-12 11:06:22 -05:00
Offending Commit
4c5489915e ci: move desktop cargo check out of github actions 2026-05-12 10:46:35 -05:00
Offending Commit
5a430b4950 ci: cache apt packages for tauri linux deps 2026-05-12 10:18:56 -05:00
Offending Commit
57b7ff3ad3 Merge branch 'main' into codex/page-loading-placeholders
Signed-off-by: Offending Commit <offendingcommit@gmail.com>
2026-05-12 10:08:10 -05:00
Offending Commit
9cc7d08ea1 Merge pull request #9 from offendingcommit/codex/darkmode-accessibility
[codex] Improve dark mode accessibility contrast
2026-05-12 10:07:39 -05:00
Offending Commit
3075e4a005 fix: show structured page placeholders while loading 2026-05-12 10:05:00 -05:00
Offending Commit
7827438d92 fix: improve dark mode accessibility contrast 2026-05-12 09:49:27 -05:00
github-actions[bot]
3d1bb4c93c chore(release): 0.7.0 [skip ci]
# [0.7.0](https://github.com/offendingcommit/openconcho/compare/v0.6.0...v0.7.0) (2026-05-04)

### Features

* deep linking for hosted URLs and openconcho:// scheme ([578c8f4](578c8f4c46))
2026-05-04 16:36:23 +00:00
Offending Commit
a07adcbcbc Merge pull request #7 from offendingcommit/feat/deep-linking
feat: deep linking for hosted URLs and openconcho:// scheme
2026-05-04 11:33:25 -05:00
github-actions[bot]
387bfa4228 chore(release): 0.6.0 [skip ci]
# [0.6.0](https://github.com/offendingcommit/openconcho/compare/v0.5.3...v0.6.0) (2026-05-04)

### Features

* support multiple Honcho instances (closes [#2](https://github.com/offendingcommit/openconcho/issues/2)) ([f706c83](f706c83cc1))
2026-05-04 16:33:21 +00:00
Offending Commit
f9e26d42f1 Merge branch 'main' into feat/deep-linking 2026-05-04 11:31:55 -05:00
Offending Commit
ee76f7a325 Merge pull request #8 from offendingcommit/feat/multi-instance
feat: support multiple Honcho instances
2026-05-04 11:31:40 -05:00
Offending Commit
f706c83cc1 feat: support multiple Honcho instances (closes #2)
Replace single localStorage config with a named-instance store
({ instances: Instance[], activeId }). Adds an instances manager on
the settings page (list / add / edit / delete / activate) and a
sidebar switcher for quick swaps. Existing single-config users are
migrated transparently on first load.

Switching or deleting an instance clears the TanStack Query cache so
data from another deployment never bleeds into the active view.
2026-05-04 11:09:28 -05:00
Offending Commit
578c8f4c46 feat: deep linking for hosted URLs and openconcho:// scheme
Add /explore redirect route that maps Honcho's deep-link shape
(?workspace=...&view=...&session=...) onto our existing flat routes,
so any app.honcho.dev URL works against a self-hosted instance by
swapping the host.

Wire tauri-plugin-deep-link to register the openconcho:// scheme on
desktop and forward incoming URLs into the router on launch and at
runtime.
2026-05-04 10:12:25 -05:00
Offending Commit
2b0844d4d3 Merge pull request #6 from offendingcommit/docs/claude-md-refresh
chore(dx): refresh CLAUDE.md, consolidate commands behind make, add editor config
2026-05-03 17:20:07 -05:00
Offending Commit
3690cf0814 chore(dx): consolidate commands behind make + add editor config
- Make is the canonical interface; pnpm scripts wrap turbo, make wraps pnpm
- CI now calls `make ci-web` / `make ci-desktop` so local == CI
- Add .nvmrc (node 24, matches CI) + engines field
- Add .editorconfig and .vscode (extensions + settings)
- Add `pnpm bootstrap` (deps + Playwright Chromium)
- Add `dev:web` / `dev:desktop` shortcuts
- CONTRIBUTING.md: lead with `make bootstrap`/`make dev-web`,
  link Tauri prereqs, fix wrong `pnpm dev` claim
- CLAUDE.md: command table reflects make-first workflow
2026-05-03 17:18:09 -05:00
github-actions[bot]
7ff16f9548 chore(release): 0.5.3 [skip ci]
## [0.5.3](https://github.com/offendingcommit/openconcho/compare/v0.5.2...v0.5.3) (2026-05-03)

### Bug Fixes

* **release:** regenerate and commit Cargo.lock on release ([6f9abf8](6f9abf84ff))
* **web:** render sidebar on settings route ([557fecf](557fecf038))
* **web:** show settings on first load and hoist DemoProvider globally ([8f5a6aa](8f5a6aa7e9))
2026-05-03 22:17:20 +00:00
Offending Commit
4a69c7d2a9 docs(claude): refresh CLAUDE.md for monorepo reality
- Fix commands (pnpm dev runs Tauri; add web filter, typecheck, test:e2e)
- Add packages/{web,desktop} structure
- Note catalog, commitlint, semantic-release, gh account conventions
2026-05-03 17:11:29 -05:00
Offending Commit
0daeadfc9c Merge pull request #5 from offendingcommit/fix/release-cargo-lock
fix(release): regenerate and commit Cargo.lock on release
2026-05-03 17:10:17 -05:00
Offending Commit
6f9abf84ff fix(release): regenerate and commit Cargo.lock on release
Previously the release workflow updated Cargo.toml's version via sed
but never refreshed Cargo.lock, leaving it one version behind after
every release. Add cargo update for the openconcho package to the
prepareCmd, and add Cargo.lock to @semantic-release/git assets so it
ships in the release commit.

Also bumps the lagging 0.5.1 -> 0.5.2 lockfile entry that the
0.5.2 release missed.
2026-05-03 17:08:29 -05:00
Offending Commit
2c848d6f1c Merge pull request #1 from offendingcommit/fix/web-settings-and-demo-provider
fix(web): settings shows on first load + global DemoProvider
2026-05-03 17:05:39 -05:00
Offending Commit
34319db283 chore(test): catalog @playwright/test and wire e2e into turbo
- Promote @playwright/test to the workspace catalog
- Add test:e2e turbo task (uncached)
- Add root pnpm test:e2e script
- Vitest scopes to src/**/*.{test,spec} and excludes e2e/
2026-05-03 17:03:55 -05:00
Offending Commit
557fecf038 fix(web): render sidebar on settings route
Settings page was rendering Outlet directly, omitting the Sidebar nav.
Adds a playwright e2e test asserting sidebar visibility on both
dashboard and settings routes.
2026-05-03 16:58:43 -05:00
Offending Commit
784cbee870 style(web): fix biome import order in test files 2026-05-03 16:54:18 -05:00
Offending Commit
8f5a6aa7e9 fix(web): show settings on first load and hoist DemoProvider globally
Bug 1: On a fresh load with no saved config, RootLayout returned `null`
while a useEffect-driven `router.navigate()` fired, leaving a blank screen
until the user manually refreshed. Move the redirect into the root route's
`beforeLoad` so it happens synchronously during route resolution and the
settings form renders on first paint.

Bug 2: `DemoProvider` was mounted inside `RootLayout` only on the
non-settings branch, so any component reading `useDemo()` outside that
branch would throw "useDemoContext must be used within DemoProvider".
Hoist `<DemoProvider>` to `main.tsx` so the context is available app-wide.

Adds vitest + RTL setup with regression tests for both behaviours.
2026-05-03 16:41:59 -05:00
Offending Commit
3fa4d599fe docs: add OSS community health files
- CONTRIBUTING.md: contributor onboarding, conventional commit rules, local setup
- CODE_OF_CONDUCT.md: adopts Contributor Covenant 2.1 by reference
- SECURITY.md: vulnerability reporting via GitHub private advisories, scope boundaries
- .github/ISSUE_TEMPLATE/config.yml: disables blank issues, links to discussions and Honcho upstream

Lifts the GitHub community profile score from 57% toward 100%.
2026-05-01 09:57:57 -05:00
Offending Commit
2349a1d41d docs: bust camo cache on release/downloads/license badges
Camo had cached "repo not found" SVGs from before the repo had releases.
Adding query params changes the camo hash so GitHub re-fetches from shields.io.
2026-05-01 09:50:32 -05:00