Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,11 @@ every intra-repo Markdown anchor (`#x` and `path.md#x`) against the target's rea
version; and `checkCrosswalk` resolves every `.js`/`.sh` binding the research paper's
crosswalk (`research/formal-synthesis/crosswalk.json`) claims for this repo against the
files that actually exist in `src/`, `global/guards/`, and `hooks/` (kit-only names opt
out with a `kit:` prefix), so the paper's stated bindings can no longer trail the code. The two public pages
out with a `kit:` prefix), so the paper's stated bindings can no longer trail the code; and
`checkMintlify` extends the reconcile to the hand-maintained Mintlify site (`mintlify/`,
previously unchecked and prone to drift) — every command must be documented on the English
site as `forge <name>`, and any env var the site names must be one the code reads (no
phantom vars). The two public pages
(`landing/index.html` + the `build-pages.mjs` status page) derive from ONE color source —
`brand.json.colors` (full dark + light palettes), emitted as CSS by `src/brand.js`
(`rootTokensCss()`). `test/pages.test.js` enforces full-palette parity: every hex in
Expand Down Expand Up @@ -363,6 +367,11 @@ self-correction` (rules) · project-layer template.
**`forge init`** (one-command bootstrap) · **`cost-budget` guard** ·
**Start-Here catalog** · **`recall`** unified memory subsystem.

**Bundled skills (model-invoked, shipped in `global/tools/`):** beyond the reuse skills
above, `problem-solver` (a framework-driven Clarify → Classify → Diagnose → Generate →
Decide → Act cycle) and `catchup` (session re-orientation, pairs with `forge decide`) ship
as native skills through the plugin's `skills` directory.

## `atlas` — the code graph

`forge atlas build [path]` walks the tree and writes a **portable JSON artifact**,
Expand Down
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,20 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Changed

- **Synced the docs with the code and added a Mintlify drift guard.** `docs check` now has
a `checkMintlify` reconciler that reconciles the hand-maintained Mintlify site
(`mintlify/`) against the code the same way it already does README/GUIDE — every command
must be documented on the English site as `forge <name>`, and any env var the site names
must be one the code reads (no phantom vars). The site had drifted (it was outside the
reconciler) and is now brought current: the `FORGE_LEDGER_ONLY` default flip, the
`problem-solver` skill, the `forge dash` write guard, the `Labs (experimental)` command
group, and version-neutral wording (was "new in v0.19"). Top-level docs updated too —
`ROADMAP.md` (legacy-store retirement now shipped), a stale `forge cortex` sample in
`docs/GUIDE.md`, and the `ARCHITECTURE.md` tool map (adds `problem-solver`/`catchup`).
`mintlify/docs.json` locale code `zh` aligned with its `zh-CN/` directory.

## [0.27.1] - 2026-07-21

### Security
Expand Down
14 changes: 8 additions & 6 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,14 @@ confidence only from independent oracles, and merges across teammates conflict-f

## Next

- **Legacy store retirement** — the read-path flip has shipped: every read surface
(cortex injection/status, the substrate advisory, routing, `recall list`, brain's
AGENTS.md index) is now a merged view (legacy ∪ ledger) via `src/ledger_read.js`,
so teammate knowledge from `forge ledger merge` reaches injection. The legacy
formats (`lessons/*.md`, recall/brain fact files) are still written as the canonical
local state; the remaining step is retiring them so the ledger is the only store.
- **Legacy store retirement** — mostly shipped. The read-path flip (every read surface —
cortex injection/status, the substrate advisory, routing, `recall list`, brain's
AGENTS.md index — is a merged view (legacy ∪ ledger) via `src/ledger_read.js`) landed
first, and the **write default has now flipped too**: `FORGE_LEDGER_ONLY` defaults on, so
the legacy formats (`lessons/*.md`, recall/brain fact files) are no longer written and the
ledger is the sole store. `FORGE_LEDGER_ONLY=0` is a one-release escape hatch that restores
the file store. The only remaining step is deleting the now-dormant legacy write/read code
once that escape hatch is removed in a later release.
- **OpenAI + Gemini provider detection** — extend `autoDetectProvider()` beyond
Anthropic/OpenRouter/LiteLLM (`OPENAI_API_KEY`, `GEMINI_API_KEY`) with the same
guided, low-configuration auto-detect contract.
Expand Down
4 changes: 2 additions & 2 deletions docs/GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,7 @@ Forge cortex — self-correcting project memory

(no active lessons yet — Cortex learns from corrections as you work)

stored in .forge/lessons/ (git-committable, auditable)
stored in the .forge/ ledger (content-addressed, git-mergeable)
```

`forge cortex why <symbol>` shows the lessons that would be injected when you touch it.
Expand Down Expand Up @@ -1040,7 +1040,7 @@ Plain `forge cost` remains the per-day spend view via `ccusage`.
| `forge init` | Emit every tool's native config from one source. |
| `forge sync` | Recompile `source/` → each tool's files (idempotent). |
| `forge doctor` | Health check: layers, install, drift, cortex. `forge doctor --fix` auto-repairs the safely fixable findings (missing settings hooks/permissions, ledger union-merge rule, stale `AGENTS.md`, non-executable guards) by reusing the same idempotent functions `forge init`/`forge sync` use, then re-checks. |
| `forge docs check` | Docs↔code drift: commands, env vars, MCP tools, CHANGELOG reconciled against the code (CI-gated on the forge repo itself). |
| `forge docs check` | Docs↔code drift: commands, env vars, MCP tools, CHANGELOG, and the Mintlify site (`mintlify/`) reconciled against the code (CI-gated on the forge repo itself). |
| `forge docs sync` | Diff-driven stale-docs sweep: UPDATED / STALE (file:line hits) / VERIFIED-UNAFFECTED per artifact (see the full section above). |
| `forge docs impact` | Documentation-reference graph: extract typed entities (commands/flags/env/MCP/symbols/version), index every doc surface, and report which docs reference the entities THIS diff changed — ranked by confidence (see the full section above). |
| `forge catalog` | Start-Here index of every tool / crew / guard. |
Expand Down
6 changes: 3 additions & 3 deletions mintlify/ar/cli/config.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ forge cost --stages # measured per-stage cost factors
لوحة معلومات محلية فوق السجل والقياسات ونصف قطر الانفجار.

```bash
forge dash # localhost-only, read-only (default port 4242)
forge dash # localhost-only (default port 4242)
```

## `forge brand`
Expand Down Expand Up @@ -72,7 +72,7 @@ forge stack
وأُطر العمل، ومديري الحِزم، وأوامر الاختبار **الفعلية** للمستودع — التي تُغذّي قائمة
تحقق الركيزة.

## `forge report` <sub>v0.19+</sub>
## `forge report`

توليد تقرير HTML ثابت عن حالة Forge للمستودع — السجل والقياسات ونصف قطر الانفجار
مُصيَّرة في ملف مكتفٍ ذاتيًا يمكنك مشاركته أو أرشفته.
Expand All @@ -81,7 +81,7 @@ forge stack
forge report
```

## `forge tools` <sub>v0.19+</sub>
## `forge tools`

اختَر أداة الترميز الأساسية بالذكاء الاصطناعي لهذا المستودع، ووصِّل مدخلات `.gitignore`
المطابقة، ليتم تجاهل الإعدادات المُولَّدة وقطع `.forge/` تجاهلًا صحيحًا لإعدادك.
Expand Down
2 changes: 1 addition & 1 deletion mintlify/ar/cli/core.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ forge docs sync # diff-driven stale-docs sweep
```bash
forge update # apply the update (git checkout or npm/copy install)
forge update --check # report whether a newer version is available
forge update --to <version> # pin or downgrade to a specific version (v0.19+)
forge update --to <version> # pin or downgrade to a specific version
```

كل مسار يفشل بلطف — دون اتصال أو منبع أو رأس منفصل يُرجَع "غير معروف"، لا خطأ.
Expand Down
6 changes: 3 additions & 3 deletions mintlify/ar/cli/memory.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ forge ledger query "<text>" # retrieve by relevance
forge ledger ratify <id> # human accept
forge ledger retract <id> # tombstone a claim
forge ledger merge <path> # fold a teammate's ledger in, conflict-free
forge ledger import # bridge legacy stores into the ledger
forge ledger import # back-fill pre-ledger history into the ledger
```

أضف `--personal` للحصول على سجل خاص بالمستخدم.
Expand Down Expand Up @@ -88,7 +88,7 @@ forge decide "<decision> — <reason>"
forge decide # read the log before re-deciding
```

## `forge know` <sub>v0.19+</sub>
## `forge know`

توجيه حقيقة إلى موطن تخزينها الصحيح — يقرر ما إذا كانت المعرفة تنتمي إلى
`recall`، أو `remember`/`brain`، أو قرار، أو درس cortex، ويودعها هناك.
Expand All @@ -97,7 +97,7 @@ forge decide # read the log before re-deciding
forge know "<fact>"
```

## `forge deja` <sub>v0.19+</sub>
## `forge deja`

بحث عن أعمال سابقة مماثلة — يُظهر الأعمال السابقة في السجل التي تشبه ما توشك على
عمله، لتعيد استخدام الإثبات بدلًا من التوليد من جديد.
Expand Down
5 changes: 3 additions & 2 deletions mintlify/ar/cli/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,16 @@ description: "كل أمر من أوامر forge مُصنَّف حسب المجم
| `FORGE_NO_HINT=1` | كتم تلميح init المُعروض لمرة واحدة الذي يدفعك إلى تشغيل `forge init`. |
| `FORGE_VERBOSE=1` | إظهار عنوان الأمر (`Forge <cmd> — …`) المخفي افتراضيًا. |
| `FORGE_EMBED=1` | تفعيل طبقة التضمينات لاسترجاع الذاكرة (يبقى MinHash افتراضًا بدون تبعيات). |
| `FORGE_LEDGER_ONLY=0` | منفذ هروب. وضع «السجل فقط» هو الافتراضي — تعيش الذاكرة في `.forge/ledger` فقط، ولم تعد ملفات `lessons/*.md` وملفات الحقائق القديمة تُكتب. اضبطه على `0` لاستعادة مخزن الملفات القديم. |

<Note>
شغّل `forge --help` للقائمة المحدَّثة دائمًا، أو `forge catalog` لفهرس البدء لكل
أداة وطاقم وحاجز مع سبب موجز.
</Note>

## جديد في v0.19+
## أوامر وعلامات أحدث

عدة أوامر وعلامات تصل في خط v0.19. موثقة في صفحات مجموعاتها وموسومة داخل النص:
هذه الأوامر والعلامات متاحة. موثقة في صفحات مجموعاتها وموسومة داخل النص:

| الأمر / العلامة | المجموعة | ماذا يفعل |
| ---------------------- | -------- | ----------------------------------------------- |
Expand Down
8 changes: 4 additions & 4 deletions mintlify/ar/cli/quality.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "أوامر Quality"
description: "التحقق والسلامة: verify وscan وspec وtaste وuicheck وharden — إضافةً إلى بوّابتَي precommit وradar في الإصدار v0.19+."
description: "التحقق والسلامة: verify وscan وspec وtaste وuicheck وharden — إضافةً إلى بوّابتَي precommit وradar."
---

مجموعة Quality هي سطح التحقق والسلامة. راجع
Expand All @@ -12,7 +12,7 @@ description: "التحقق والسلامة: verify وscan وspec وtaste وuich

```bash
forge verify
forge verify --deep # multi-lens consensus (v0.19+)
forge verify --deep # multi-lens consensus
```

يُبلِّغ `forge verify --deep` عن `status` رباعي الحالات بدلًا من نجاح/إخفاق ثنائي:
Expand Down Expand Up @@ -76,7 +76,7 @@ forge uicheck visual <file-or-url> # Playwright-rendered check (opt-in tier)
forge harden
```

## `forge precommit` <sub>v0.19+</sub>
## `forge precommit`

بوّابة على مستوى الالتزام — تُشغّل الحد الأدنى للتحقق عند وقت الالتزام، فيُلتقط
العمل الجزئي أو غير المُتحقَّق منه قبل أن يستقر.
Expand All @@ -85,7 +85,7 @@ forge harden
forge precommit
```

## `forge radar` <sub>v0.19+</sub>
## `forge radar`

حلقات حداثة التبعيات — تُجمِّع تبعيات المشروع بحسب مدى حداثتها، ليظهر ما هو بائت أو
منحرف قبل أن يعضّ.
Expand Down
4 changes: 2 additions & 2 deletions mintlify/ar/concepts/verification-gates.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ forge verify --deep # multi-lens consensus — several independent checks
```

<Note>
يُصعّد `--deep` (v0.19+) إلى إجماع متعدد العدسات: يجب أن يجتاز التغيير عدة عدسات
يُصعّد `--deep` إلى إجماع متعدد العدسات: يجب أن يجتاز التغيير عدة عدسات
تحقق مستقلة، لا عدسة واحدة فقط.
</Note>

Expand Down Expand Up @@ -92,7 +92,7 @@ forge harden # gitleaks pre-commit + sandbox settings
## بوابة على مستوى الالتزام — `forge precommit`

<Note>
`forge precommit` (v0.19+) هي بوابة على مستوى الالتزام (commit) — تُشغّل الحد الأدنى للتحقق
`forge precommit` هي بوابة على مستوى الالتزام (commit) — تُشغّل الحد الأدنى للتحقق
وقت الالتزام حتى يُصطاد العمل الجزئي أو غير المُتحقَق منه قبل أن يهبط.
</Note>

Expand Down
2 changes: 1 addition & 1 deletion mintlify/ar/guides/radar-deps.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: "يجمع forge radar تبعياتك في حلقات حداثة (cu
---

<Note>
`forge radar` يهبط في خط v0.19. يصف هذا الدليل كيف يتناسب مع انضباط تحديث التبعيات القائم؛
`forge radar` متاح. يصف هذا الدليل كيف يتناسب مع انضباط تحديث التبعيات القائم؛
شغّل `forge --help` للتأكد من توفره في نسختك المثبتة.
</Note>

Expand Down
11 changes: 7 additions & 4 deletions mintlify/cli/config.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,13 @@ forge cost --stages # measured per-stage cost factors

## `forge dash`

Local dashboard over the ledger, metrics, and blast radius.
Local dashboard over the ledger, metrics, and blast radius. Read-mostly: the only writes
are the two human-driven actions `POST /api/ratify` and `POST /api/retract`, which are
guarded against CSRF and DNS-rebinding — a request must come from the loopback `Host` (and,
for a browser, a loopback `Origin`) or it is refused with `403`.

```bash
forge dash # localhost-only, read-only (default port 4242)
forge dash # localhost-only (default port 4242)
```

## `forge brand`
Expand Down Expand Up @@ -72,7 +75,7 @@ Reads `package.json`, `pyproject.toml`, `go.mod`, `Cargo.toml`, `Gemfile`,
frameworks, package managers, and the repo's **actual** test commands — which feed the
substrate's verification checklist.

## `forge report` <sub>v0.19+</sub>
## `forge report`

Generate a static HTML report of the repo's Forge state — the ledger, metrics, and blast
radius rendered to a self-contained file you can share or archive.
Expand All @@ -81,7 +84,7 @@ radius rendered to a self-contained file you can share or archive.
forge report
```

## `forge tools` <sub>v0.19+</sub>
## `forge tools`

Select this repo's primary AI coding tool and wire the matching `.gitignore` entries, so
generated config and `.forge/` artifacts are ignored correctly for your setup.
Expand Down
2 changes: 1 addition & 1 deletion mintlify/cli/core.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ Self-update across all three install modes.
```bash
forge update # apply the update (git checkout or npm/copy install)
forge update --check # report whether a newer version is available
forge update --to <version> # pin or downgrade to a specific version (v0.19+)
forge update --to <version> # pin or downgrade to a specific version
```

Every path is fail-open — offline, no upstream, or detached HEAD returns "unknown", never
Expand Down
Loading
Loading