Back to Projects
DOKUMENTASI TEKNIS

UNIVERSAL AUTOMATED
DOCUMENTATION ENGINE

DocuForge menganalisis project secara otomatis, mengubah struktur menjadi intermediate representation framework-agnostic, menyelesaikan hubungan antar komponen, dan menghasilkan dokumentasi teknis yang human-friendly.

Laravel — Plugin Generic Scanner TypeScript AST Monorepo Ready

Product Vision

DocuForge bukan sekadar Laravel documentation generator. Laravel hanyalah salah satu plugin. Target akhirnya adalah engine universal yang mendukung berbagai framework dan bahasa:

Web Frameworks

Laravel, Express, NestJS, FastAPI, Django, Spring Boot

Languages

TypeScript, JavaScript, Python, PHP, Java, Go, Rust

Output

Markdown, HTML, VS Code, OpenAPI, Mermaid, Static Site

Masalah yang Diselesaikan

Prinsip Inti

Scan once, understand everywhere.

Laravel / Express / FastAPI │ ▼ Scanner (Plugin) │ ▼ DFIR ← framework-agnostic │ ▼ Analyzer + Relationship Engine │ ▼ Documentation Generator │ ┌────┼────┐ Markdown HTML VS Code

High-level Architecture

DocuForge CLI
↓
Project Detector
↓
Laravel Scanner
Generic Scanner
Future Plugins
↓
DFIR
↓
Analyzer + Relationship Engine
↓
Generator
↓
Markdown
HTML
Future

Project Detector

Memilih scanner dengan confidence tertinggi. Specialized scanner always wins over generic scanner.

Plugin Architecture

interface Scanner {
  metadata(): PluginMetadata;
  detect(rootPath: string): Promise<DetectionResult> | DetectionResult;
  scan(ctx: ScanContext): Promise<DFIRDocument> | DFIRDocument;
}

Contoh package: @docuforge/plugin-laravel, @docuforge/plugin-generic, @docuforge/plugin-express, dll.

Scanner Layers (3 Level)

Level 1

Generic Project Scanner

Metadata, package manager, dependencies, directory structure, source files

Level 2

Language Analyzer

Classes, interfaces, functions, methods, imports, exports, types, enums, decorators

Level 3

Framework Scanner

Routes, controllers, models, middleware, services, jobs, events (per framework)

DocuForge Intermediate Representation

DFIR adalah bahasa universal antara scanner dan generator. Scanner boleh framework-specific, tapi output-nya harus framework-agnostic.

Evolusi DFIR

v0.1

Web-oriented

Route, Controller, Service, Model, Database, Dependencies, Relationships

Current
v0.2

Universal Source

File, Module, Class, Interface, Function, Method, Import, Export, Type, Enum

Next
v0.3

Architecture

Component, Package, Module, Dependency, Relationship, External System

v1.0

Stable Model

Universal documentation model yang stabil

Relationship Engine

Fitur inti. Contoh resolving:

route:POST:/courses → controller:CourseController → service:CourseService → model:Course → table:courses

Dari relationship ini DocuForge dapat menghasilkan architecture graph (Mermaid-ready).

Fitur Utama & Roadmap Fitur

CLI

docuforge generate .
Options: --output, --format, --watch, --verbose

Commands

init · detect · scan · generate · serve · watch · diff · check

Watch Mode

Incremental analysis: hanya file yang berubah di-scan ulang, relationship & docs di-update.

Drift Detection

Membandingkan source vs documentation (missing route, signature mismatch, dll).

Monorepo Support

Workspace, package, internal & external dependency (penting karena DocuForge sendiri monorepo).

Configuration

.docuforge.json + .docuforgeignore

VS Code Extension

Generate docs, open source location, explain file/function, show architecture.

Web UI (serve)

Dashboard, architecture graph, API explorer, dependency graph, search.

AI Integration

Opt-in. AI membaca DFIR + relationships untuk explain architecture, generate onboarding, summary.

Security & Privacy

Default: local analysis only. Source code tidak di-upload. AI bersifat opt-in.

Performance Target

Target Final Structure

docuforge/
├── packages/
│   ├── core/          (dfir, plugin, analyzer, relationship)
│   ├── generator/     (markdown, html, json)
│   └── cli/
├── plugins/
│   ├── generic/
│   ├── laravel/
│   ├── node / express /
│   ├── python / fastapi / django
│   └── spring /
├── apps/
│   └── docs-web/
└── extensions/
    └── vscode/

Development Phases

Phase 0

Foundation

DFIR, Plugin Interface, Registry, CLI, Markdown Generator, Laravel Scanner

Done
Phase 1

Universal MVP

Generic Scanner, Detection, Dependency Scan, TypeScript Analyzer, Monorepo

Current
Phase 2

TypeScript Intelligence

AST Parser → Classes, Functions, Interfaces, Imports/Exports + Relationship Engine

Phase 3

Framework Expansion

Express, NestJS, FastAPI, Django, Spring Boot

Phase 4

Documentation Web UI

docuforge serve — Dashboard, graphs, explorers

Phase 5–6

VS Code + AI

Extension + AI Assistant (explain, onboarding, drift detection)

Urutan Implementasi yang Sehat

Karena Generic Scanner sudah berhasil jalan, jangan loncat ke VS Code atau AI dulu.

Dengan milestone yang baru tercapai, DocuForge sudah resmi berubah dari “Laravel documentation tool” menjadi “universal documentation engine” secara arsitektur. Generic fallback adalah fondasi penting untuk itu.