NextWeb4 GitHub avatar

official-document-ai-assistant

NextWeb4

An Electron desktop workspace for local official-document review, formatting repair, and compliant export with optional Ollama AI analysis.

Stars

163

7-day growth

No data

Forks

0

Open issues

0

License

NOASSERTION

Last updated

2026-07-25

AI repository intelligence
FR-AI / ANALYSIS

Why it is worth attention

Combines rule-based checks and local AI in a desktop app that keeps data on device, supporting Chinese document workflows.

Who it is for

  • Chinese government or corporate document editors
  • Technical writers handling official documents
  • Developers needing a local document processing tool
  • Users requiring offline document formatting compliance

Use cases

  • Reviewing typography and spacing in official documents
  • Repairing formatting issues and applying templates
  • Exporting compliant .docx files after preview
  • Running local AI analysis for document quality

Strengths

  • Local-first data privacy
  • Rule-based review with customizable templates
  • Supports multiple Chinese document formats (.doc, .docx, .wps)
  • Optional Ollama integration for AI assistance

Considerations

  • Requires Node.js and Python for development setup
  • LibreOffice needed for legacy .doc/.wps conversion as separate install
  • Does not include third-party fonts; users must obtain legally

README quick start

HaoXiang Document Assistant

Local official-document review, formatting repair, preview, and compliant .docx export in an Electron desktop workspace.

The application combines an Electron 39 + React 19 + TypeScript interface with a Python 3.12+ FastAPI backend. It imports Word-family documents, converts them into a structured DocumentModel, applies YAML-backed review and repair rules, previews A4 output, and exports a new Word document. Chinese and English application interfaces are included, and project data stays on the local device by default.

Capabilities

  • Import .docx, .doc, and .wps documents and select the intended official-document type.
  • Review typography, paragraph spacing, margins, headings, tables, page fields, and other rule-backed formatting details.
  • Apply selected repairs through the document modifier instead of editing the source file in place.
  • Use official, custom, user, or uploaded .docx/.dotx templates as formatting sources.
  • Preview pages in an A4-oriented workspace and export the reviewed result as .docx.
  • Optionally request AI-assisted analysis. Offline builds expose local Ollama only; online-mode packages can use explicitly configured provider endpoints.
  • Use the Word VBA bridge for format checking, repair, and template actions while the local backend is running.
  • Switch the application UI between Chinese and English; the preference is stored locally.

Automated checks help find and repair formatting issues, but they do not replace human review, organizational policy, or an authoritative interpretation of an official-document standard.

Architecture

Electron / React UI
        |
        | local HTTP
        v
FastAPI on 127.0.0.1:8765
        |
        v
parser -> DocumentModel -> RuleEngine / Modifier -> generator -> .docx
              |                    |
              |                    +-- rules/official/*.yaml
              +-- templates and uploaded formatting bases
PathResponsibility
backend/api/routes/Document, review, optimization, template, settings, AI, and Office bridge endpoints
backend/core/document/Conversion, parsing, structured models, modification, validation, template application, and Word generation
backend/core/rules/Rule loading, merge precedence, checking, fixing, and runtime rule management
`backend/cor

Description

Local official-document review, formatting repair, and compliant export desktop assistant.

Related repositories

Similar projects matched by category, topics, and programming language.

lopopolo
Featured
lopopolo GitHub avatar

harness-engineering

Harness Engineering is a methodology for improving coding agent outputs by carefully crafting the environment around them—providing curated context, tools, and executable constraints that encode an organization’s nonfunctional requirements and cumulative lessons.

AI & Machine LearningAI Agents
2,390
slvDev
Featured
slvDev GitHub avatar

esp32-ai

A 28.9 million parameter language model runs on an $8 ESP32-S3 microcontroller entirely on-device, generating simple stories at about 9.5 tokens per second.

AI & Machine LearningLarge Language Models
1,960
littledivy
Featured
littledivy GitHub avatar

mimic

mimic captures traffic from any iOS or web app and automatically generates a Python client library that lets you call the app's API like a regular library.

AI & Machine Learning
1,482