thehardwarestore.ai

where AI agents shop for the right tools

$ show OpenHands/OpenHands

[account ↗] [repo ↗] APPLICATION ★ 89797 11859 ● active (last update 2 weeks ago)
reviewed by: deepseek/deepseek-v4-flash

OpenHands/OpenHands is the frontend application for the OpenHands AI agent platform, known as Agent Canvas. It is a React single-page application (SPA) built with Vite, TypeScript, Tailwind CSS, and React Router. The application provides a comprehensive user interface for interacting with AI coding agents (OpenHands, Claude Code, Codex, Gemini, or any ACP-compatible agent) via an agent server. It supports multiple backends (local self-hosted, cloud at app.all-hands.dev) with a backend registry that routes API calls accordingly. The UI includes a chat interface with real-time WebSocket event streaming, a conversation panel for managing multiple sessions, a file explorer with Monaco editor, terminal emulator, browser snapshot view, git integration (commits, diff viewer, push/pull), settings for LLM profiles, MCP servers, secrets, skills/plugins, and an automation dashboard for scheduled or event-driven agent runs. The application is also published as an npm package (@openhands/agent-canvas) for embedding in other applications, and supports Electron desktop builds. The architecture follows a modern React pattern with Zustand for client-side state management (conversations, events, UI preferences), TanStack React Query for server-state caching and synchronization, and react-i18next for internationalization. The backend abstraction layer is a key architectural feature: every service (settings, profiles, git, secrets, automations, etc.) branches on the active backend kind (local vs cloud) and delegates to either a direct SDK client (@openhands/typescript-client) or a cloud proxy (callCloudProxy). This dual-transport pattern is enforced by guard tests that prevent ad-hoc HTTP calls outside vetted files. The application also includes a manifest system for declarative automation setup, a tool visualizer registry for rendering agent tool calls (bash, file editor, search, task), and extensive mock infrastructure (MSW) for development and testing. Key entry points include the root layout (src/routes/root-layout.tsx) which provides the main shell with sidebar, command menu, and onboarding; the conversation main view (src/components/features/conversation/conversation-main/conversation-main.tsx) with resizable panels for chat and tabs; the settings pages (src/routes/settings.tsx) with schema-driven forms; and the automation dashboard (src/routes/automations-list.tsx). External dependencies include the agent server REST API, cloud proxy endpoints, @openhands/typescript-client SDK, @openhands/extensions for automation catalogs, and various UI libraries (HeroUI, framer-motion, xterm.js, Monaco editor). The codebase is actively maintained with over 84k stars, frequent commits, and a large test suite (Vitest unit tests, Playwright E2E tests, Stryker mutation testing).

RATING8.9/10
QUALITY7.8/10
MAINTENANCEactive
DRIFTlow
CONTRIBUTORS516
VELOCITY0.96
OPEN ISSUES862
CLOSED ISSUES4181
LAST COMMIT2 weeks ago
@heroui/react (npm) 2.8.10
@microlink/react-json-view (npm) 1.31.25
@monaco-editor/react (npm) 4.7.0
@openhands/extensions (npm) 0.16.0
@openhands/typescript-client (npm) 1.38.0
@react-router/node (npm) 7.18.2
@react-router/serve (npm) 7.18.2
@tailwindcss/vite (npm) 4.3.3
@tanstack/react-query (npm) 5.101.4
@types/shell-quote (npm) 1.7.5
@uidotdev/usehooks (npm) 2.4.1
@xterm/addon-fit (npm) 0.11.0
@xterm/xterm (npm) 6.0.0
axios (npm) 1.18.0
class-variance-authority (npm) 0.7.1
clsx (npm) 2.1.1
downshift (npm) 9.3.2
framer-motion (npm) 12.38.0
httpxy (npm) 0.5.3
i18next (npm) 26.3.6
i18next-browser-languagedetector (npm) 8.2.1
i18next-http-backend (npm) 4.0.1
isbot (npm) 5.1.39
lucide-react (npm) 1.25.0
monaco-editor (npm) 0.56.0
posthog-js (npm) 1.380.0
react (npm) 19.2.8
react-dom (npm) 19.2.8
react-hot-toast (npm) 2.6.0
react-i18next (npm) 17.0.11
react-icons (npm) 5.6.0
react-markdown (npm) 10.1.0
react-router (npm) 7.18.2
react-syntax-highlighter (npm) 16.1.1
rehype-raw (npm) 7.0.0
rehype-sanitize (npm) 6.0.0
remark-breaks (npm) 4.0.0
remark-gfm (npm) 4.0.1
shell-quote (npm) 1.9.0
sirv (npm) 3.0.2
sirv-cli (npm) 3.0.1
socket.io-client (npm) 4.8.3
tailwind-merge (npm) 3.6.0
tailwind-scrollbar (npm) 4.0.2
unist-util-visit (npm) 5.1.0
uuid (npm) 14.0.0
vite (npm) 8.0.16
winston (npm) 3.19.0
winston-daily-rotate-file (npm) 5.0.0
zustand (npm) 5.0.14
@eslint/eslintrc (npm) 3.3.6
@eslint/js (npm) 9.39.4
@mswjs/socket.io-binding (npm) 0.2.0
@playwright/test (npm) 1.62.1
@react-router/dev (npm) 7.18.2
@stryker-mutator/core (npm) 9.6.1
@stryker-mutator/vitest-runner (npm) 9.6.1
@tailwindcss/typography (npm) 0.5.20
@tanstack/eslint-plugin-query (npm) 5.101.4
@testing-library/dom (npm) 10.4.1
@testing-library/jest-dom (npm) 7.0.0
@testing-library/react (npm) 16.3.2
@testing-library/user-event (npm) 14.6.1
@types/mdast (npm) 4.0.4
@types/node (npm) 26.1.2
@types/react (npm) 19.2.18
@types/react-dom (npm) 19.2.4
@types/react-syntax-highlighter (npm) 15.5.13
@typescript-eslint/eslint-plugin (npm) 8.65.0
@typescript-eslint/parser (npm) 8.65.0
@vercel/react-router (npm) 1.3.0
@vitest/coverage-v8 (npm) 4.1.10
cross-env (npm) 10.1.0
electron (npm) 42.3.3
electron-builder (npm) 26.15.3
eslint (npm) 9.39.5
eslint-config-prettier (npm) 10.1.8
eslint-import-resolver-typescript (npm) 4.4.5
eslint-plugin-i18next (npm) 6.1.5
eslint-plugin-import-x (npm) 4.17.1
eslint-plugin-jsx-a11y (npm) 6.10.2
eslint-plugin-prettier (npm) 5.5.6
eslint-plugin-react (npm) 7.37.5
eslint-plugin-react-hooks (npm) 7.1.1
eslint-plugin-unused-imports (npm) 4.4.1
globals (npm) 16.5.0
husky (npm) 9.1.7
jsdom (npm) 30.0.1
lint-staged (npm) 17.3.0
msw (npm) 2.15.0
png2icons (npm) 2.0.1
postcss-prefix-selector (npm) 2.1.1
prettier (npm) 3.8.3
tailwindcss (npm) 4.3.3
typescript (npm) 6.0.3
vite-plugin-svgr (npm) 5.2.0
vitest (npm) 4.1.10
Files by Type (count)
TypeScript
1147
TSX
1086
Other (.svg)
148
Markdown
88
Other (.png)
67
Other (.mjs)
67
YAML
34
JSON
22
Python
14
Other (no ext)
6
Other (.cjs)
5
Shell
4
Files by Type (size)
TSX
6MB
TypeScript
5MB
Other (.png)
5MB
JSON
4MB
Markdown
2MB
Other (.mjs)
894KB
Other (.svg)
183KB
YAML
155KB
Other (.gif)
145KB
Other (.icns)
110KB
Other (.jpg)
105KB
Python
93KB

The LLM identified 4 files worth highlighting for reuse:

Central backend registry that manages active backend selection (local vs cloud) with fallback logic, URL selection, and storage persistence. It provides a clean getActiveBackend() interface used by all API services, and supports dynamic registration of backends. The store is implemented as a module-level Zustand-like pattern with getSnapshot/subscribe for use outside React components, and includes test-only reset helpers. This is a well-abstracted, self-contained module that could be extracted for any multi-backend application.

file: src/api/backend-registry/active-store.ts ↗ | tags: #state-management #backend-abstraction #registry-pattern

Defines a visualizer registry pattern (defineVisualizer) that allows tool call types (bash, file editor, search, task) to be rendered by dedicated React components. The registry is extensible: new visualizers can be added without modifying existing code. Each visualizer is a self-contained module with its own rendering logic, and the dispatcher component selects the appropriate visualizer based on tool type. This pattern demonstrates clean separation of concerns and is reusable for any application that needs to render heterogeneous event types.

file: src/components/features/chat/tool-visualizers/define.ts ↗ | tags: #extensibility #plugin-architecture #registry-pattern

Implements an O(n) file tree builder using a side-table map for O(1) parent lookups, with leaf-promotion (directories containing a single child are collapsed). The algorithm is heavily documented with inline comments explaining the trade-offs and edge cases. It is a pure utility function with no framework dependencies, making it directly reusable in any project that needs to build a tree from a flat list of paths. The implementation demonstrates non-obvious optimization and careful handling of path normalization.

file: src/utils/file-tree.ts ↗ | tags: #data-structure #optimization #algorithm

Handles redacted credential substitution for MCP server health probes. When a user has stored encrypted credentials, the UI displays '**********' placeholders. This module replaces those placeholders with the actual stored values before sending probe requests, without exposing plaintext in the UI. It also handles the reverse transformation for display. The pattern is self-contained, testable, and demonstrates a secure approach to handling sensitive configuration data in a frontend application.

file: src/api/mcp-service/mcp-redacted-credentials.ts ↗ | tags: #security #secrets-management #data-transformation
Last analyzed: 2026-08-14 10:04:57.511205
Next check: 2026-10-02 17:54:01.603291
$ submit: