Hysen Labs
Open-source project
sunyifeisb-art/legalwork avatar
sunyifeisb-art

legalwork

LegalWork - legal AI workbench

50 stars10 forksTypeScriptNOASSERTION
DEEP OPEN-SOURCE ANALYSIS

A legal AI workbench for Chinese law

LegalWork is an Electron desktop app that bundles legal skills, OCR, redaction, and verified law sources for lawyers.

What the workbench includes

LegalWork is a legal AI workbench aimed at legal professionals. The README is written in Chinese and describes a platform that brings several capabilities into one desktop application. The interface is built with Electron and React, and the agent runtime communicates over HTTP or SSE and uses the Model Context Protocol, or MCP. The README states the app runs on macOS, Windows, and Linux. The skill library is large: the badges report 1260 skills in total, made up of 79 core legal AI skills and an extended store of 1182. A knowledge base of 326 files backs the legal reasoning. For documents, the app uses two OCR engines, PaddleOCR and Tesseract, and it performs PDF redaction by blacking out sensitive text at the pixel level. For source material it reaches external law sources, including the national laws and regulations database at flk.npc.gov.cn, plus commercial services named in the README. The stated goal is to support OCR document recognition, sensitive information masking, case analysis, legal search, document generation, and compliance review as a complete set of legal AI abilities. That scope places it closer to a practice tool than a single purpose chatbot, since a lawyer can move from reading a scanned filing to drafting a compliant document within the same environment.

Recent stability and accuracy work

The README devotes a long changelog to recent versions, and version 0.3.29 is described in detail. That release focused on making the agent runtime more stable. The fixes cover an SSE first connection timeout at the edge, misreported failures when the runtime restarts or drops briefly, repeated JSON output during learning iterations, and a startup race in the document skill. On research accuracy, the update makes the national laws database prefer an explicit law name, so a query like the civil code article five hundred eighty five hits the correct code instead of a vague match. It also stops forcing online search when the user says it is not needed. On document writing, the app now treats only facts that the user, an attachment, or a verified source explicitly provides as certain, and it no longer fills in missing acceptance, reminder, quality objection, amount, or date fields on its own. Version 0.3.27 added the ability to keep working without a network: if a live search fails, the agent falls back to attachments and the local knowledge base and marks only truly live dependent content as needing verification. These notes show a project paying attention to factual boundaries and to not inventing details, which matters in legal work where a wrong auto filled value has real consequences.

Platform and licensing notes

The desktop app targets the three major operating systems, and the README shows badges for macOS, Windows, and Linux alongside the Electron and React stack. The agent runtime's HTTP, SSE, and MCP design means the models and tools are reached through a local or configured server rather than hardcoded to one provider, and the changelog mentions support for a vision model that reads images directly instead of relying only on OCR text extraction. The Filesystem MCP was changed to start locally and offline by default, which reduces reliance on pulling packages from npm at every launch and avoids connection timeouts when the registry is flaky. The plugin market distinguishes a unavailable network from a real authentication or configuration error, so recoverable states no longer show as hard failures. On licensing, the README badge states PolyForm Noncommercial 1.0.0, which permits use, modification, and sharing but forbids commercial use without a separate agreement. That is an important limit for a law firm thinking of deploying it, since billable internal use may still count as commercial under the license terms. The TypeScript codebase and the active changelog suggest steady development, but the noncommercial license is the fact a potential user must weigh before adopting it.

Editorial conclusion

The project is published under the PolyForm Noncommercial 1.0.0 license and is written in TypeScript.

DEEP OPEN-SOURCE ANALYSIS

Official sources

Community notes

Community notes