Standard Garden Architecture v1

The Blueprint for the Universal Publishing Protocol.

This document outlines the finalized architecture for Standard Garden. It defines our pivot from a complex AI content generator to a robust, utility-first publishing tool.

1. The Core Philosophy

“Turn Chaos into Order.”

Standard Garden is a utility, not a platform. It accepts messy input (text, images, HTML) and outputs standardized, beautiful, permanent documents.


2. The Universal Funnel (Ingestion)

We handle input entirely in the browser (Client-Side) before it hits the API.

A. The “Drop All, Paste All” Interface

We aggressively sanitize input to produce pure Markdown.

B. Title Inference Protocol (The Dirty Input Handler)

We never block a save for lack of a title. We infer it in this order:

  1. Frontmatter: title: ...
  2. H1 Tag: # My Title
  3. Filename/Subject: my_doc.txt -> “My Doc”
  4. First Line: First 50 chars of text.
  5. AI Fallback: Cloudflare AI summarizes text into 3 words.
  6. Timestamp: Last resort.

3. The Grand Unified Linking Theory

We separate the system into Roots (Explicit) and Mycelium (Implicit).

The user’s explicit intent. Deterministic.

B. The Lean Weaver (Implicit Discovery)

The system’s contextual suggestions. Probabilistic.


4. The Citation Economy

“The Currency of the Garden is Thought, not Clicks.”


5. Data Architecture (D1)

We avoid complex relationship tables in favor of calculated properties.

notes Table

edges Table (The Graph)

Stores ONLY explicit Wiki Links found during ingestion.


6. Implementation Priorities

  1. Database Migration: Add edges table and content_score column.
  2. Ingestion Worker: Build the “Title Inference” and “Drop Handler”.
  3. Markdown Parser: Implement markdown-it folio for Silent Resolution of [[...]].
  4. Vector Pipeline: Connect workers-ai to generate embeddings on save.

Are you absolutely sure?

This action cannot be undone.