Skip to content

Commit da643fb

Browse files
KSemenenkoclaude
andcommitted
Present KeyLoad as an AI-native database across README and landing
README: lead with the AI-native thesis ("Agents shouldn't need a dozen databases"), a before/after stack diagram, why we think one database is the future, a capability matrix (atomic writes, reads, SQL, MCP tools per model), composition and agent tool-call diagrams, why .NET, Orleans and ZoneTree, an SEO-oriented FAQ and calls to action. All credits are kept; the benchmark comparison engines are now credited too. Landing: add the same theses in a "Why an AI-native database" section and a "Why .NET, Orleans and ZoneTree" section with Liquid Glass styles, plain product language for composition and engine copy, a valid MCP request sample, a Get started CTA, and AI-native title, description, Open Graph and JSON-LD within the AC-SEO-002 contract. Traceability: REQ-COMP-007 / AC-COMP-009 / ADR-067 stage 8 (TASK-COMP-008) with SiteProductThesisTests (README headings, landing main copy, forbidden claims, all-missing and one-missing cases). Shared SiteProductCopy helper replaces duplicated parsing, and README and landing now assert one set of composition stage contracts. Verification: three review rounds (accuracy, engagement/SEO, final gate) with all findings applied; SiteTests Release build and dotnet format pass; thesis and composition assertions verified statically with the tests' own tokens; Mermaid diagrams render; landing checked at 320/375/761/1440 px with no overflow. The site suite needs the GitHub exact-revision gate and was not run locally. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 873cd1a commit da643fb

11 files changed

Lines changed: 335 additions & 115 deletions

File tree

‎README.md‎

Lines changed: 156 additions & 31 deletions
Large diffs are not rendered by default.

‎docs/ADR/ADR-067-composable-agent-database.md‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# ADR-067: One composable database for AI agents
22

33
Status: Accepted. Date: 2026-10-03. Owner: root integration agent.
4-
REQ-COMP-001–006 / AC-COMP-001–008, [DatabaseComposition](../Features/DatabaseComposition.md).
4+
REQ-COMP-001–007 / AC-COMP-001–009, [DatabaseComposition](../Features/DatabaseComposition.md).
55

66
## Decision
77

@@ -69,6 +69,9 @@ flowchart LR
6969
7. TASK-COMP-005 records development versus exact-source GitHub proof separately;
7070
build/analyzers/format/governance, normal/scalar, process recovery and RF3 gates
7171
remain mandatory. Full site publication waits on complete Benchmarks producer.
72+
8. TASK-COMP-008 (root) owns the README and landing AI-native thesis copy and the
73+
SiteProductCopy/SiteProductThesis* content tests for REQ-COMP-007/AC-COMP-009.
74+
It changes no runtime contract, storage, serialization or topology.
7275

7376
Determinism: replicated apply cannot use a local elapsed deadline or caller
7477
cancellation to choose effects. A frozen monotonic TimeProvider feeds the existing

‎docs/Features/DatabaseComposition.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ flowchart LR
3434
| REQ-COMP-004: persisted source/target/row/field authorization and stable retries | AC-COMP-005/007 | TASK-COMP-002/004; real policy, replay and scope errors |
3535
| REQ-COMP-005: bounded deterministic same-partition atomic execution | AC-COMP-004/006 | TASK-COMP-002/004; cumulative limits, late rollback, real reopen, real process-kill atomic recovery and identical replica commands |
3636
| REQ-COMP-006: honest syntax, qualification, performance and publication | AC-COMP-001/008 | TASK-COMP-003/005; content tests, integrated checks and exact-source Actions receipts |
37+
| REQ-COMP-007: README and landing present one AI-native product thesis | AC-COMP-009 | TASK-COMP-008 (ADR-067 stage 8); SiteProductThesisTests and lead prose review |
3738

3839
Canonical slice map: Abstractions/Core/UnitTests/IntegrationTests/RecoveryTests/CrashHost
3940
`Features/DatabaseComposition/`; shared Mutation/ApplyMutations/authorization joins
@@ -81,6 +82,7 @@ one request grain; physical hosts retain ZoneTree/native WAL and RF3 ownership.
8182
| AC-COMP-006 | One cumulative read-byte budget and expanded MaxBatchMutations bound cover entire batch; overflow rejects all, never truncates silently; reads materialize before writes; replicated derivation uses deterministic bounds without local wall deadlines/cancellation | byte/count/multiple-composition/exact-cap/replica-determinism cases; code review of callbacks and apply clock |
8283
| AC-COMP-007 | Native DTOs have stable aliases/IDs; public polymorphic JSON preserves old shapes; SQL canonical CALL needs no second gateway/operation kind; fresh request routing remains | serializer roundtrip + frozen pre-composition native writer fixtures + SQL compiler + actual RF3 .NET/official MCP forward/reverse/retry/error tests |
8384
| AC-COMP-008 | Build/formatter/governance and relevant TUnit tests pass; exact-source Actions full normal/scalar/recovery/RF3 remain separately recorded, website publication requires existing complete Benchmarks pipeline | retained source/SHA/commands/reports in implementation receipt; no numeric coverage claim without collector |
85+
| AC-COMP-009 | README and landing both state the same theses: KeyLoad is an AI-native database; agents shouldn't need a dozen databases; why we think one database is the future; why .NET, Orleans and ZoneTree. Neither surface claims production readiness. README theses are its section headings and lead sentence, not navigation links; landing theses are visible `<main>` copy, not metadata. Fail if either surface drops a thesis or matches the forbidden-claims pattern | SiteProductThesisTests (README headings, landing main copy, forbidden claims on both, all-missing and one-missing cases); prose and SEO review is the explicit manual exception |
8486

8587
Frozen DTOs: QueueGraphLink(From EntityRef, To EntityRef, Label string,
8688
AttributesJson string = "{}"); QueueToGraph(Graph string, Queue string,

‎site/Features/BenchmarkComparisons/index.html‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ <h1 id="page-title">The database <span class="h1-break">for <span class="kl-mark
121121
</figure>
122122
<ul class="hero-facts" aria-label="KeyLoad at a glance">
123123
<li><strong>Connected models</strong><span>Documents, rows, graphs and queued work share references and persisted permissions.</span></li>
124-
<li><strong>MCP built in</strong><span>Agents query, read and write through the official MCP server, under the same permissions.</span></li>
124+
<li><strong>MCP built in</strong><span>Agents query, read and write through the built-in MCP server, under the same permissions.</span></li>
125125
<li><strong>Policy in the database</strong><span>Credentials and authorization live server-side; callers cannot claim trusted roles.</span></li>
126126
<li><strong>.NET 10 · Orleans · RF3</strong><span>Three replicas of your data, each on its own node.</span></li>
127127
</ul>
@@ -150,7 +150,7 @@ <h3>The stitched stack</h3>
150150
<article class="thesis-card thesis-card--one">
151151
<h3>One AI-native database</h3>
152152
<ul class="thesis-points">
153-
<li><b>One reference</b> Any record can reference any other through canonical entity references.</li>
153+
<li><b>One reference</b> Any record can point to any other through canonical entity references.</li>
154154
<li><b>One permission check</b> Keys and policies live in the database, so an agent gets exactly what you grant.</li>
155155
<li><b>One atomic write</b> A document, its event, a graph edge and the next task in the same partition commit together.</li>
156156
<li><b>One way in</b> SQL, the built-in MCP server and the .NET SDK reach the same operations.</li>
@@ -169,7 +169,7 @@ <h3>One AI-native database</h3>
169169
<ol class="anatomy-steps">
170170
<li><span class="step-no" aria-hidden="true">01</span><div><h3>Queue to knowledge graph</h3><p>Read ready messages, resolve their linked entities and write knowledge-graph relationships inside the database.</p></div></li>
171171
<li><span class="step-no" aria-hidden="true">02</span><div><h3>Graph to queued actions</h3><p>Follow visible relationships to enqueue actions carrying canonical entity references.</p></div></li>
172-
<li><span class="step-no" aria-hidden="true">03</span><div><h3>One authorized atomic command</h3><p>Source and target resources share the same atomic partition and transaction domain. A failed effect rolls back the whole command. Projection does not lease or ACK messages. Blobs remain part of the same database; staged upload and publication use their existing operations outside this initial graph/queue batch.</p></div></li>
172+
<li><span class="step-no" aria-hidden="true">03</span><div><h3>One authorized atomic command</h3><p>Every source and target must live in the same atomic partition and transaction domain, so the whole command succeeds or rolls back together. Reading a queue into the graph does not lease or ACK its messages. Blobs remain part of the same database, but use their separate upload and publication operations.</p></div></li>
173173
</ol>
174174
<div class="terminal kl-graphite">
175175
<article class="code-card"><header><span class="code-tag">SQL</span>One bound command envelope</header><pre><code><span class="tok-key">CALL</span> keyload_documents_commit(@arguments);</code></pre></article>
@@ -182,7 +182,7 @@ <h3>One AI-native database</h3>
182182
(<span class="tok-key">await</span> client.CommitAsync(command)).ThrowIfFail();</code></pre></article>
183183
</div>
184184
</div>
185-
<p>The source adds this initial bounded procedural composition stage through SQL CALL, the .NET SDK and official MCP, with exact-source qualification pending. Full declarative SQL, the native SQL-client protocol and cross-partition composition remain required and pending.</p>
185+
<p>The current composition API runs through SQL CALL, the .NET SDK and the official MCP server. KeyLoad is a development preview: full declarative SQL, the native SQL-client protocol and cross-partition composition are still in development, and production guarantees remain under qualification.</p>
186186
<p><a class="text-link" href="https://github.com/managedcode/KeyLoad/blob/main/docs/Features/DatabaseComposition.md">Database composition contract <span aria-hidden="true">↗</span></a> · <a class="text-link" href="https://github.com/managedcode/KeyLoad/blob/main/docs/ADR/ADR-067-composable-agent-database.md">Composition architecture <span aria-hidden="true">↗</span></a></p>
187187
</section>
188188

‎site/Features/BenchmarkComparisons/styles.css‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,24 @@ h1 .kl-mark { background-size: 100% .11em; background-position: 0 94%; }
121121
.shape p { margin: 0; color: var(--kl-muted); font-size: .9rem; line-height: 1.5; }
122122
.shape-link { margin-top: .5rem; color: var(--kl-ink-2); font-size: .8rem; font-weight: 600; }
123123

124+
/* Thesis: the stitched stack against one AI-native database */
125+
.thesis-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .9rem; }
126+
.thesis-card { min-width: 0; padding: clamp(1.3rem, 3vw, 2rem); border: 1px solid var(--kl-stroke); border-radius: var(--kl-radius-xl); background: var(--kl-sheen), var(--kl-surface); box-shadow: var(--kl-shadow); backdrop-filter: var(--kl-glass); }
127+
.thesis-card h3 { margin: 0 0 1.2rem; font-size: 1.35rem; }
128+
.thesis-card > p { margin: 1.2rem 0 0; color: var(--kl-muted); font-size: .92rem; }
129+
.thesis-stack { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; margin: 0; padding: 0; list-style: none; }
130+
.thesis-stack li { display: grid; align-content: start; gap: .1rem; min-width: 0; padding: .65rem .85rem; border: 1px dashed var(--kl-line-strong); border-radius: var(--kl-radius); color: var(--kl-muted); font: .72rem/1.4 var(--kl-font-mono); }
131+
.thesis-stack b { color: var(--kl-ink-2); font: 650 .95rem/1.3 var(--kl-font-display); letter-spacing: -.01em; }
132+
.thesis-card--one { border-color: var(--kl-graphite-line); background: linear-gradient(180deg, var(--kl-graphite-2) 0%, var(--kl-graphite) 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 24px 60px rgba(17, 18, 20, .22); color: var(--kl-on-graphite); }
133+
.thesis-card--one h3 { color: #fff; }
134+
.thesis-points { display: grid; gap: 1.15rem; margin: 0; padding: 0; list-style: none; }
135+
.thesis-points li { display: grid; gap: .2rem; padding-left: 1rem; border-left: 2px solid transparent; border-image: linear-gradient(180deg, var(--kl-peach), var(--kl-lilac), var(--kl-periwinkle)) 1; color: var(--kl-on-graphite-muted); font-size: .92rem; }
136+
.thesis-points b { color: #fff; font: 700 1.05rem/1.3 var(--kl-font-display); letter-spacing: -.015em; }
137+
.thesis-future { max-width: 54rem; margin: 1.8rem 0 0; color: var(--kl-ink-2); font-size: 1.08rem; }
138+
.why-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .9rem; }
139+
.why-grid .shape-no { margin-top: 0; color: var(--kl-ink-2); }
140+
.why-grid .shape-link { margin-top: auto; padding-top: .5rem; }
141+
124142
/* Engine cross-section on graphite */
125143
.engine-inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(2rem, 5vw, 4.5rem); padding: clamp(1.6rem, 5vw, 4rem); border-radius: var(--kl-radius-xl); }
126144
.engine .eyebrow, .engine .eyebrow::before, .reproduce .eyebrow::before { color: var(--kl-on-graphite-muted); }
@@ -212,6 +230,7 @@ tr:last-child td { border-bottom: 0; }
212230
.hero-facts li:nth-child(n + 3) { margin-top: 1rem; border-top: 1px solid var(--kl-line); }
213231
.anatomy-grid, .engine-inner, .reproduce-inner { grid-template-columns: minmax(0, 1fr); }
214232
.bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
233+
.thesis-grid, .why-grid { grid-template-columns: minmax(0, 1fr); }
215234
}
216235

217236
@media (max-width: 760px) {
Lines changed: 16 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
1-
using System.Net;
2-
using System.Text.RegularExpressions;
3-
41
namespace KeyLoad.SiteTests.Features.BenchmarkComparisons;
52

6-
internal sealed partial class SiteDatabaseCompositionTests
3+
internal sealed class SiteDatabaseCompositionTests
74
{
85
[Test]
96
public async Task AC_COMP_001_PublicIntroductionsDescribeOneLinkedDatabaseWithFamiliarSql()
107
{
11-
var readme = await ReadSourceAsync(SiteDatabaseCompositionTokens.ReadmePath);
12-
var html = await ReadSourceAsync(SiteDatabaseCompositionTokens.HtmlPath);
13-
var hero = ReadSection(html, SiteDatabaseCompositionTokens.HeroStart,
8+
var readme = await SiteProductCopy.ReadSourceAsync(SiteDatabaseCompositionTokens.ReadmePath);
9+
var html = await SiteProductCopy.ReadSourceAsync(SiteDatabaseCompositionTokens.HtmlPath);
10+
var hero = SiteProductCopy.ReadSection(html, SiteDatabaseCompositionTokens.HeroStart,
1411
SiteDatabaseCompositionTokens.ParagraphEnd);
15-
var readmeIntroduction = ReadSection(readme, SiteDatabaseCompositionTokens.ReadmeIntroductionStart,
12+
var readmeIntroduction = SiteProductCopy.ReadSection(readme, SiteDatabaseCompositionTokens.ReadmeIntroductionStart,
1613
SiteDatabaseCompositionTokens.ReadmeIntroductionEnd);
1714
foreach (var introduction in new[] { readmeIntroduction, hero })
1815
{
@@ -37,17 +34,17 @@ public async Task AC_COMP_001_PublicCompositionExplainsQueueGraphAndReverseFlows
3734
public async Task AC_COMP_001_008_PublicCompositionRetainsCurrentStageAndAtomicBoundaries()
3835
{
3936
var sections = await ReadCompositionSectionsAsync();
40-
await AssertIncludesAsync(sections[SiteDatabaseCompositionTokens.ReadmeSectionIndex],
41-
SiteDatabaseCompositionTokens.ReadmeStageContracts);
42-
await AssertIncludesAsync(sections[SiteDatabaseCompositionTokens.HtmlSectionIndex],
43-
SiteDatabaseCompositionTokens.StageContracts);
37+
foreach (var section in sections)
38+
{
39+
await AssertIncludesAsync(section, SiteDatabaseCompositionTokens.StageContracts);
40+
}
4441
}
4542

4643
[Test]
4744
public async Task AC_COMP_001_PublicCompositionLinksItsFeatureAndArchitectureContract()
4845
{
49-
var readme = await ReadSourceAsync(SiteDatabaseCompositionTokens.ReadmePath);
50-
var html = await ReadSourceAsync(SiteDatabaseCompositionTokens.HtmlPath);
46+
var readme = await SiteProductCopy.ReadSourceAsync(SiteDatabaseCompositionTokens.ReadmePath);
47+
var html = await SiteProductCopy.ReadSourceAsync(SiteDatabaseCompositionTokens.HtmlPath);
5148
await AssertIncludesAsync(readme,
5249
[SiteDatabaseCompositionTokens.FeaturePath, SiteDatabaseCompositionTokens.AdrPath]);
5350
await Assert.That(html).Contains(SiteDatabaseCompositionTokens.GitHubRoot + SiteDatabaseCompositionTokens.FeaturePath);
@@ -56,53 +53,19 @@ await AssertIncludesAsync(readme,
5653

5754
private static async Task<string[]> ReadCompositionSectionsAsync()
5855
{
59-
var readme = await ReadSourceAsync(SiteDatabaseCompositionTokens.ReadmePath);
60-
var html = await ReadSourceAsync(SiteDatabaseCompositionTokens.HtmlPath);
56+
var readme = await SiteProductCopy.ReadSourceAsync(SiteDatabaseCompositionTokens.ReadmePath);
57+
var html = await SiteProductCopy.ReadSourceAsync(SiteDatabaseCompositionTokens.HtmlPath);
6158
return
6259
[
63-
ReadSection(readme, SiteDatabaseCompositionTokens.ReadmeCompositionStart,
60+
SiteProductCopy.ReadSection(readme, SiteDatabaseCompositionTokens.ReadmeCompositionStart,
6461
SiteDatabaseCompositionTokens.ReadmeCompositionEnd),
65-
ReadSection(html, SiteDatabaseCompositionTokens.HtmlCompositionStart,
62+
SiteProductCopy.ReadSection(html, SiteDatabaseCompositionTokens.HtmlCompositionStart,
6663
SiteDatabaseCompositionTokens.HtmlSectionEnd),
6764
];
6865
}
6966

70-
private static Task<string> ReadSourceAsync(string relativePath)
71-
{
72-
var repository = Environment.GetEnvironmentVariable(SiteTokens.RepositoryEnvironment);
73-
if (string.IsNullOrWhiteSpace(repository) || !Path.IsPathFullyQualified(repository))
74-
{
75-
throw new InvalidOperationException(SiteDatabaseCompositionTokens.MissingRepository);
76-
}
77-
78-
return File.ReadAllTextAsync(Path.Combine(repository, relativePath),
79-
TestContext.Current!.Execution.CancellationToken);
80-
}
81-
82-
private static string ReadSection(string source, string startMarker, string endMarker)
83-
{
84-
var start = source.IndexOf(startMarker, StringComparison.Ordinal);
85-
var end = start < 0 ? -1 : source.IndexOf(endMarker, start + startMarker.Length, StringComparison.Ordinal);
86-
if (start < 0 || end < 0)
87-
{
88-
throw new InvalidDataException(SiteDatabaseCompositionTokens.MissingSection);
89-
}
90-
91-
return source[start..end];
92-
}
93-
9467
private static async Task AssertIncludesAsync(string source, IEnumerable<string> contracts)
9568
{
96-
var plainText = WebUtility.HtmlDecode(HtmlTags().Replace(source, SiteDatabaseCompositionTokens.WordSeparator));
97-
var text = string.Join(SiteDatabaseCompositionTokens.WordSeparator,
98-
plainText.Split((char[]?)null, StringSplitOptions.RemoveEmptyEntries));
99-
foreach (var contract in contracts)
100-
{
101-
await Assert.That(text.Contains(contract, StringComparison.OrdinalIgnoreCase)).IsTrue();
102-
}
69+
await Assert.That(SiteProductCopy.Missing(source, contracts)).IsEmpty();
10370
}
104-
105-
[GeneratedRegex(SiteDatabaseCompositionTokens.HtmlTagPattern, RegexOptions.CultureInvariant,
106-
SiteDatabaseCompositionTokens.PatternTimeoutMilliseconds)]
107-
private static partial Regex HtmlTags();
10871
}

0 commit comments

Comments
 (0)