Skip to content

Turn any idea, plan, or codebase into a beautiful interactive diagram. An agent skill for Claude Code, Codex, and more.

feat(website): add gated Cloudflare Pages deployment (#766)

tt-a1i8a061bfb2c5c
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 2873f334..d24ed192 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -363,11 +363,31 @@ jobs:
ARCHIFY_SITE_INTEGRATION: '1'
ARCHIFY_CHROME: ${{ steps.website-chrome.outputs.chrome-path }}
ARCHIFY_CHROME_NO_SANDBOX: '1'
+ - name: Build and validate the Cloudflare static website
+ run: npm run build && node scripts/check-cloudflare-output.mjs && node --test test/deployment-target.test.mjs
+ working-directory: website
+ env:
+ ARCHIFY_SITE_TARGET: cloudflare
+ - name: Verify Cloudflare navigation and language continuity
+ run: npm run test:browser
+ working-directory: website
+ env:
+ ARCHIFY_SITE_ROOT: ${{ github.workspace }}/website/dist-cloudflare
+ ARCHIFY_SITE_BASE: ''
+ ARCHIFY_SITE_INTEGRATION: '1'
+ ARCHIFY_CHROME: ${{ steps.website-chrome.outputs.chrome-path }}
+ ARCHIFY_CHROME_NO_SANDBOX: '1'
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
with:
name: website-dist
path: website/dist
include-hidden-files: true
+ - uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
+ with:
+ name: website-cloudflare-dist
+ path: website/dist-cloudflare
+ include-hidden-files: true
+ if-no-files-found: error
windows-test-portability:
needs: scope
@@ -458,3 +478,63 @@ jobs:
if: steps.deployment-head.outputs.current == 'true'
id: deployment
uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0
+
+ # Enable after configuring a Pages project with production branch main.
+ # Disable Git-connected automatic deployments so they cannot bypass these gates.
+ deploy-cloudflare:
+ if: github.event_name == 'push' && github.ref == 'refs/heads/main' && vars.CLOUDFLARE_PAGES_PROJECT != ''
+ needs: [test, webm-artifact, zip-freshness, published-update-manifest, package-smoke, windows-test-portability, website]
+ runs-on: ubuntu-latest
+ concurrency:
+ group: cloudflare-pages
+ cancel-in-progress: false
+ permissions:
+ contents: read
+ environment:
+ name: cloudflare-pages
+ url: ${{ steps.deployment.outputs.deployment-url }}
+ steps:
+ - uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5.1.0
+ with:
+ persist-credentials: false
+ - uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
+ with:
+ node-version: 22
+ - name: Validate Cloudflare destination
+ env:
+ CLOUDFLARE_PAGES_PROJECT: ${{ vars.CLOUDFLARE_PAGES_PROJECT }}
+ CLOUDFLARE_ACCOUNT_ID: ${{ vars.CLOUDFLARE_ACCOUNT_ID }}
+ shell: bash
+ run: |
+ [[ "$CLOUDFLARE_PAGES_PROJECT" =~ ^[a-z0-9][a-z0-9-]{0,57}[a-z0-9]$ ]] || exit 1
+ [[ "$CLOUDFLARE_ACCOUNT_ID" =~ ^[0-9a-f]{32}$ ]] || exit 1
+ # Wrangler also discovers Functions relative to its working directory.
+ test ! -e functions
+ - name: Download verified Cloudflare website build
+ uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
+ with:
+ name: website-cloudflare-dist
+ path: website/dist-cloudflare
+ - name: Reject an obsolete deployment run
+ id: deployment-head
+ env:
+ GH_TOKEN: ${{ github.token }}
+ shell: bash
+ run: |
+ current_main="$(gh api "repos/${GITHUB_REPOSITORY}/git/ref/heads/main" --jq '.object.sha')"
+ if [[ "$current_main" == "$GITHUB_SHA" ]]; then
+ echo 'current=true' >> "$GITHUB_OUTPUT"
+ else
+ echo 'current=false' >> "$GITHUB_OUTPUT"
+ echo "::notice::Skipping obsolete Cloudflare deployment for ${GITHUB_SHA}; main is ${current_main}"
+ fi
+ - name: Deploy verified Cloudflare website
+ if: steps.deployment-head.outputs.current == 'true'
+ id: deployment
+ uses: cloudflare/wrangler-action@953926a2e2182532811c01a25e53647d93bf07c0 # v4.1.3
+ with:
+ apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
+ accountId: ${{ vars.CLOUDFLARE_ACCOUNT_ID }}
+ wranglerVersion: '4.148.0'
+ packageManager: npm
+ command: pages deploy website/dist-cloudflare --project-name=${{ vars.CLOUDFLARE_PAGES_PROJECT }} --branch=main --commit-hash=${{ github.sha }}
diff --git a/.gitignore b/.gitignore
index 2be3b0cb..f5fda7db 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,6 +1,7 @@
.DS_Store
.harnessed/
node_modules/
+.wrangler/
.claude/
.lore/
/.impeccable/
diff --git a/README.md b/README.md
index 401fd5b9..a81c55da 100644
--- a/README.md
+++ b/README.md
@@ -13,9 +13,9 @@
<p align="center">See what the community is creating—and imagine what you could make next.</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/gallery.html"><strong>Live demos</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/gallery.html"><strong>Live demos</strong></a> &nbsp;·&nbsp;
<a href="#start"><strong>Get started</strong></a> &nbsp;·&nbsp;
- <a href="https://tt-a1i.github.io/archify/guide.html"><strong>Scenario guide</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/guide.html"><strong>Scenario guide</strong></a> &nbsp;·&nbsp;
<a href="#community"><strong>Community</strong></a> &nbsp;·&nbsp;
<a href="./README_ZH.md"><strong>简体中文</strong></a> &nbsp;·&nbsp;
<a href="./README_JA.md"><strong>日本語</strong></a>
@@ -34,7 +34,7 @@
</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
+ <a href="https://archify.si/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
<a href="https://discord.gg/6xWMjgCeUq"><img src="https://img.shields.io/badge/Discord-5865F2?style=for-the-badge&amp;logo=discord&amp;logoColor=white" alt="Join Archify on Discord" /></a>
<a href="#community"><img src="https://img.shields.io/badge/WeChat-07C160?style=for-the-badge&amp;logo=wechat&amp;logoColor=white" alt="Archify WeChat group" /></a>
<a href="#community"><img src="https://img.shields.io/badge/QQ-1688D8?style=for-the-badge&amp;logo=qq&amp;logoColor=white" alt="Archify QQ group" /></a>
@@ -49,7 +49,7 @@
https://github.com/user-attachments/assets/78570807-ba1d-4737-953f-55504a378a87
-**One sentence. Your repo, mapped.** Watch the 35-second demo: explore the diagram, follow source links, and trace a path. [Try the interactive examples ↗](https://tt-a1i.github.io/archify/gallery.html)
+**One sentence. Your repo, mapped.** Watch the 35-second demo: explore the diagram, follow source links, and trace a path. [Try the interactive examples ↗](https://archify.si/gallery.html)
<a id="start"></a>
@@ -72,7 +72,7 @@ Then continue: “Add authentication”, “Highlight the cache-miss path”, or
**No repository is required:** start with a description, or ask your agent to read a repository for a source-backed architecture diagram.
-[Choose your agent](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture) · [Installation details and update checks](#quick-start)
+[Choose your agent](https://archify.si/start.html?agent=cursor&type=architecture) · [Installation details and update checks](#quick-start)
<a id="sponsors"></a>
@@ -102,18 +102,18 @@ Then continue: “Add authentication”, “Highlight the cache-miss path”, or
| Explain an agent workflow | Follow a cache miss | Explore service relationships |
|---|---|---|
-| [![Agent workflow tracing everything the planner drives](docs/assets/archify-demo-reach.png)](https://tt-a1i.github.io/archify/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![Cache-miss sequence showing the Web App to Postgres route](docs/assets/archify-demo-route.png)](https://tt-a1i.github.io/archify/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![Production architecture comparing backend and database roles](docs/assets/archify-demo-lens.png)](https://tt-a1i.github.io/archify/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
+| [![Agent workflow tracing everything the planner drives](docs/assets/archify-demo-reach.png)](https://archify.si/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![Cache-miss sequence showing the Web App to Postgres route](docs/assets/archify-demo-route.png)](https://archify.si/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![Production architecture comparing backend and database roles](docs/assets/archify-demo-lens.png)](https://archify.si/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
| Trace everything downstream of one step. | Highlight the path from web app to database. | Focus on authored backend and database connections. |
-The [Proof Lab](https://tt-a1i.github.io/archify/gallery.html) contains all 11 checked-in scenarios, their JSON sources, and validation receipts.
+The [Proof Lab](https://archify.si/gallery.html) contains all 11 checked-in scenarios, their JSON sources, and validation receipts.
### Understand a real repository
<sub>CODE → DIAGRAM · A source-backed system map</sub>
-[![MCO runtime architecture generated from the public mco-org/mco repository](docs/assets/mco-runtime-share-card.png)](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)
+[![MCO runtime architecture generated from the public mco-org/mco repository](docs/assets/mco-runtime-share-card.png)](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)
-Archify traced [`mco-org/mco`](https://github.com/mco-org/mco) at `9f1a1cf` and produced this checked map. **[Open it ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [trace reach ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [typed source](docs/cases/mco-runtime.architecture.json)
+Archify traced [`mco-org/mco`](https://github.com/mco-org/mco) at `9f1a1cf` and produced this checked map. **[Open it ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [trace reach ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [typed source](docs/cases/mco-runtime.architecture.json)
### Easy to extend. More ways to make it yours.
@@ -125,11 +125,11 @@ One user started with a hand-drawn multi-agent architecture, turned it into an i
Another user turned a Shanghai CityWalk guide into a four-day itinerary: switch between days, inspect a stop, and jump to Amap, Xiaohongshu, or Dianping. The author also added arrival check-ins and stop notes, turning the itinerary into a small tool to use during the trip. These extensions were added by the community author for this particular artifact.
-**[▶ Explore the interactive Shanghai CityWalk](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)**
+**[▶ Explore the interactive Shanghai CityWalk](https://archify.si/cases/community/shanghai-citywalk.html)**
-[![A community-created four-day Shanghai CityWalk itinerary](docs/assets/community/shanghai-citywalk.png)](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)
+[![A community-created four-day Shanghai CityWalk itinerary](docs/assets/community/shanghai-citywalk.png)](https://archify.si/cases/community/shanghai-citywalk.html)
-**[▶ Try the interactive version](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · Switch between D1–D4 and click a place to explore.
+**[▶ Try the interactive version](https://archify.si/cases/community/shanghai-citywalk.html)** · Switch between D1–D4 and click a place to explore.
<sub>Community artifact · Shanghai CityWalk · Four days of routes and place links</sub>
@@ -137,7 +137,7 @@ Another user turned a Shanghai CityWalk guide into a four-day itinerary: switch
The output is a self-contained HTML file. Download it and open it in your browser to use the node details and path exploration included in that artifact. No Archify installation is needed to view it. Send the HTML to someone else and the interactions go with it; external websites and map links need a network connection.
-**[Explore the Shanghai CityWalk ↗](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · **[Download HTML ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
+**[Explore the Shanghai CityWalk ↗](https://archify.si/cases/community/shanghai-citywalk.html)** · **[Download HTML ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
<sub>Try switching between D1–D4, opening a place card, or following a map link. Times and place information reflect the author's original itinerary.</sub>
@@ -203,7 +203,7 @@ npx skills use tt-a1i/archify@archify --agent codex
[DSH community opt-in](integrations/deepseek-harness/README.md): `dsh plugin --profile web add @tt-a1i/[email protected]`
-The [agent switcher](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture) covers `cursor`, `codex`, `claude-code`, and `opencode`.
+The [agent switcher](https://archify.si/start.html?agent=cursor&type=architecture) covers `cursor`, `codex`, `claude-code`, and `opencode`.
Archify may GET the fixed stable manifest solely to show an optional reminder; it never downloads or installs updates. Successful checks wait about 24 hours (±20%); active use retries failures after 6, then 24 hours. The server sees normal HTTP metadata (IP and time), but receives no version, Agent, project data, prompts, account/device ID, or ETag. You decide whether and when to update. Set `ARCHIFY_UPDATE_CHECK_DISABLED=1` to disable networking and reminder-state writes.
@@ -249,7 +249,7 @@ Continue with focused requests such as `add Redis`, `move auth to the left`, or
| **Data Flow** | Pipelines, lineage, PII, consumers | Sources, transforms, stores, boundaries |
| **Lifecycle** | States, retries, waits, terminal outcomes | States, events, retry and cancellation paths |
-Architecture's optional `deployment-ownership` profile fails closed when authored owners, region placement, private database scope, or named crossings are missing; it is never implicit and does not inspect live infrastructure. See the [checked deployment proof](https://tt-a1i.github.io/archify/gallery.html#proof-deployment-ownership).
+Architecture's optional `deployment-ownership` profile fails closed when authored owners, region placement, private database scope, or named crossings are missing; it is never implicit and does not inspect live infrastructure. See the [checked deployment proof](https://archify.si/gallery.html#proof-deployment-ownership).
For design or PR review, Architecture Delta compares validated Before / Delta / After snapshots with a machine receipt. Select an authored change or play one finite, viewer-only Review; it infers no impact, risk, or merge safety.
@@ -257,7 +257,7 @@ For design or PR review, Architecture Delta compares validated Before / Delta /
[![Architecture Delta showing added, removed, changed, and moved authored facts](docs/assets/architecture-delta-proof.jpg)](examples/checkout-platform-delta.html)
-Not sure which one fits? Use the [interactive scenario guide](https://tt-a1i.github.io/archify/guide.html), or ask the zero-dependency CLI:
+Not sure which one fits? Use the [interactive scenario guide](https://archify.si/guide.html), or ask the zero-dependency CLI:
```bash
node archify/bin/archify.mjs guide "Show an API request with Redis cache miss"
@@ -391,7 +391,7 @@ The complete generation and viewer contract lives in [`archify/SKILL.md`](archif
- [Schema reference](archify/schemas/README.md) · [Skill](archify/SKILL.md) · [Examples](archify/examples/) · [Agent cookbook](docs/authoring-cookbook.md)
- [Changelog](CHANGELOG.md)
- [Roadmap](ROADMAP.md)
-- [Generated Proof Lab](https://tt-a1i.github.io/archify/gallery.html)
+- [Generated Proof Lab](https://archify.si/gallery.html)
Automatic Mermaid parsing, general-purpose auto-layout, hosted sharing, and WYSIWYG editing are intentionally outside the current scope.
diff --git a/README_EN.md b/README_EN.md
index 401fd5b9..a81c55da 100644
--- a/README_EN.md
+++ b/README_EN.md
@@ -13,9 +13,9 @@
<p align="center">See what the community is creating—and imagine what you could make next.</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/gallery.html"><strong>Live demos</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/gallery.html"><strong>Live demos</strong></a> &nbsp;·&nbsp;
<a href="#start"><strong>Get started</strong></a> &nbsp;·&nbsp;
- <a href="https://tt-a1i.github.io/archify/guide.html"><strong>Scenario guide</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/guide.html"><strong>Scenario guide</strong></a> &nbsp;·&nbsp;
<a href="#community"><strong>Community</strong></a> &nbsp;·&nbsp;
<a href="./README_ZH.md"><strong>简体中文</strong></a> &nbsp;·&nbsp;
<a href="./README_JA.md"><strong>日本語</strong></a>
@@ -34,7 +34,7 @@
</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
+ <a href="https://archify.si/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
<a href="https://discord.gg/6xWMjgCeUq"><img src="https://img.shields.io/badge/Discord-5865F2?style=for-the-badge&amp;logo=discord&amp;logoColor=white" alt="Join Archify on Discord" /></a>
<a href="#community"><img src="https://img.shields.io/badge/WeChat-07C160?style=for-the-badge&amp;logo=wechat&amp;logoColor=white" alt="Archify WeChat group" /></a>
<a href="#community"><img src="https://img.shields.io/badge/QQ-1688D8?style=for-the-badge&amp;logo=qq&amp;logoColor=white" alt="Archify QQ group" /></a>
@@ -49,7 +49,7 @@
https://github.com/user-attachments/assets/78570807-ba1d-4737-953f-55504a378a87
-**One sentence. Your repo, mapped.** Watch the 35-second demo: explore the diagram, follow source links, and trace a path. [Try the interactive examples ↗](https://tt-a1i.github.io/archify/gallery.html)
+**One sentence. Your repo, mapped.** Watch the 35-second demo: explore the diagram, follow source links, and trace a path. [Try the interactive examples ↗](https://archify.si/gallery.html)
<a id="start"></a>
@@ -72,7 +72,7 @@ Then continue: “Add authentication”, “Highlight the cache-miss path”, or
**No repository is required:** start with a description, or ask your agent to read a repository for a source-backed architecture diagram.
-[Choose your agent](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture) · [Installation details and update checks](#quick-start)
+[Choose your agent](https://archify.si/start.html?agent=cursor&type=architecture) · [Installation details and update checks](#quick-start)
<a id="sponsors"></a>
@@ -102,18 +102,18 @@ Then continue: “Add authentication”, “Highlight the cache-miss path”, or
| Explain an agent workflow | Follow a cache miss | Explore service relationships |
|---|---|---|
-| [![Agent workflow tracing everything the planner drives](docs/assets/archify-demo-reach.png)](https://tt-a1i.github.io/archify/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![Cache-miss sequence showing the Web App to Postgres route](docs/assets/archify-demo-route.png)](https://tt-a1i.github.io/archify/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![Production architecture comparing backend and database roles](docs/assets/archify-demo-lens.png)](https://tt-a1i.github.io/archify/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
+| [![Agent workflow tracing everything the planner drives](docs/assets/archify-demo-reach.png)](https://archify.si/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![Cache-miss sequence showing the Web App to Postgres route](docs/assets/archify-demo-route.png)](https://archify.si/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![Production architecture comparing backend and database roles](docs/assets/archify-demo-lens.png)](https://archify.si/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
| Trace everything downstream of one step. | Highlight the path from web app to database. | Focus on authored backend and database connections. |
-The [Proof Lab](https://tt-a1i.github.io/archify/gallery.html) contains all 11 checked-in scenarios, their JSON sources, and validation receipts.
+The [Proof Lab](https://archify.si/gallery.html) contains all 11 checked-in scenarios, their JSON sources, and validation receipts.
### Understand a real repository
<sub>CODE → DIAGRAM · A source-backed system map</sub>
-[![MCO runtime architecture generated from the public mco-org/mco repository](docs/assets/mco-runtime-share-card.png)](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)
+[![MCO runtime architecture generated from the public mco-org/mco repository](docs/assets/mco-runtime-share-card.png)](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)
-Archify traced [`mco-org/mco`](https://github.com/mco-org/mco) at `9f1a1cf` and produced this checked map. **[Open it ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [trace reach ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [typed source](docs/cases/mco-runtime.architecture.json)
+Archify traced [`mco-org/mco`](https://github.com/mco-org/mco) at `9f1a1cf` and produced this checked map. **[Open it ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [trace reach ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [typed source](docs/cases/mco-runtime.architecture.json)
### Easy to extend. More ways to make it yours.
@@ -125,11 +125,11 @@ One user started with a hand-drawn multi-agent architecture, turned it into an i
Another user turned a Shanghai CityWalk guide into a four-day itinerary: switch between days, inspect a stop, and jump to Amap, Xiaohongshu, or Dianping. The author also added arrival check-ins and stop notes, turning the itinerary into a small tool to use during the trip. These extensions were added by the community author for this particular artifact.
-**[▶ Explore the interactive Shanghai CityWalk](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)**
+**[▶ Explore the interactive Shanghai CityWalk](https://archify.si/cases/community/shanghai-citywalk.html)**
-[![A community-created four-day Shanghai CityWalk itinerary](docs/assets/community/shanghai-citywalk.png)](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)
+[![A community-created four-day Shanghai CityWalk itinerary](docs/assets/community/shanghai-citywalk.png)](https://archify.si/cases/community/shanghai-citywalk.html)
-**[▶ Try the interactive version](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · Switch between D1–D4 and click a place to explore.
+**[▶ Try the interactive version](https://archify.si/cases/community/shanghai-citywalk.html)** · Switch between D1–D4 and click a place to explore.
<sub>Community artifact · Shanghai CityWalk · Four days of routes and place links</sub>
@@ -137,7 +137,7 @@ Another user turned a Shanghai CityWalk guide into a four-day itinerary: switch
The output is a self-contained HTML file. Download it and open it in your browser to use the node details and path exploration included in that artifact. No Archify installation is needed to view it. Send the HTML to someone else and the interactions go with it; external websites and map links need a network connection.
-**[Explore the Shanghai CityWalk ↗](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · **[Download HTML ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
+**[Explore the Shanghai CityWalk ↗](https://archify.si/cases/community/shanghai-citywalk.html)** · **[Download HTML ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
<sub>Try switching between D1–D4, opening a place card, or following a map link. Times and place information reflect the author's original itinerary.</sub>
@@ -203,7 +203,7 @@ npx skills use tt-a1i/archify@archify --agent codex
[DSH community opt-in](integrations/deepseek-harness/README.md): `dsh plugin --profile web add @tt-a1i/[email protected]`
-The [agent switcher](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture) covers `cursor`, `codex`, `claude-code`, and `opencode`.
+The [agent switcher](https://archify.si/start.html?agent=cursor&type=architecture) covers `cursor`, `codex`, `claude-code`, and `opencode`.
Archify may GET the fixed stable manifest solely to show an optional reminder; it never downloads or installs updates. Successful checks wait about 24 hours (±20%); active use retries failures after 6, then 24 hours. The server sees normal HTTP metadata (IP and time), but receives no version, Agent, project data, prompts, account/device ID, or ETag. You decide whether and when to update. Set `ARCHIFY_UPDATE_CHECK_DISABLED=1` to disable networking and reminder-state writes.
@@ -249,7 +249,7 @@ Continue with focused requests such as `add Redis`, `move auth to the left`, or
| **Data Flow** | Pipelines, lineage, PII, consumers | Sources, transforms, stores, boundaries |
| **Lifecycle** | States, retries, waits, terminal outcomes | States, events, retry and cancellation paths |
-Architecture's optional `deployment-ownership` profile fails closed when authored owners, region placement, private database scope, or named crossings are missing; it is never implicit and does not inspect live infrastructure. See the [checked deployment proof](https://tt-a1i.github.io/archify/gallery.html#proof-deployment-ownership).
+Architecture's optional `deployment-ownership` profile fails closed when authored owners, region placement, private database scope, or named crossings are missing; it is never implicit and does not inspect live infrastructure. See the [checked deployment proof](https://archify.si/gallery.html#proof-deployment-ownership).
For design or PR review, Architecture Delta compares validated Before / Delta / After snapshots with a machine receipt. Select an authored change or play one finite, viewer-only Review; it infers no impact, risk, or merge safety.
@@ -257,7 +257,7 @@ For design or PR review, Architecture Delta compares validated Before / Delta /
[![Architecture Delta showing added, removed, changed, and moved authored facts](docs/assets/architecture-delta-proof.jpg)](examples/checkout-platform-delta.html)
-Not sure which one fits? Use the [interactive scenario guide](https://tt-a1i.github.io/archify/guide.html), or ask the zero-dependency CLI:
+Not sure which one fits? Use the [interactive scenario guide](https://archify.si/guide.html), or ask the zero-dependency CLI:
```bash
node archify/bin/archify.mjs guide "Show an API request with Redis cache miss"
@@ -391,7 +391,7 @@ The complete generation and viewer contract lives in [`archify/SKILL.md`](archif
- [Schema reference](archify/schemas/README.md) · [Skill](archify/SKILL.md) · [Examples](archify/examples/) · [Agent cookbook](docs/authoring-cookbook.md)
- [Changelog](CHANGELOG.md)
- [Roadmap](ROADMAP.md)
-- [Generated Proof Lab](https://tt-a1i.github.io/archify/gallery.html)
+- [Generated Proof Lab](https://archify.si/gallery.html)
Automatic Mermaid parsing, general-purpose auto-layout, hosted sharing, and WYSIWYG editing are intentionally outside the current scope.
diff --git a/README_JA.md b/README_JA.md
index 8bb5cf94..6316cf8e 100644
--- a/README_JA.md
+++ b/README_JA.md
@@ -13,9 +13,9 @@
<p align="center">コミュニティが何を作っているかを見て、自分なら次に何を作れるかを考えてみてください。</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/gallery.html"><strong>ライブデモ</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/gallery.html"><strong>ライブデモ</strong></a> &nbsp;·&nbsp;
<a href="#start"><strong>使ってみる</strong></a> &nbsp;·&nbsp;
- <a href="https://tt-a1i.github.io/archify/guide.html"><strong>シナリオガイド</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/guide.html"><strong>シナリオガイド</strong></a> &nbsp;·&nbsp;
<a href="#コミュニティ"><strong>コミュニティ</strong></a> &nbsp;·&nbsp;
<a href="./README.md"><strong>English</strong></a> &nbsp;·&nbsp;
<a href="./README_ZH.md"><strong>简体中文</strong></a>
@@ -34,7 +34,7 @@
</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
+ <a href="https://archify.si/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
<a href="https://discord.gg/6xWMjgCeUq"><img src="https://img.shields.io/badge/Discord-5865F2?style=for-the-badge&amp;logo=discord&amp;logoColor=white" alt="Join Archify on Discord" /></a>
<a href="#コミュニティ"><img src="https://img.shields.io/badge/WeChat-07C160?style=for-the-badge&amp;logo=wechat&amp;logoColor=white" alt="Archify WeChat group" /></a>
<a href="#コミュニティ"><img src="https://img.shields.io/badge/QQ-1688D8?style=for-the-badge&amp;logo=qq&amp;logoColor=white" alt="Archify QQ group" /></a>
@@ -47,7 +47,7 @@
https://github.com/user-attachments/assets/78570807-ba1d-4737-953f-55504a378a87
-**ひと言で、リポジトリを可視化。** 約35秒の英語デモで、図の操作、ソースコードへのリンク、経路の追跡をご覧ください。[インタラクティブな作例を試す ↗](https://tt-a1i.github.io/archify/gallery.html)
+**ひと言で、リポジトリを可視化。** 約35秒の英語デモで、図の操作、ソースコードへのリンク、経路の追跡をご覧ください。[インタラクティブな作例を試す ↗](https://archify.si/gallery.html)
<a id="start"></a>
@@ -70,7 +70,7 @@ the API checks Redis, and a cache miss queries PostgreSQL and fills the cache.
**リポジトリは不要です:** 説明から始めることも、リポジトリを読ませてソースに基づくアーキテクチャ図を作らせることもできます。
-[エージェントを選ぶ](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture) · [インストールの詳細と更新チェック](#クイックスタート)
+[エージェントを選ぶ](https://archify.si/start.html?agent=cursor&type=architecture) · [インストールの詳細と更新チェック](#クイックスタート)
## ❤️ スポンサー
@@ -92,18 +92,18 @@ the API checks Redis, and a cache miss queries PostgreSQL and fills the cache.
| エージェントのワークフローを説明する | キャッシュミスを追う | サービス間の関係を調べる |
|---|---|---|
-| [![プランナーから下流をすべてたどるエージェントワークフロー](docs/assets/archify-demo-reach.png)](https://tt-a1i.github.io/archify/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![Web アプリから Postgres への経路を示すキャッシュミスのシーケンス](docs/assets/archify-demo-route.png)](https://tt-a1i.github.io/archify/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![バックエンドとデータベースのロールを比較する本番アーキテクチャ](docs/assets/archify-demo-lens.png)](https://tt-a1i.github.io/archify/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
+| [![プランナーから下流をすべてたどるエージェントワークフロー](docs/assets/archify-demo-reach.png)](https://archify.si/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![Web アプリから Postgres への経路を示すキャッシュミスのシーケンス](docs/assets/archify-demo-route.png)](https://archify.si/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![バックエンドとデータベースのロールを比較する本番アーキテクチャ](docs/assets/archify-demo-lens.png)](https://archify.si/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
| 1 つのステップから下流をすべてたどります。 | Web アプリからデータベースまでの経路を強調します。 | 記述されたバックエンドとデータベースの接続に絞って見ます。 |
-[Proof Lab](https://tt-a1i.github.io/archify/gallery.html) には、チェックイン済みの 11 シナリオすべてと、その JSON ソース、検証レシートが含まれています。
+[Proof Lab](https://archify.si/gallery.html) には、チェックイン済みの 11 シナリオすべてと、その JSON ソース、検証レシートが含まれています。
### 実際のリポジトリを理解する
<sub>CODE → DIAGRAM · ソースに基づくシステムマップ</sub>
-[![公開リポジトリ mco-org/mco から生成した MCO ランタイムアーキテクチャ](docs/assets/mco-runtime-share-card.png)](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)
+[![公開リポジトリ mco-org/mco から生成した MCO ランタイムアーキテクチャ](docs/assets/mco-runtime-share-card.png)](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)
-Archify は [`mco-org/mco`](https://github.com/mco-org/mco) の `9f1a1cf` を解析し、この検証済みマップを生成しました。**[開く ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [到達範囲をトレース ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [型付きソース](docs/cases/mco-runtime.architecture.json)
+Archify は [`mco-org/mco`](https://github.com/mco-org/mco) の `9f1a1cf` を解析し、この検証済みマップを生成しました。**[開く ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [到達範囲をトレース ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [型付きソース](docs/cases/mco-runtime.architecture.json)
### 拡張しやすい。自分のものにする方法はいくつもある。
@@ -115,11 +115,11 @@ Archify は [`mco-org/mco`](https://github.com/mco-org/mco) の `9f1a1cf` を解
上海 CityWalk のガイドを 4 日間の行程表に変えたユーザーもいます。日ごとに切り替え、立ち寄り先を確認し、Amap・Xiaohongshu・Dianping へ飛べます。作者は到着時のチェックインや立ち寄り先のメモも追加し、旅行中に使える小さなツールに仕立てました。これらの拡張は、この成果物のためにコミュニティの作者自身が加えたものです。
-**[▶ インタラクティブな上海 CityWalk を見る](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)**
+**[▶ インタラクティブな上海 CityWalk を見る](https://archify.si/cases/community/shanghai-citywalk.html)**
-[![コミュニティが作成した 4 日間の上海 CityWalk 行程表](docs/assets/community/shanghai-citywalk.png)](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)
+[![コミュニティが作成した 4 日間の上海 CityWalk 行程表](docs/assets/community/shanghai-citywalk.png)](https://archify.si/cases/community/shanghai-citywalk.html)
-**[▶ インタラクティブ版を試す](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · D1〜D4 を切り替え、場所をクリックして探索できます。
+**[▶ インタラクティブ版を試す](https://archify.si/cases/community/shanghai-citywalk.html)** · D1〜D4 を切り替え、場所をクリックして探索できます。
<sub>コミュニティ成果物 · 上海 CityWalk · 4 日分のルートと場所のリンク</sub>
@@ -127,7 +127,7 @@ Archify は [`mco-org/mco`](https://github.com/mco-org/mco) の `9f1a1cf` を解
出力は単体で完結する HTML ファイルです。ダウンロードしてブラウザで開けば、その成果物に含まれるノードの詳細と経路の探索をそのまま使えます。閲覧に Archify のインストールは必要ありません。HTML を誰かに送れば操作性もそのまま届きます。外部サイトや地図のリンクにはネットワーク接続が必要です。
-**[上海 CityWalk を見る ↗](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · **[HTML をダウンロード ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
+**[上海 CityWalk を見る ↗](https://archify.si/cases/community/shanghai-citywalk.html)** · **[HTML をダウンロード ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
<sub>D1〜D4 の切り替え、場所カードを開く、地図リンクをたどる、といった操作を試してみてください。時刻や場所の情報は作者の元の行程に基づいています。</sub>
@@ -193,7 +193,7 @@ npx skills use tt-a1i/archify@archify --agent codex
[DSH コミュニティ版(任意)](integrations/deepseek-harness/README.md): `dsh plugin --profile web add @tt-a1i/[email protected]`
-[エージェント切り替え](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture)は `cursor`、`codex`、`claude-code`、`opencode` に対応しています。
+[エージェント切り替え](https://archify.si/start.html?agent=cursor&type=architecture)は `cursor`、`codex`、`claude-code`、`opencode` に対応しています。
Archify は固定の安定版マニフェストを GET して任意の更新リマインダーを表示することがありますが、更新をダウンロードしたりインストールしたりすることはありません。チェックに成功すると次回まで約 24 時間(±20%)待機し、失敗した場合はアクティブに使用していれば 6 時間後、その後は 24 時間後に再試行します。サーバーが受け取るのは通常の HTTP メタデータ(IP と時刻)だけで、バージョン、Agent、プロジェクトデータ、プロンプト、アカウント/デバイス ID、ETag は送信されません。更新するかどうか、いつ更新するかは常にあなたが決めます。`ARCHIFY_UPDATE_CHECK_DISABLED=1` を設定すると、ネットワーク通信とリマインダー状態の書き込みを無効化できます。
@@ -231,7 +231,7 @@ Put supporting detail in cards instead of adding more edges.
| **Data Flow** | パイプライン、リネージ、PII、コンシューマ | ソース、変換、ストア、境界 |
| **Lifecycle** | 状態、リトライ、待機、終端結果 | 状態、イベント、リトライとキャンセルの経路 |
-Architecture の任意プロファイル `deployment-ownership` は、記述されたオーナー、リージョン配置、データベースのプライベートスコープ、名前付きの境界越えが欠けている場合は fail-closed で停止します。暗黙的に有効化されることはなく、ライブのインフラを検査することもありません。[検証済みのデプロイ実証](https://tt-a1i.github.io/archify/gallery.html#proof-deployment-ownership)を参照してください。
+Architecture の任意プロファイル `deployment-ownership` は、記述されたオーナー、リージョン配置、データベースのプライベートスコープ、名前付きの境界越えが欠けている場合は fail-closed で停止します。暗黙的に有効化されることはなく、ライブのインフラを検査することもありません。[検証済みのデプロイ実証](https://archify.si/gallery.html#proof-deployment-ownership)を参照してください。
設計や PR のレビューでは、Architecture Delta が検証済みの Before / Delta / After スナップショットを機械可読なレシート付きで比較します。記述された変更を選ぶか、有限でビューア専用の Review を 1 つ再生してください。影響度・リスク・マージ安全性を推測することはありません。
@@ -239,7 +239,7 @@ Architecture の任意プロファイル `deployment-ownership` は、記述さ
[![追加・削除・変更・移動された記述済みの事実を示す Architecture Delta](docs/assets/architecture-delta-proof.jpg)](examples/checkout-platform-delta.html)
-どれを選べばよいか分からない場合は、[インタラクティブなシナリオガイド](https://tt-a1i.github.io/archify/guide.html)を使うか、依存関係ゼロの CLI に尋ねてください:
+どれを選べばよいか分からない場合は、[インタラクティブなシナリオガイド](https://archify.si/guide.html)を使うか、依存関係ゼロの CLI に尋ねてください:
```bash
node archify/bin/archify.mjs guide "Show an API request with Redis cache miss"
@@ -373,7 +373,7 @@ node bin/archify.mjs deliver workflow examples/agent-tool-call.workflow.json /tm
- [スキーマリファレンス](archify/schemas/README.md) · [Skill](archify/SKILL.md) · [サンプル](archify/examples/) · [エージェント向けクックブック](docs/authoring-cookbook.md)
- [変更履歴](CHANGELOG.md)
- [ロードマップ](ROADMAP.md)
-- [生成された Proof Lab](https://tt-a1i.github.io/archify/gallery.html)
+- [生成された Proof Lab](https://archify.si/gallery.html)
Mermaid の自動パース、汎用オートレイアウト、ホスティング型の共有、WYSIWYG 編集は、現時点では意図的にスコープ外としています。
diff --git a/README_ZH.md b/README_ZH.md
index f111c48a..c63d3a5a 100644
--- a/README_ZH.md
+++ b/README_ZH.md
@@ -13,9 +13,9 @@
<p align="center">看看社区正在创造什么,也想想你还能用它做些什么。</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/gallery.html"><strong>交互演示</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/gallery.html"><strong>交互演示</strong></a> &nbsp;·&nbsp;
<a href="#start"><strong>开始使用</strong></a> &nbsp;·&nbsp;
- <a href="https://tt-a1i.github.io/archify/guide.html"><strong>场景指南</strong></a> &nbsp;·&nbsp;
+ <a href="https://archify.si/guide.html"><strong>场景指南</strong></a> &nbsp;·&nbsp;
<a href="#社区交流"><strong>社区交流</strong></a> &nbsp;·&nbsp;
<a href="./README.md"><strong>English</strong></a> &nbsp;·&nbsp;
<a href="./README_JA.md"><strong>日本語</strong></a>
@@ -34,7 +34,7 @@
</p>
<p align="center">
- <a href="https://tt-a1i.github.io/archify/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
+ <a href="https://archify.si/"><img src="https://img.shields.io/badge/Website-0891B2?style=for-the-badge" alt="Archify website" /></a>
<a href="https://discord.gg/6xWMjgCeUq"><img src="https://img.shields.io/badge/Discord-5865F2?style=for-the-badge&amp;logo=discord&amp;logoColor=white" alt="Join Archify on Discord" /></a>
<a href="#社区交流"><img src="https://img.shields.io/badge/WeChat-07C160?style=for-the-badge&amp;logo=wechat&amp;logoColor=white" alt="Archify WeChat group" /></a>
<a href="#社区交流"><img src="https://img.shields.io/badge/QQ-1688D8?style=for-the-badge&amp;logo=qq&amp;logoColor=white" alt="Archify QQ group" /></a>
@@ -49,7 +49,7 @@
https://github.com/user-attachments/assets/88cff7dd-bdf3-4b97-950c-37cc079898b1
-**一句话,看懂你的项目。** 35 秒演示:探索交互图、查看源码关联、追踪完整路径。[试试可交互示例 ↗](https://tt-a1i.github.io/archify/gallery.html)
+**一句话,看懂你的项目。** 35 秒演示:探索交互图、查看源码关联、追踪完整路径。[试试可交互示例 ↗](https://archify.si/gallery.html)
<a id="start"></a>
@@ -72,7 +72,7 @@ API 优先读取 Redis,缓存未命中时查询 PostgreSQL 并回填缓存。
**不需要绑定代码库:**从描述开始即可。也可以让 Agent 阅读仓库,生成有源码依据的架构图。
-[按 Agent 选择安装方式](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture) · [安装细节与更新检查](#快速开始)
+[按 Agent 选择安装方式](https://archify.si/start.html?agent=cursor&type=architecture) · [安装细节与更新检查](#快速开始)
<a id="sponsors"></a>
@@ -102,18 +102,18 @@ API 优先读取 Redis,缓存未命中时查询 PostgreSQL 并回填缓存。
| 讲清 Agent 如何调用工具 | 跟随一次缓存回源请求 | 看清服务与数据库的关系 |
|---|---|---|
-| [![Agent 工作流中 Planner 驱动的全部下游](docs/assets/archify-demo-reach.png)](https://tt-a1i.github.io/archify/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![缓存未命中时从 Web App 到 Postgres 的路径](docs/assets/archify-demo-route.png)](https://tt-a1i.github.io/archify/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![生产架构中后端与数据库角色的真实关系](docs/assets/archify-demo-lens.png)](https://tt-a1i.github.io/archify/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
+| [![Agent 工作流中 Planner 驱动的全部下游](docs/assets/archify-demo-reach.png)](https://archify.si/gallery/artifacts/agent-tool-call.workflow.html?theme=dark&present=1#focus=planner&reach=downstream) | [![缓存未命中时从 Web App 到 Postgres 的路径](docs/assets/archify-demo-route.png)](https://archify.si/gallery/artifacts/cache-miss.sequence.html?theme=dark&present=1#route=web~db) | [![生产架构中后端与数据库角色的真实关系](docs/assets/archify-demo-lens.png)](https://archify.si/gallery/artifacts/production-deployment.architecture.html?theme=dark&present=1#lens=backend~database) |
| 追踪一个步骤影响到的全部下游。 | 点亮 Web App 到数据库的路径。 | 聚焦后端与数据库之间已定义的连接。 |
-[Proof Lab](https://tt-a1i.github.io/archify/gallery.html) 收录全部 11 个仓库内场景、JSON 源和校验回执。
+[Proof Lab](https://archify.si/gallery.html) 收录全部 11 个仓库内场景、JSON 源和校验回执。
### 看懂一个真实代码仓库
<sub>CODE → DIAGRAM · 有源码依据的系统地图</sub>
-[![根据公开仓库 mco-org/mco 生成的 MCO 运行时架构图](docs/assets/mco-runtime-share-card.png)](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)
+[![根据公开仓库 mco-org/mco 生成的 MCO 运行时架构图](docs/assets/mco-runtime-share-card.png)](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)
-Archify 追踪 [`mco-org/mco`](https://github.com/mco-org/mco) 的 `9f1a1cf` 版本并生成这张校验地图。**[打开成品 ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [追踪下游 ↗](https://tt-a1i.github.io/archify/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [Typed Source](docs/cases/mco-runtime.architecture.json)
+Archify 追踪 [`mco-org/mco`](https://github.com/mco-org/mco) 的 `9f1a1cf` 版本并生成这张校验地图。**[打开成品 ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark&present=1)** · [追踪下游 ↗](https://archify.si/cases/mco-runtime.architecture.html?theme=dark#focus=router&reach=downstream) · [Typed Source](docs/cases/mco-runtime.architecture.json)
### 易于扩展,社区还在不断创造新用法
@@ -125,11 +125,11 @@ Archify 追踪 [`mco-org/mco`](https://github.com/mco-org/mco) 的 `9f1a1cf` 版
还有用户把上海 CityWalk 攻略整理成了四天行程图:按天切换路线,点击节点查看地点信息,并跳转高德地图、小红书和大众点评。作者还扩展了到达打卡和停留记录,让一张路线图变成旅途中可以实际使用的小工具。这些扩展由社区作者为该作品添加。
-**[▶ 点击体验上海 CityWalk 交互版](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)**
+**[▶ 点击体验上海 CityWalk 交互版](https://archify.si/cases/community/shanghai-citywalk.html)**
-[![社区用户创作的上海 CityWalk 四天行程图](docs/assets/community/shanghai-citywalk.png)](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)
+[![社区用户创作的上海 CityWalk 四天行程图](docs/assets/community/shanghai-citywalk.png)](https://archify.si/cases/community/shanghai-citywalk.html)
-**[▶ 点击体验交互版](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · 切换 D1–D4 行程,点击地点查看详情。
+**[▶ 点击体验交互版](https://archify.si/cases/community/shanghai-citywalk.html)** · 切换 D1–D4 行程,点击地点查看详情。
<sub>社区作品 · 上海 CityWalk · 四天行程与地点链接</sub>
@@ -137,7 +137,7 @@ Archify 追踪 [`mco-org/mco`](https://github.com/mco-org/mco) 的 `9f1a1cf` 版
成品是一个独立的 HTML 文件。下载后用浏览器打开,即可使用该作品包含的节点详情和路径探索,无需安装 Archify。把 HTML 文件发给别人,交互也会一起保留;外部网站和地图链接需要网络。
-**[打开上海 CityWalk 交互版 ↗](https://tt-a1i.github.io/archify/cases/community/shanghai-citywalk.html)** · **[下载 HTML ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
+**[打开上海 CityWalk 交互版 ↗](https://archify.si/cases/community/shanghai-citywalk.html)** · **[下载 HTML ↓](https://github.com/tt-a1i/archify/raw/refs/heads/main/docs/cases/community/shanghai-citywalk.html)**
<sub>试试切换 D1–D4、点击地点卡片,或打开地图链接。行程中的时间和地点信息为作者创作时的记录。</sub>
@@ -201,9 +201,9 @@ npx -y skills add tt-a1i/archify --skill archify --agent cursor --global --copy
npx skills use tt-a1i/archify@archify --agent codex
```
-DeepSeek Harness(社区集成、显式启用):运行 `dsh plugin --profile web add @tt-a1i/[email protected]`;参见[兼容范围、限制与安全说明](integrations/deepseek-harness/README.md)。[Agent 切换器](https://tt-a1i.github.io/archify/start.html?agent=cursor&type=architecture)只为 `cursor`、`codex`、`claude-code` 和 `opencode` 生成命令。
+DeepSeek Harness(社区集成、显式启用):运行 `dsh plugin --profile web add @tt-a1i/[email protected]`;参见[兼容范围、限制与安全说明](integrations/deepseek-harness/README.md)。[Agent 切换器](https://archify.si/start.html?agent=cursor&type=architecture)只为 `cursor`、`codex`、`claude-code` 和 `opencode` 生成命令。
-安装后的 Skill 包含一个低频、失败静默的发布检查,它最多只显示可选更新提醒,绝不会自行下载或安装更新。一次成功检查后,下次网络请求通常约在 24 小时(±20%)后发出;检查失败后,活跃使用可能在首次 6 小时、后续 24 小时退避到期时重试。请求只访问 `https://tt-a1i.github.io/archify/skill-updates/archify/stable.json`。服务端会自然获得 IP、请求时间和常规 HTTP 元数据;检查器不会发送本地版本、Agent、项目数据、用户输入、账户/设备标识,也不会保存或回传 ETag。是否更新以及何时更新始终由你决定。如需完全关闭检查(包括网络请求和提醒状态写入),请在 Agent 环境中设置 `ARCHIFY_UPDATE_CHECK_DISABLED=1`。
+安装后的 Skill 包含一个低频、失败静默的发布检查,它最多只显示可选更新提醒,绝不会自行下载或安装更新。一次成功检查后,下次网络请求通常约在 24 小时(±20%)后发出;检查失败后,活跃使用可能在首次 6 小时、后续 24 小时退避到期时重试。请求只访问 `https://archify.si/skill-updates/archify/stable.json`。服务端会自然获得 IP、请求时间和常规 HTTP 元数据;检查器不会发送本地版本、Agent、项目数据、用户输入、账户/设备标识,也不会保存或回传 ETag。是否更新以及何时更新始终由你决定。如需完全关闭检查(包括网络请求和提醒状态写入),请在 Agent 环境中设置 `ARCHIFY_UPDATE_CHECK_DISABLED=1`。
</details>
@@ -250,7 +250,7 @@ DeepSeek Harness(社区集成、显式启用):运行 `dsh plugin --profile
做生产部署评审时,Architecture 可以按需启用 `deployment-ownership`
工程画像:负责人、单一区域归属、数据库私有边界或边界穿越机制缺失时会直接阻断。
它不会被静默开启,只校验作者写入的事实,不代表线上基础设施已经核验。可查看
-[通过校验的部署证明](https://tt-a1i.github.io/archify/gallery.html#proof-deployment-ownership)。
+[通过校验的部署证明](https://archify.si/gallery.html#proof-deployment-ownership)。
做设计或 PR 评审时,Architecture Delta 生成已校验的 Before / Delta / After 和机器回执。精确选择任一作者变更,或播放一次有限 Review;全程只读,不推断影响、风险或合并安全。
@@ -258,7 +258,7 @@ DeepSeek Harness(社区集成、显式启用):运行 `dsh plugin --profile
[![Architecture Delta:展示作者明确写出的新增、删除、变化和移动](docs/assets/architecture-delta-proof.jpg)](examples/checkout-platform-delta.html)
-不知道选哪一种?打开[交互式场景指南](https://tt-a1i.github.io/archify/guide.html),或直接询问零依赖 CLI:
+不知道选哪一种?打开[交互式场景指南](https://archify.si/guide.html),或直接询问零依赖 CLI:
```bash
node archify/bin/archify.mjs guide "展示带 Redis 缓存未命中的 API 请求"
@@ -395,7 +395,7 @@ node bin/archify.mjs deliver workflow examples/agent-tool-call.workflow.json /tm
- [Agent 编图手册](docs/authoring-cookbook.zh-CN.md) · [English](docs/authoring-cookbook.md)
- [版本历史](CHANGELOG.md)
- [路线图](ROADMAP.md)
-- [自动生成的 Proof Lab](https://tt-a1i.github.io/archify/gallery.html)
+- [自动生成的 Proof Lab](https://archify.si/gallery.html)
自动 Mermaid Parser、通用自动布局、托管分享服务和 WYSIWYG 编辑器目前都不在产品范围内。
diff --git a/test/cloudflare-deployment-workflow.test.mjs b/test/cloudflare-deployment-workflow.test.mjs
new file mode 100644
index 00000000..dc7e0458
--- /dev/null
+++ b/test/cloudflare-deployment-workflow.test.mjs
@@ -0,0 +1,58 @@
+import { test } from 'node:test';
+import assert from 'node:assert/strict';
+import fs from 'node:fs';
+import { spawnSync } from 'node:child_process';
+import { parse } from 'yaml';
+
+const workflow = parse(fs.readFileSync(new URL('../.github/workflows/ci.yml', import.meta.url), 'utf8'));
+const cloudflare = workflow.jobs['deploy-cloudflare'];
+
+test('Cloudflare deployment is opt-in, stable-main-only, and waits for the existing publication gates', () => {
+ assert.match(cloudflare.if, /github\.event_name == 'push'/);
+ assert.match(cloudflare.if, /github\.ref == 'refs\/heads\/main'/);
+ assert.match(cloudflare.if, /vars\.CLOUDFLARE_PAGES_PROJECT != ''/);
+ assert.deepEqual(cloudflare.needs, workflow.jobs['deploy-pages'].needs);
+ assert.deepEqual(cloudflare.permissions, { contents: 'read' });
+ assert.equal(cloudflare.concurrency['cancel-in-progress'], false);
+});
+
+test('Cloudflare publishes only the checked artifact at the current main SHA', () => {
+ const steps = cloudflare.steps;
+ const download = steps.find(step => step.uses?.startsWith('actions/download-artifact@'));
+ const gate = steps.find(step => step.id === 'deployment-head');
+ const deployment = steps.find(step => step.id === 'deployment');
+ assert.equal(download.with.name, 'website-cloudflare-dist');
+ assert.equal(download.with.path, 'website/dist-cloudflare');
+ assert.ok(steps.indexOf(gate) > steps.indexOf(download));
+ assert.ok(steps.indexOf(deployment) > steps.indexOf(gate));
+ assert.match(gate.run, /current_main.*gh api/);
+ assert.match(gate.run, /"\$current_main" == "\$GITHUB_SHA"/);
+ assert.equal(deployment.if, "steps.deployment-head.outputs.current == 'true'");
+ assert.match(deployment.with.command, /^pages deploy website\/dist-cloudflare /);
+ assert.match(deployment.with.command, /--branch=main --commit-hash=\$\{\{ github.sha \}\}/);
+ assert.equal(deployment.with.apiToken, '${{ secrets.CLOUDFLARE_API_TOKEN }}');
+ assert.match(deployment.with.wranglerVersion, /^\d+\.\d+\.\d+$/);
+ assert.ok(!steps.some(step => /npm (?:run build|ci)/.test(step.run ?? '')), 'deployment must not rebuild');
+ const build = workflow.jobs.website.steps.find(step => step.env?.ARCHIFY_SITE_TARGET === 'cloudflare');
+ assert.match(build.run, /npm run build && node scripts\/check-cloudflare-output.mjs/);
+ assert.match(build.run, /node --test test\/deployment-target.test.mjs/);
+ const browser = workflow.jobs.website.steps.find(step => step.env?.ARCHIFY_SITE_ROOT?.endsWith('/website/dist-cloudflare'));
+ assert.equal(browser.env.ARCHIFY_SITE_BASE, '');
+ assert.equal(browser.env.ARCHIFY_SITE_INTEGRATION, '1');
+ assert.equal(browser.run, 'npm run test:browser');
+ const upload = workflow.jobs.website.steps.find(step => step.with?.name === download.with.name);
+ assert.equal(upload.with.path, download.with.path);
+ assert.equal(upload.with['if-no-files-found'], 'error');
+});
+
+test('Cloudflare destination rejects invalid values without evaluating them as shell code', () => {
+ const step = cloudflare.steps.find(step => step.name === 'Validate Cloudflare destination');
+ assert.ok(!step.run.includes('${{'));
+ const run = project => spawnSync('bash', ['-c', step.run], {
+ env: { ...process.env, CLOUDFLARE_PAGES_PROJECT: project, CLOUDFLARE_ACCOUNT_ID: 'a'.repeat(32) },
+ });
+ assert.equal(run('archify').status, 0);
+ for (const value of ['', '--help', 'archify --branch=dev', '$(exit 0)', 'a\nb']) {
+ assert.notEqual(run(value).status, 0, value);
+ }
+});
diff --git a/test/cloudflare-output.test.mjs b/test/cloudflare-output.test.mjs
new file mode 100644
index 00000000..24179dfc
--- /dev/null
+++ b/test/cloudflare-output.test.mjs
@@ -0,0 +1,50 @@
+import { test } from 'node:test';
+import assert from 'node:assert/strict';
+import fs from 'node:fs';
+import os from 'node:os';
+import path from 'node:path';
+import { checkCloudflareOutput } from '../website/scripts/check-cloudflare-output.mjs';
+
+function fixture(t) {
+ const root = fs.mkdtempSync(path.join(os.tmpdir(), 'archify-cloudflare-output-'));
+ t.after(() => fs.rmSync(root, { recursive: true, force: true }));
+ for (const name of ['index', 'gallery', 'guide', 'start', 'community', '404']) {
+ fs.writeFileSync(path.join(root, `${name}.html`), '<!doctype html><title>Archify</title>');
+ }
+ fs.writeFileSync(path.join(root, 'site.css'), 'body { color: black; }');
+ fs.appendFileSync(path.join(root, 'index.html'), '<link href="site.css" rel="stylesheet"><a href="/guide?lang=zh#install">Guide</a>');
+ const manifest = path.join(root, 'skill-updates/archify/stable.json');
+ fs.mkdirSync(path.dirname(manifest), { recursive: true });
+ fs.copyFileSync(new URL('../docs/skill-updates/archify/stable.json', import.meta.url), manifest);
+ return root;
+}
+
+test('Cloudflare output accepts static files and extensionless canonical routes', t => {
+ assert.equal(checkCloudflareOutput(fixture(t)), 6);
+});
+
+test('Cloudflare output rejects a missing 404 before implicit SPA fallback can ship', t => {
+ const root = fixture(t);
+ fs.rmSync(path.join(root, '404.html'));
+ assert.throws(() => checkCloudflareOutput(root), /ENOENT.*404\.html/);
+});
+
+test('Cloudflare output rejects a referenced asset missing from the deployment', t => {
+ const root = fixture(t);
+ fs.rmSync(path.join(root, 'site.css'));
+ assert.throws(() => checkCloudflareOutput(root), /index\.html: missing local target site\.css/);
+});
+
+test('Cloudflare output rejects a Worker accidentally bundled into the static site', t => {
+ const root = fixture(t);
+ fs.writeFileSync(path.join(root, '_worker.js'), 'export default {};');
+ assert.throws(() => checkCloudflareOutput(root), /Static deployment must not contain _worker\.js/);
+});
+
+test('Cloudflare output rejects an asset exceeding the Pages upload limit', t => {
+ const root = fixture(t);
+ const asset = path.join(root, 'oversize.bin');
+ fs.writeFileSync(asset, '');
+ fs.truncateSync(asset, 25 * 1024 * 1024 + 1);
+ assert.throws(() => checkCloudflareOutput(root), /asset exceeds 25 MiB/);
+});
diff --git a/test/readme-showcase.test.mjs b/test/readme-showcase.test.mjs
index e99bc94f..abee634a 100644
--- a/test/readme-showcase.test.mjs
+++ b/test/readme-showcase.test.mjs
@@ -205,7 +205,7 @@ test('all README languages show the brand mark and localized launch video', () =
const videoId = filename === 'README_ZH.md' ? '88cff7dd-bdf3-4b97-950c-37cc079898b1' : '78570807-ba1d-4737-953f-55504a378a87';
assert.ok(readme.includes(`\nhttps://github.com/user-attachments/assets/${videoId}\n`), `${filename}: missing standalone localized video attachment`);
assert.ok(!readme.includes('docs/assets/archify-live-proof.gif'), `${filename}: obsolete preview remains`);
- assert.match(readme, /https:\/\/tt-a1i\.github\.io\/archify\/gallery\.html/);
+ assert.match(readme, /https:\/\/archify\.si\/gallery\.html/);
}
assert.equal(
fs.readFileSync(path.join(repoRoot, 'README.md'), 'utf8'),
diff --git a/test/site-language-continuity.test.mjs b/test/site-language-continuity.test.mjs
index 8e8a08f8..5656b843 100644
--- a/test/site-language-continuity.test.mjs
+++ b/test/site-language-continuity.test.mjs
@@ -386,7 +386,7 @@ test('real Chrome preserves language through entry, navigation, selection, refre
timeout: 120000,
}, async () => {
const docsRoot = process.env.ARCHIFY_SITE_ROOT ? path.resolve(process.env.ARCHIFY_SITE_ROOT) : path.join(repoRoot, 'docs');
- const basePath = process.env.ARCHIFY_SITE_ROOT ? '/archify' : '';
+ const basePath = process.env.ARCHIFY_SITE_ROOT ? (process.env.ARCHIFY_SITE_BASE ?? '/archify') : '';
const server = startStaticServer(docsRoot, basePath);
await new Promise((resolve) => server.listen(0, '127.0.0.1', resolve));
const address = server.address();
diff --git a/website/.gitignore b/website/.gitignore
index a06acbf9..618867bf 100644
--- a/website/.gitignore
+++ b/website/.gitignore
@@ -1,4 +1,5 @@
node_modules/
dist/
+dist-cloudflare/
.astro/
.public/
diff --git a/website/README.md b/website/README.md
index 9d041abc..1207668b 100644
--- a/website/README.md
+++ b/website/README.md
@@ -45,4 +45,34 @@ npm run test:browser
CI builds/tests the website when website inputs change and on every main push. It uploads `website-dist`; the existing protected Pages deployment downloads that exact verified artifact. Build output, caches and staged assets are ignored by Git. Existing GitHub required checks and obsolete-deployment protection remain in place.
+## Cloudflare Pages migration
+
+The same source can build a second static site for `https://archify.si/`:
+
+```sh
+ARCHIFY_SITE_TARGET=cloudflare npm run build
+ARCHIFY_SITE_TARGET=cloudflare node --test test/deployment-target.test.mjs
+node scripts/check-cloudflare-output.mjs
+ARCHIFY_SITE_ROOT="$PWD/dist-cloudflare" ARCHIFY_SITE_BASE='' \
+ARCHIFY_SITE_INTEGRATION=1 ARCHIFY_CHROME="/path/to/chrome" npm run test:browser
+```
+
+This writes `dist-cloudflare/`; the default build still writes `dist/` for GitHub Pages. Cloudflare uses root asset paths, formal-domain sharing/canonical URLs, and a top-level `404.html` so unknown URLs do not silently return the homepage. Keep file-format pages: changing to directory-format pages would change the base used by relative proof and asset links. Pages redirects `.html` routes to extensionless routes; verify the actual Pages preview, especially `/gallery`, `/gallery.html`, `/gallery/`, standalone diagrams, query strings and fragments.
+
+The `website` CI job verifies both artifacts. The optional `deploy-cloudflare` job runs only on `main` after the same test/package/manifest gates as GitHub Pages, rejects an obsolete source revision, and uploads the verified `website-cloudflare-dist` artifact. Enable it with repository variables `CLOUDFLARE_PAGES_PROJECT` and `CLOUDFLARE_ACCOUNT_ID`, plus secret `CLOUDFLARE_API_TOKEN` restricted to **Account / Cloudflare Pages / Edit** on the selected account. Never commit the token or put it in build artifacts.
+
+When using a Git-connected Pages project, disable automatic production and preview deployments before enabling CI uploads, so Cloudflare does not publish an unchecked parallel build. A Direct Upload project can also receive these GitHub Actions uploads, but cannot later be converted to Git integration. Both approaches retain GitHub as the source and provide automatic deployment from the gated workflow. See [Git integration](https://developers.cloudflare.com/pages/get-started/git-integration/) and [CI uploads](https://developers.cloudflare.com/pages/how-to/use-direct-upload-with-continuous-integration/).
+
+Cut over in this order:
+
+1. Review the migration on `dev`, then promote only the reviewed migration to stable `main`; do not deploy the unrelated development feature batch as part of a hosting change. Record the stable source SHA and tested artifact.
+2. Deploy and check the Pages preview: all five pages, mobile navigation, language/theme state, proof iframes and links, images, installation/download destinations and real missing-route 404s. Static hosting uses the free plan; no Functions, server, or paid China Network is required.
+3. Add `archify.si` as a free Cloudflare zone. Inventory existing DNS records (including MX/TXT), registrar DNSSEC and DS records before changing nameservers; preserve records used by other services. Bind the root domain inside the Pages project, not only by adding DNS records.
+4. Change only `archify.si`'s nameservers at Dynadot to the two assigned by Cloudflare. Keep registration and renewal at Dynadot. Verify authoritative DNS, active zone/domain status and HTTPS certificate issuance before changing public links.
+5. Configure `www.archify.si` to redirect permanently to the root domain, preserving paths and query strings. Check both HTTP and HTTPS and avoid redirect loops. Keep the Pages preview available until formal-domain acceptance is complete.
+6. Test the formal domain through actual mainland networks without a proxy. Record operator, location, time and observed page/resource behavior; tests through a local proxy or an overseas runner do not establish mainland availability. The current site also uses Google Fonts and links to GitHub, so validate the full user journey.
+7. Only after acceptance, update README and repository website metadata. Social profile edits are a separate account action. Keep GitHub Pages and the old `skill-updates/archify/stable.json` endpoint available: existing installed Skills still request that URL. Do not change the Skill updater or install/update live Skills as part of this migration.
+
+For rollback, disable the Cloudflare deployment variable and roll back to the last verified Pages deployment; keep the old GitHub site available. Record DNS before any cutover so changes can be reversed deliberately. Removing a project is not a rollback: first detach custom domains and their DNS records to avoid dangling destinations.
+
The migration visual receipt is in `test/evidence/visual-parity.json`. Full-page comparisons use identical browser/viewports and wait for fonts. Animation is frozen and iframe pixels are hidden in both versions; iframe files are instead verified byte-for-byte, and unmasked pages are inspected separately.
diff --git a/website/astro.config.mjs b/website/astro.config.mjs
index 267352b8..1d6ce3fe 100644
--- a/website/astro.config.mjs
+++ b/website/astro.config.mjs
@@ -1,14 +1,27 @@
import { defineConfig } from 'astro/config';
import react from '@astrojs/react';
import tailwindcss from '@tailwindcss/vite';
+import { writeFileSync } from 'node:fs';
+import { siteTarget } from './scripts/site-target.mjs';
+
+const target = siteTarget();
+const cloudflareNotFound = {
+ name: 'archify-cloudflare-not-found',
+ hooks: {
+ 'astro:build:done': ({ dir }) => {
+ writeFileSync(new URL('404.html', dir), '<!doctype html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><title>Page not found — Archify</title><meta name="robots" content="noindex"></head><body><main><h1>Page not found</h1><p><a href="/">Return to Archify</a></p></main></body></html>\n');
+ },
+ },
+};
export default defineConfig({
- site: 'https://tt-a1i.github.io',
- base: '/archify',
+ site: target.site,
+ base: target.base,
+ outDir: target.outDir,
output: 'static',
publicDir: './.public',
compressHTML: false,
build: { format: 'file' },
- integrations: [react()],
+ integrations: [react(), ...(target.name === 'cloudflare' ? [cloudflareNotFound] : [])],
vite: { plugins: [tailwindcss()] },
});
diff --git a/website/scripts/check-cloudflare-output.mjs b/website/scripts/check-cloudflare-output.mjs
new file mode 100644
index 00000000..504b7ccc
--- /dev/null
+++ b/website/scripts/check-cloudflare-output.mjs
@@ -0,0 +1,58 @@
+import assert from 'node:assert/strict';
+import fs from 'node:fs';
+import path from 'node:path';
+import { fileURLToPath, pathToFileURL } from 'node:url';
+import { parse } from 'parse5';
+
+// Check the deployable files, not only the build configuration. Pages needs a
+// top-level 404 to disable its implicit single-page-app fallback.
+export function checkCloudflareOutput(root) {
+ const pages = ['index.html', 'gallery.html', 'guide.html', 'start.html', 'community.html', '404.html'];
+ let fileCount = 0;
+ const checkAssets = directory => {
+ for (const entry of fs.readdirSync(directory, { withFileTypes: true })) {
+ const file = path.join(directory, entry.name);
+ assert.ok(!entry.isSymbolicLink(), `Static output must not contain a symlink: ${file}`);
+ if (entry.isDirectory()) checkAssets(file);
+ else {
+ fileCount += 1;
+ assert.ok(fs.statSync(file).size <= 25 * 1024 * 1024, `Cloudflare Pages asset exceeds 25 MiB: ${file}`);
+ }
+ }
+ };
+ checkAssets(root);
+ assert.ok(fileCount <= 20000, `Cloudflare Pages Free file limit exceeded: ${fileCount}`);
+ for (const forbidden of ['_worker.js', '_worker.js/index.js', 'functions']) {
+ assert.ok(!fs.existsSync(path.join(root, forbidden)), `Static deployment must not contain ${forbidden}`);
+ }
+ for (const page of pages) {
+ const source = fs.readFileSync(path.join(root, page), 'utf8');
+ const visit = node => {
+ for (const { name, value } of node.attrs ?? []) {
+ if (!['src', 'href'].includes(name) || !value || value.startsWith('#')) continue;
+ const url = new URL(value, `https://archify.si/${page}`);
+ if (url.origin !== 'https://archify.si') continue;
+ const pathname = decodeURIComponent(url.pathname);
+ assert.ok(!/^\/archify(?:\/|$)/.test(pathname), `${page}: legacy base URL ${value}`);
+ const relative = pathname.replace(/^\//, '') || 'index.html';
+ const target = path.resolve(root, relative);
+ assert.ok(target.startsWith(`${path.resolve(root)}${path.sep}`), `${page}: URL escapes output ${value}`);
+ // Pages serves file-format HTML at extensionless canonical URLs.
+ const candidates = [target, `${target}.html`, path.join(target, 'index.html')];
+ assert.ok(candidates.some(candidate => fs.existsSync(candidate) && fs.statSync(candidate).isFile()), `${page}: missing local target ${value}`);
+ }
+ for (const child of node.childNodes ?? []) visit(child);
+ };
+ visit(parse(source));
+ }
+ const builtManifest = fs.readFileSync(path.join(root, 'skill-updates/archify/stable.json'));
+ const canonicalManifest = fs.readFileSync(new URL('../../docs/skill-updates/archify/stable.json', import.meta.url));
+ assert.ok(builtManifest.equals(canonicalManifest), 'The static site must retain the exact stable update manifest');
+ return pages.length;
+}
+
+if (process.argv[1] && import.meta.url === pathToFileURL(process.argv[1]).href) {
+ const root = fileURLToPath(new URL('../dist-cloudflare/', import.meta.url));
+ const count = checkCloudflareOutput(root);
+ console.log(`Verified ${count} Cloudflare pages, local assets, static-only output, and stable update manifest.`);
+}
diff --git a/website/scripts/site-target.mjs b/website/scripts/site-target.mjs
new file mode 100644
index 00000000..aca0474b
--- /dev/null
+++ b/website/scripts/site-target.mjs
@@ -0,0 +1,9 @@
+export function siteTarget(value = process.env.ARCHIFY_SITE_TARGET) {
+ if (value === undefined || value === '' || value === 'github') {
+ return { name: 'github', site: 'https://tt-a1i.github.io', base: '/archify', outDir: './dist' };
+ }
+ if (value === 'cloudflare') {
+ return { name: 'cloudflare', site: 'https://archify.si', base: '/', outDir: './dist-cloudflare' };
+ }
+ throw new Error(`Unknown ARCHIFY_SITE_TARGET: ${value}`);
+}
diff --git a/website/src/layouts/SiteLayout.astro b/website/src/layouts/SiteLayout.astro
index f53c6c27..764d9b46 100644
--- a/website/src/layouts/SiteLayout.astro
+++ b/website/src/layouts/SiteLayout.astro
@@ -3,11 +3,18 @@ import '../styles/utilities.css';
import siteCss from '../styles/site.css?raw';
interface Props { head: string; css: string }
const { head, css } = Astro.props;
+const cloudflare = Astro.site?.origin === 'https://archify.si';
+const pagePath = Astro.url.pathname.replace(/\/index\.html$/, '/').replace(/\.html$/, '').replace(/\/$/, '') || '/';
+const canonical = cloudflare ? new URL(pagePath, Astro.site).href : undefined;
+const pageHead = cloudflare
+ ? head.replaceAll('https://tt-a1i.github.io/archify/', 'https://archify.si/').replace(/(<meta property="og:url" content=")[^"]*(")/, `$1${canonical}$2`)
+ : head;
---
<!DOCTYPE html>
<html lang="en">
<head>
- <Fragment set:html={head} />
+ <Fragment set:html={pageHead} />
+ {canonical && <link rel="canonical" href={canonical} />}
<script is:inline>(function () { var t = 'light'; try { t = localStorage.getItem('archify-site-theme') || 'light'; } catch (_) {} document.documentElement.setAttribute('data-theme', t === 'dark' ? 'dark' : 'light'); })();</script>
<style is:inline set:html={siteCss + css}></style>
</head>
diff --git a/website/test/community-browser.test.mjs b/website/test/community-browser.test.mjs
index a18b10c5..fc297a54 100644
--- a/website/test/community-browser.test.mjs
+++ b/website/test/community-browser.test.mjs
@@ -8,6 +8,8 @@ import { createCommunityFixture, payload, websiteRoot } from './helpers/communit
const integrationEnabled = process.env.ARCHIFY_SITE_INTEGRATION === '1';
const chrome = integrationEnabled ? findChrome() : null;
+const siteRoot = process.env.ARCHIFY_SITE_ROOT ? path.resolve(process.env.ARCHIFY_SITE_ROOT) : path.join(websiteRoot, 'dist');
+const siteBase = process.env.ARCHIFY_SITE_BASE ?? '/archify';
test('real Chrome: community metadata remains text through language, filter and navigation changes', {
skip: integrationEnabled ? false : 'Set ARCHIFY_SITE_INTEGRATION=1 and ARCHIFY_CHROME to run the community browser regression.',
@@ -22,8 +24,10 @@ test('real Chrome: community metadata remains text through language, filter and
assert.equal(built.status, 0, built.stdout + built.stderr);
server = http.createServer((request, response) => {
const url = new URL(request.url, 'http://127.0.0.1');
- const root = url.pathname.startsWith('/fixture/') ? fixture.dist : path.join(websiteRoot, 'dist');
- const relative = url.pathname.replace(/^\/(?:fixture|archify)\//, '');
+ const isFixture = url.pathname.startsWith('/fixture/');
+ const root = isFixture ? fixture.dist : siteRoot;
+ if (!isFixture && siteBase && !url.pathname.startsWith(`${siteBase}/`)) return response.writeHead(404).end();
+ const relative = url.pathname.slice(isFixture ? '/fixture/'.length : siteBase.length).replace(/^\/+/, '');
const file = path.resolve(root, relative);
if (!file.startsWith(`${root}${path.sep}`)) return response.writeHead(404).end();
try {
@@ -81,12 +85,12 @@ test('real Chrome: community metadata remains text through language, filter and
await navigate(`${base}/fixture/community.html?type=skill&lang=en`);
assert.equal(await evaluate("document.querySelector('[data-filter=skill]').getAttribute('aria-pressed')"), 'true');
assert.equal(await evaluate("document.querySelector('.package-card').hidden"), false);
- await navigate(`${base}/archify/index.html?lang=zh`);
+ await navigate(`${base}${siteBase}/index.html?lang=zh`);
const loaded = browser.cdp.waitFor('Page.loadEventFired', session);
await evaluate("document.querySelector('footer a[href=\"community.html\"]').click()");
await loaded;
assert.equal(await evaluate('document.documentElement.lang'), 'zh-CN');
- assert.equal(await evaluate('location.pathname'), '/archify/community.html');
+ assert.equal(await evaluate('location.pathname'), `${siteBase}/community.html`);
}
} finally {
if (browser) await browser.close();
diff --git a/website/test/deployment-target.test.mjs b/website/test/deployment-target.test.mjs
new file mode 100644
index 00000000..7c2fbda0
--- /dev/null
+++ b/website/test/deployment-target.test.mjs
@@ -0,0 +1,40 @@
+import { test } from 'node:test';
+import assert from 'node:assert/strict';
+import fs from 'node:fs';
+import { parse } from 'parse5';
+
+const cloudflare = process.env.ARCHIFY_SITE_TARGET === 'cloudflare';
+const output = new URL(cloudflare ? '../dist-cloudflare/' : '../dist/', import.meta.url);
+const nodes = node => [node, ...(node.childNodes || []).flatMap(nodes)];
+const attr = (node, name) => node?.attrs?.find(item => item.name === name)?.value;
+const pages = ['index', 'start', 'guide', 'gallery', 'community'];
+
+test('built deployment uses host-compatible generated assets and canonical metadata', () => {
+ for (const page of pages) {
+ const dom = parse(fs.readFileSync(new URL(`${page}.html`, output), 'utf8'));
+ const all = nodes(dom);
+ const canonical = all.find(node => node.tagName === 'link' && attr(node, 'rel') === 'canonical');
+ assert.equal(attr(canonical, 'href'), cloudflare ? `https://archify.si/${page === 'index' ? '' : page}` : undefined, page);
+ const generatedAssets = all.flatMap(node => ['src', 'href'].map(name => attr(node, name))).filter(value => value?.includes('/_astro/'));
+ for (const asset of generatedAssets) {
+ assert.ok(asset.startsWith(cloudflare ? '/_astro/' : '/archify/_astro/'), asset);
+ const relative = asset.replace(cloudflare ? /^\// : /^\/archify\//, '').split(/[?#]/)[0];
+ assert.ok(fs.existsSync(new URL(relative, output)), asset);
+ }
+ for (const property of ['og:url', 'og:image']) {
+ const meta = all.find(node => attr(node, 'property') === property);
+ if (meta) assert.ok(attr(meta, 'content').startsWith(cloudflare ? 'https://archify.si/' : 'https://tt-a1i.github.io/archify/'), `${page}: ${property}`);
+ }
+ }
+});
+
+test('deployment preserves standalone proof and updater bytes and only Cloudflare gets a 404', () => {
+ for (const file of ['gallery/artifacts/agent-tool-call.workflow.html', 'skill-updates/archify/stable.json', 'assets/site-language.js']) {
+ assert.deepEqual(fs.readFileSync(new URL(file, output)), fs.readFileSync(new URL(`../../docs/${file}`, import.meta.url)), file);
+ }
+ assert.equal(fs.existsSync(new URL('404.html', output)), cloudflare);
+ if (cloudflare) {
+ const dom = parse(fs.readFileSync(new URL('404.html', output), 'utf8'));
+ assert.ok(nodes(dom).some(node => node.tagName === 'a' && attr(node, 'href') === '/'));
+ }
+});
diff --git a/website/test/helpers/community-fixture.mjs b/website/test/helpers/community-fixture.mjs
index 9a3175dc..f0095d23 100644
--- a/website/test/helpers/community-fixture.mjs
+++ b/website/test/helpers/community-fixture.mjs
@@ -17,7 +17,7 @@ export function createCommunityFixture() {
};
// Compile the actual page, loader, validator and language script, without
// modifying the checked-out registry or running any community package code.
- for (const relative of ['website/src', 'website/astro.config.mjs', 'website/package.json',
+ for (const relative of ['website/src', 'website/astro.config.mjs', 'website/scripts/site-target.mjs', 'website/package.json',
'archify/package.json', 'archify/recipes', 'scripts/site-copy.mjs',
'scripts/check-community-packages.mjs', 'docs/gallery/manifest.json']) copy(relative);
const pages = path.join(root, 'website/src/pages');
@@ -47,6 +47,7 @@ export function createCommunityFixture() {
fs.rmSync(path.join(root, 'website/dist'), { recursive: true, force: true });
return spawnSync(process.execPath, [path.join(websiteRoot, 'node_modules/astro/bin/astro.mjs'), 'build'], {
cwd: path.join(root, 'website'), encoding: 'utf8', timeout: 60000,
+ env: { ...process.env, ARCHIFY_SITE_TARGET: 'github' },
});
},
close() { fs.rmSync(root, { recursive: true, force: true }); },