Skip to main content

adk_website/
lib.rs

1//! # adk-website
2//!
3//! A prebuilt AWP 2.0 website (spec 3.5 Part C, §7.16–§7.24): a site that onboards its
4//! owner, builds or migrates itself, passes its own launch gate, and then works towards the
5//! owner's goals with a team of eight agents, inside the authority, budget and guardrails of
6//! its charter.
7//!
8//! The product holds no framework code (D-1): the harness supplies the agents, tools,
9//! partitions and the autonomy ladder; the kernel the charter store, KPI tracker, signals,
10//! pairing and processes; `adk-site` the pipeline, gate, releases and probes; `adk-payments`
11//! the wallet. This crate decides what a website *is* for each kind of site.
12//!
13//! | Module | Contents | Spec 3.5 |
14//! |---|---|---|
15//! | [`kinds`] | One charter template per site kind, the rules each adds, kind detection | §7.16.1, D-15 |
16//! | [`team`] | The eight agents; the back office as a `TeamSpec` led by the Steward; building them over the harness kits | §7.19, §7.10 |
17//! | [`jobs`] | The §7.20 jobs, their ladder bindings, first-week authority, and the kernel processes that run them | §7.20, §7.11 |
18//! | [`onboarding`] | The nine-stage plan, three starting points, the setup-code gate, discovery, building release 1, the live preview, the cost estimate | §7.17, §7.18, A-I20 |
19//! | [`themes`] | Three themes with light and dark tokens for the built-in renderer | §7.16, §7.23 |
20//! | [`packs`] | Capability declarations: contact, quote, booking, order, search, components | §7.16, §7.4 |
21//! | [`playbooks`] | A skill file for every job | §7.16, §7.15 |
22//! | [`incident`] | Drift, incident status, rollback by standing rule or proposal, the person's exit | §7.20, A-I11 |
23//! | [`inbox`] | The Inbox: the site's email and the chat messages of unpaired accounts, answered in their own thread | §7.19, §7.10, X12, A-I24 |
24//! | [`leads`] | Lead scores and the handoff threshold, consent for nurture, the durable contact book, nurture sends inside quiet hours | §7.20, §7.21, S8, A-I8 |
25//! | [`alarms`] | P1, P2 and P3 routing to the owner's channels | §7.21 |
26//! | [`channel`] | The owner's chat channel: photos into the Steward's draft, alt text confirmed from the thread | §7.8.2, S18, A-I24 |
27//! | [`repository`] | Files and git as an entry point: a signed push from an authorised committer proposes a release | §7.8.2, A-I24 |
28//! | [`publish_delay`] | The delay a page the site drafts on its own waits before it can go live | §7.20, S10 |
29//! | [`quotes`] | The reviews discovery found, the owner's approvals to quote them, and the launch gate's check over them | §7.18, S2 |
30//! | [`review`] | The weekly review | §7.21 |
31//! | [`learning`] | Outcomes into playbook revision proposals, decided by the owner; versioned playbooks | §7.15, A-I13 |
32//! | [`upkeep`] | Upgrade proposals for advisories against the edge's lockfile, certificate renewal proposals | §7.20, S10 |
33//! | [`wallet`] | The wallet as a KPI source and the site's commerce outcomes | §7.14 |
34//! | [`experiments`] | Charter KPIs and guardrails as experiments, variants as static files, daily looks, pauses on a breach, the review's evidence | §7.12, A-I15 |
35//! | [`measurement`] | KPI sources that are not drivers: the beacon, host logs, the commerce, action and spend ledgers, agent search at the edge, AEO | §7.12, §7.11 |
36//! | [`workflows`] | The probe and the weekly review as kernel runs | §7.20 |
37//! | [`contract`] | The signed contract, key set and charter terms released with the site | §7.2, §7.7, D-11 |
38//! | [`deploy`] | The four deployment shapes, agency mode and serving the kernel and the edge | §7.22, A-I22 |
39//! | [`edge`] | The site on the agent edge: the packs' handlers, the adapters to the back office, the read-only step | §7.9, §7.16, A-I11 |
40//! | [`observability`] | Spans, metrics and the site view | §7.24 |
41//! | [`ui`] | Onboarding and owner views on the web home: setup code, onboarding, charter cards, the site view, the weekly review, the web editor | §7.16, §7.18, §7.21, §7.24, §8.2 |
42//!
43//! # Example
44//!
45//! ```rust
46//! use adk_harness::website::SiteRef;
47//! use adk_website::kinds::{CharterInputs, template};
48//! use adk_website::team::{AgentRole, SiteTeam};
49//! use awp_types::SiteKind;
50//!
51//! let id = uuid::Uuid::new_v4();
52//! let personal = template(SiteKind::Personal);
53//! let team = SiteTeam::new(SiteRef::new(id, "notes", "https://notes.example"), &personal);
54//! assert!(team.runs(AgentRole::Guardian) && !team.runs(AgentRole::Revenue));
55//!
56//! let inputs = CharterInputs::new(id, "Notes", "user:wanjiru", "Essays on cities.", vec!["en".parse().unwrap()], "USD");
57//! let charter = personal.draft_charter(&team, &inputs);
58//! assert!(charter.validate().is_ok());
59//! ```
60//!
61//! ## Stability
62//!
63//! Experimental — new in 3.0.0 (spec 3.5), and its API may change while the spec lands. See
64//! [STABILITY.md](https://github.com/zavora-ai/adk-rust/blob/main/STABILITY.md).
65
66#![warn(missing_docs)]
67
68pub mod alarms;
69pub mod audit;
70pub mod channel;
71pub mod contract;
72pub mod deploy;
73pub mod edge;
74pub mod experiments;
75pub mod inbox;
76pub mod incident;
77pub mod jobs;
78pub mod kinds;
79pub mod leads;
80pub mod learning;
81pub mod measurement;
82pub mod observability;
83pub mod onboarding;
84pub mod packs;
85pub mod playbooks;
86pub mod publish_delay;
87pub mod quotes;
88pub mod repository;
89pub mod review;
90pub mod team;
91pub mod themes;
92pub mod ui;
93pub mod upkeep;
94pub mod wallet;
95pub mod workflows;