Skip to main content

rto_spec/
lib.rs

1//! House-style ADR/blueprint/site-page parsing and `roteiro check` drift
2//! detection.
3//!
4//! An ADR becomes an `adr` node with `adr_section` children; its
5//! `[[path#Symbol]]` wiki-links and `@rto:<id>` source annotations become
6//! `authored` edges into the derived code graph. [`check::run`] validates those
7//! links against the graph and fails on drift (a link to a missing symbol, or a
8//! `@rto:` annotation to an unknown or superseded ADR).
9//!
10//! [`SitePage`] is the same treatment for the public website: a document that
11//! declares itself published becomes a `site_page` node whose links are
12//! drift-checked like an ADR's, so roteiro.dev stops being the one documentation
13//! surface outside the gate. See [`site`](mod@site) for why publication is a
14//! frontmatter marker rather than a directory.
15
16mod adr;
17mod annotate;
18mod blueprint;
19mod check;
20mod import;
21mod lat;
22mod layer;
23mod site;
24mod spec;
25mod text;
26mod tool_check;
27
28pub use adr::{
29    AdrDoc, AdrMeta, AdrStatus, DocVersion, InlineVersionRef, ParseError, Section, VersionFacts,
30    WikiLink, parse_adr,
31};
32pub use annotate::{Annotation, scan_annotations};
33pub use blueprint::{BlueprintDoc, is_blueprint, parse_blueprint};
34pub use check::{
35    CheckReport, Validation, Violation, ViolationKind, run, run_layer, validate, validate_layer,
36};
37pub use import::{GRAPHIFY_REF, GraphifyImport, ImportError, ImportReport, import_graphify};
38pub use lat::{
39    LAT_REF, LatAnnotation, LatImport, LatReport, import_lat, import_lat_backlinks,
40    resolve_lat_ref, scan_lat_annotations,
41};
42pub use layer::{
43    AuthoredDocs, AuthoredLayer, BlobReader, authored_blobs, authored_docs, authored_docs_from,
44    authored_layer, authored_layer_from,
45};
46pub use site::{
47    MARKER_FIELD as SITE_PAGE_FIELD, ParseError as SiteParseError, SitePage, is_site_page,
48    parse_site_page, site_nav,
49};
50pub use spec::{
51    SPEC_SCHEMA, SpecContext, SymbolContext, apply_drafts, context, draft_prompt, draft_targets,
52    scaffold_adr, scaffold_blueprint,
53};
54pub use tool_check::{CheckedAgainst, Gate, TOOL_CHECK_SCHEMA, ToolCheck, tool_check};