A11 (C++ runtime)
Native C++ implementation of the A11 streaming action runtime
Loading...
Searching...
No Matches
a11::flow Namespace Reference

Namespaces

namespace  catalogue
 Action and type metadata supplied to Flow tooling.
 
namespace  discover
 Source scanning for project action declarations.
 
namespace  graph
 
namespace  internal
 
namespace  interpreter
 
namespace  pattern
 
namespace  syntax
 
namespace  tool
 
namespace  vocabulary
 Word sets and argument shapes shared by language frontends.
 

Classes

struct  ActionDeclaration
 Import an action interface and representable object metadata for generation. More...
 
struct  CallOptions
 Typed modifiers for an invocation expression. More...
 
struct  CodeInfo
 Published diagnostic code metadata for documentation and a11 flow codes. More...
 
struct  CoerceContext
 What coercion needs besides the value and the type. More...
 
class  CompilationBudget
 One cooperative deadline and work counter for a compilation request. More...
 
struct  CompilationLimits
 Host-controlled bounds shared by parsing, linking and semantic analysis. More...
 
class  CompiledProgram
 One flow file, compiled: the plans, the graphs, and the tree they borrow. More...
 
struct  CompleteResult
 What may be written at an offset, and the word already typed there. More...
 
struct  Description
 What is at one offset, described. More...
 
struct  Diagnostic
 Flow problem rendered by the CLI, JSON and SARIF writers, and editors. More...
 
struct  DocumentChange
 The source edits committed atomically by one document transaction. More...
 
struct  DocumentSymbol
 One thing a document declares, and the things declared inside it. More...
 
struct  DocumentSymbolHandle
 A symbol's identity in one revision of an owning document. More...
 
struct  DtoPlan
 One compiled struct: a shape a port may be typed with. More...
 
struct  Edit
 One replacement of a span of source. An empty text is a deletion. More...
 
struct  EvalContext
 
class  Expression
 A native source expression whose emitter supplies required grouping. More...
 
struct  ExpressionInfo
 The statically known interface of one expression, borrowing its program. More...
 
struct  FieldPlan
 One field of a struct, resolved. More...
 
struct  Fix
 Source edits supplied with a diagnostic. More...
 
class  FlowBuilder
 An implemented flow or interface, constructed with native typed helpers. More...
 
struct  FlowPlan
 One compiled flow: what a caller sees, and what the runtime will do. More...
 
struct  FormatOptions
 What the formatter is allowed to decide. More...
 
struct  FormatPart
 What an expression is evaluated against. More...
 
struct  FormatResult
 Formatted source, edits, and diagnostics. More...
 
struct  FrameOptions
 Execution-frame storage policy, independent of Flow semantics. More...
 
struct  FrameStats
 Requested frame capacity, including block headers and unused optional slots. More...
 
struct  HeaderPlan
 One declared header. More...
 
class  HostBridge
 What the process running a flow knows and the language does not. More...
 
class  HostObject
 A value only the host knows what to do with. More...
 
struct  ImportSelection
 
struct  LexOptions
 What to keep while lexing. More...
 
struct  LexResult
 Tokens, and what could not be read. More...
 
class  LineIndex
 Line and column lookup over one source text. More...
 
struct  LinkedModule
 Owning syntax and source snapshot for a linked module graph. More...
 
class  ModuleDocument
 Editable source, separate from immutable linked and executable snapshots. More...
 
struct  ModuleGraphChange
 A validated rename transaction over the supplied source snapshots. More...
 
struct  ModuleMember
 One visible namespace member and its linked identity. More...
 
struct  ModuleRange
 One original document's interval in linked analysis source. More...
 
struct  ModuleSource
 Source supplied by a host, with its canonical identity. More...
 
class  NodeFragmentObject
 A typed raw fragment carried through a fragment-view Flow pipeline. More...
 
class  NodeReferenceObject
 A typed reference carried through a fragment-view Flow pipeline. More...
 
struct  ParseResult
 The flows a file declares, and everything wrong with it. More...
 
struct  PipelinePorts
 The unique unsupplied input and unique output of a whole-stream invocation. More...
 
struct  PortPlan
 One declared port of a flow, resolved. More...
 
struct  Position
 Source position with a byte offset and 1-based line and column. More...
 
struct  PreparedExpressions
 Immutable, bounded literal preparation shared by execution activations. More...
 
struct  Program
 Every flow and shape one source file declares. More...
 
struct  Proposal
 One thing that may be written at an offset. More...
 
struct  Range
 Half-open span of source, [start, end). More...
 
struct  RelatedDiagnostic
 Another source range explaining a diagnostic. More...
 
struct  ResolvedFlow
 One flow, resolved: its plan, its names, and what is wrong with it. More...
 
struct  ResolveResult
 A whole file, resolved. More...
 
struct  RunOptions
 
struct  SchemaImport
 The shapes a JSON Schema describes, and what would not fit. More...
 
struct  SemanticToken
 One nonoverlapping semantic span; string escapes have their own spans. More...
 
struct  SingleItemAnalysis
 
struct  SingleItemFact
 Evidence for transport selection, independent of declared cardinality. More...
 
class  Statement
 Typed statements for constructing executable bodies. More...
 
struct  StepPlan
 One resolved statement in the a11 flow describe plan. More...
 
struct  StringEscape
 The source range of an escape inside a string token. More...
 
class  StructBuilder
 Construct a struct using the language's existing shape descriptor. More...
 
struct  Symbol
 One name, what it is, and what became of it. More...
 
class  TextIndex
 A document, and the offset arithmetic every editor protocol needs over it. More...
 
struct  Token
 One token: what it is, where it is, and what it holds. More...
 
struct  TransportStats
 Optional per-run counters; transport pumps count actual fiber entry. More...
 
class  Value
 An immutable Flow value with shared containers and long text. More...
 
class  WindowBuffer
 Builds immutable overlapping lists from append-only blocks. More...
 

Typedefs

using ModuleSources = absl::flat_hash_map< std::string, std::string >
 
using ModuleResolver = std::function< absl::StatusOr< ModuleSource >(std::string_view reference, std::string_view importer)>
 
using ModuleLimits = CompilationLimits
 Limits applied before imported source is parsed or linked.
 
using FormatTemplate = std::vector< FormatPart >
 

Enumerations

enum class  ProposalKind {
  kStatement , kDeclaration , kModifier , kStage ,
  kFunction , kType , kStatusCode , kLogLevel ,
  kConstant , kPortModifier , kFlow , kPort ,
  kNode , kNodeMap , kCall , kBarrier ,
  kVariable , kHeader , kField
}
 Completion categories published by flow.completions/v1. More...
 
enum class  Refinement { kYes , kNo , kUnknown }
 Whether available metadata proves payload refinement. More...
 
enum class  Severity { kError , kWarning , kWeakWarning , kInformation }
 Severity of a Flow diagnostic. More...
 
enum class  Family {
  kSyntax , kForm , kName , kSequence ,
  kBarrier , kUnused
}
 Diagnostic category used by editors and build gates. More...
 
enum class  SyntaxTarget {
  kSublime , kPygments , kVsCode , kVsCodeInjection ,
  kBrowser
}
 An editor definition the language can write for itself. More...
 
enum class  SemanticKind {
  kComment , kString , kStringEscape , kNumber ,
  kDuration , kDeclarationKeyword , kStatementKeyword , kModifierKeyword ,
  kStage , kBuiltin , kType , kBuiltinType ,
  kStatusCode , kLogLevel , kConstant , kWordOperator ,
  kFlowName , kActionName , kNodeMapName , kNamespaceName ,
  kMember , kPortName , kIdentifier , kFlowOperator ,
  kOperator , kBrace , kParenthesis , kBracket ,
  kPunctuation , kBad
}
 What a token means where it stands, which is what a reader colours by. More...
 
enum class  SymbolClass {
  kModule , kFlow , kDto , kField ,
  kPort , kHeader , kNodeMap , kNode ,
  kCall , kBarrier , kVariable , kExternal
}
 Moving around a document: what is under the caret, what the file declares, and where a name was bound. More...
 
enum class  OffsetBasis { kBytes , kUtf16 }
 Which basis the offsets in a request and its answer are counted in. More...
 
enum class  SymbolKind {
  kSink , kInputPort , kOutputPort , kHeader ,
  kCall , kNode , kNodeMap , kBarrier ,
  kLoopVariable , kCarry , kValue
}
 What a name means inside a flow. More...
 
enum class  ExpressionCategory {
  kSink , kUnknown , kValue , kStream ,
  kCall , kNode , kCompletion
}
 Native result categories used by resolution and editor queries. More...
 
enum class  TokenKind {
  kNewline , kSemicolon , kComment , kString ,
  kNumber , kDuration , kWord , kDot ,
  kQuestionDot , kQuestionBracket , kRange , kSpread ,
  kArrow , kCarry , kEqual , kEqualEqual ,
  kBangEqual , kLess , kLessEqual , kGreater ,
  kGreaterEqual , kPlus , kMinus , kPipe ,
  kColon , kScope , kStar , kSlash ,
  kPercent , kComma , kLeftBrace , kRightBrace ,
  kLeftParen , kRightParen , kLeftBracket , kRightBracket ,
  kBad , kEnd
}
 What kind of thing a token is. More...
 

Functions

CompleteResult CompleteAt (std::string_view source, size_t offset, const catalogue::Catalogue &known, CompilationLimits limits, CompilationBudget *budget, const LinkedModule *linked)
 
std::string_view ProposalKindName (ProposalKind kind)
 The name of a proposal kind in the output format, in kebab case.
 
CompleteResult CompleteAt (std::string_view source, size_t offset, const catalogue::Catalogue &known=catalogue::Catalogue::Builtin(), CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr, const LinkedModule *absl_nullable linked=nullptr)
 Returns grammar and scope-aware proposals at offset in source.
 
absl::StatusOr< PipelinePorts > SelectPipelinePorts (const FlowPlan &flow, absl::Span< const std::string > supplied)
 
absl::StatusOr< const PortPlan * > SelectPipelineStarterOutput (const FlowPlan &flow, absl::Span< const std::string > supplied)
 The unique output of a call with every input supplied explicitly.
 
std::vector< std::string_view > FieldTypeNames (const FieldPlan &field)
 Every type named by a field, including nested container parameters.
 
void MarkBinaryTypes (std::vector< DtoPlan > &types, CompilationBudget *budget)
 
std::string CanonicalPayloadType (std::string_view type)
 Canonical payload spelling for alias and generic equality.
 
Refinement RefinesType (std::string_view actual, std::string_view expected, const Program &program)
 Compare payload types using native aliases and document shapes.
 
std::string HeaderBytes (const syntax::Constant &constant)
 Encode a constant using the native action-header textual convention.
 
absl::Status MergeContract (FlowPlan &effective, const FlowPlan &contribution, const Program &program)
 Conjoin compatible interfaces without changing executable identity.
 
absl::Status CheckImplementation (const FlowPlan &actual, const FlowPlan &declared, const Program &program)
 Validate the actual implementation against every declared obligation.
 
void MarkBinaryTypes (std::vector< DtoPlan > &types, CompilationBudget *absl_nullable budget=nullptr)
 Propagate byte payloads through the shape dependency graph.
 
std::string_view SeverityName (Severity severity)
 The spelling of a severity in the output formats.
 
std::string_view FamilyName (Family family)
 The spelling of a family in the output formats.
 
Severity SeverityFromName (std::string_view name)
 Severity for a name from the output formats, or kError if unknown.
 
Family FamilyFromName (std::string_view name)
 Family for a name from the output formats, or kSyntax if unknown.
 
const Diagnostic *absl_nullable FirstError (absl::Span< const Diagnostic > diagnostics)
 The first error in diagnostics, or nullptr if none is an error.
 
absl::Span< const CodeInfo > KnownCodes ()
 Every diagnostic code the language can produce, sorted by code.
 
const CodeInfo *absl_nullable FindCode (std::string_view code)
 The entry for a code, or nullptr if nothing publishes it.
 
void SortDiagnostics (std::vector< Diagnostic > &diagnostics)
 Sorts diagnostics into the order every frontend presents them in: by position, then by code, so two runs over the same file agree byte for byte.
 
absl::StatusOr< std::string > DeclarationSource (const FlowPlan &plan)
 Emit a declaration without introducing an action-layer dependency.
 
nlohmann::json DiagnosticToJsonValue (const Diagnostic &diagnostic)
 One diagnostic, as it appears in the envelope.
 
Diagnostic DiagnosticFromJsonValue (const nlohmann::json &value)
 Reads a diagnostic, ignoring unknown fields and defaulting missing ones.
 
nlohmann::json DiagnosticsToJsonValue (std::string_view source, absl::Span< const Diagnostic > diagnostics)
 The flow.diagnostics/v1 envelope, with source and severity counts.
 
std::string DiagnosticsToJson (std::string_view source, absl::Span< const Diagnostic > diagnostics)
 The envelope, serialised with a trailing newline and two-space indent.
 
nlohmann::json CodesToJsonValue ()
 The published code table, as flow.codes/v1.
 
nlohmann::json VocabularyToJsonValue ()
 The language word sets as flow.vocabulary/v1.
 
nlohmann::json DiagnosticsToSarifValue (std::string_view source, absl::Span< const Diagnostic > diagnostics)
 A SARIF 2.1.0 log for one file, with rule metadata from [KnownCodes].
 
std::string DiagnosticsToSarif (std::string_view source, absl::Span< const Diagnostic > diagnostics)
 The SARIF log, serialised with a trailing newline.
 
nlohmann::json ConstantToJsonValue (const syntax::Constant &constant)
 A constant as the syntax format writes it.
 
nlohmann::json NodeToJsonValue (const syntax::Node &node)
 A syntax node and its subtree.
 
nlohmann::json SyntaxToJsonValue (std::string_view source, const ParseResult &result)
 The flow.syntax/v1 envelope, including partial trees and diagnostics.
 
std::string SyntaxToJson (std::string_view source, const ParseResult &result)
 The envelope, serialised with a trailing newline and two-space indent.
 
nlohmann::json TokensToJsonValue (std::string_view source_name, std::string_view source)
 The flow.tokens/v1 envelope, with token kinds and semantic classes.
 
std::string TokensToJson (std::string_view source_name, std::string_view source)
 The envelope, serialised with a trailing newline and two-space indent.
 
nlohmann::json FormatToJsonValue (const FormatResult &result)
 The flow.format/v1 envelope: the formatted text, and what it took.
 
nlohmann::json CompletionsToJsonValue (const CompleteResult &result)
 The flow.completions/v1 envelope: what may be written at an offset.
 
nlohmann::json PlanToJsonValue (std::string_view source_name, const Program &program)
 The flow.plan/v1 envelope for resolved flows.
 
nlohmann::json DtoToJsonValue (const DtoPlan &dto, const Program *absl_nullable program=nullptr)
 A resolved shape.
 
std::string PlanToJson (std::string_view source_name, const Program &program)
 The envelope, serialised with a trailing newline and two-space indent.
 
std::string DiagnosticToText (std::string_view source, const Diagnostic &diagnostic)
 path:line:column: severity: message [code] on one line.
 
std::string FileModuleIdentity (std::string_view reference)
 Lexical source identity; normalizing it performs no target-path inspection.
 
ModuleResolver FileModuleResolver (size_t max_bytes=8 *1024 *1024, ModuleSources overrides={}, std::vector< std::string > approved_roots={})
 Filesystem imports confined to explicitly approved roots without symlinks.
 
FormatResult Format (std::string_view source, FormatOptions options, CompilationLimits limits, CompilationBudget *budget)
 
FormatResult Format (std::string_view source, FormatOptions options={}, CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr)
 Formats Flow source with stable whitespace and equivalent syntax.
 
std::string FragmentStartPattern ()
 Native document-start pattern used by host-string injectors.
 
absl::Span< const SyntaxTarget > SyntaxTargets ()
 Every target, for a command that offers a choice of them.
 
std::string_view SyntaxTargetName (SyntaxTarget target)
 The name a target is asked for by: sublime.
 
bool SyntaxTargetFromName (std::string_view name, SyntaxTarget &target)
 A target from its name, or nullopt.
 
std::string_view SyntaxTargetPath (SyntaxTarget target)
 Where the generated file belongs, relative to the repository root.
 
std::string GenerateSyntax (SyntaxTarget target)
 Generates the target grammar from the Flow vocabulary.
 
std::string_view SemanticKindName (SemanticKind kind)
 The name of a semantic kind in the output formats, in kebab case.
 
SemanticKind SemanticKindFromName (std::string_view name)
 The kind a name refers to, or kIdentifier if it is not one.
 
std::vector< SemanticToken > Highlight (absl::Span< const Token > tokens)
 Classify a token stream.
 
void RefinePorts (std::string_view source, std::vector< SemanticToken > &semantic)
 Refine lexical tokens using parsed type positions and resolved bindings.
 
std::vector< Diagnostic > Inspect (std::string_view source, const ParseResult &parsed, const ResolveResult &resolved)
 Reports nonfatal Flow diagnostics from parsed and resolved source.
 
LexResult Lex (std::string_view source, LexOptions options={})
 Lexes Flow source, ending with one end token.
 
LinkedModule LinkModules (std::string source, std::string identity, const ModuleSources &sources, ModuleResolver resolver, ModuleLimits limits, CompilationBudget *budget)
 
LinkedModule LinkModules (std::string source, std::string identity, const ModuleSources &sources={}, ModuleResolver resolver={}, ModuleLimits limits={}, CompilationBudget *absl_nullable budget=nullptr)
 Link lexical imports and private dependencies using host-supplied sources.
 
std::string WordMarkdown (std::string_view name, vocabulary::WordRole role)
 One word or mark of the language, written out as reference: what it does, what it takes, how it behaves, and a line of Flow using it.
 
std::string StageMarkdown (std::string_view name)
 A pipeline stage, written out as reference.
 
std::string BuiltinMarkdown (std::string_view name)
 A built-in function, the same way.
 
std::string ActionMarkdown (const catalogue::ActionInfo &action)
 An action, written out as the Markdown a reader wants to see: what it does, then every port it has.
 
std::string InvocationNote (std::string_view mode)
 
const syntax::CallExpression * CallAt (const ParseResult &parsed, size_t offset)
 
std::string PortMarkdown (std::string_view name, std::string_view type, bool required, bool unary, std::string_view description)
 One port, written out as the Markdown a reader wants beside its name.
 
std::string FlowMarkdown (const FlowPlan &flow)
 A flow of the document, written out the same way: what it does, then its ports and which direction each runs.
 
std::string ShapeMarkdown (const DtoPlan &shape)
 A struct, written out the same way: how many fields, then each of them.
 
std::string_view SymbolClassName (SymbolClass kind)
 
Range Widened (const LineIndex &lines, const Range &range, const Range &selection)
 Expands a symbol range to include its selection.
 
Range ConstructRange (const LineIndex &lines, absl::Span< const Token > tokens, const syntax::Location &opened, const Range &selection)
 
std::vector< DocumentSymbol > Symbols (std::string_view source, CompilationLimits limits, CompilationBudget *budget)
 
Description Describe (std::string_view source, size_t offset, const catalogue::Catalogue &known, CompilationLimits limits, CompilationBudget *budget, const LinkedModule *linked)
 
std::vector< DocumentSymbol > Symbols (std::string_view source, CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr)
 Every symbol a document declares, nested as it is written.
 
Description Describe (std::string_view source, size_t offset, const catalogue::Catalogue &known=catalogue::Catalogue::Builtin(), CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr, const LinkedModule *absl_nullable linked=nullptr)
 What is at offset, and where it came from.
 
bool OffsetBasisFromName (std::string_view name, OffsetBasis &basis)
 The basis a request named, or kBytes when it named none.
 
std::string_view OffsetBasisName (OffsetBasis basis)
 The name of a basis, for a message and for the JSON.
 
void RebaseToUtf16 (nlohmann::json &answer, const TextIndex &index)
 Rewrite every document offset in an answer from bytes into UTF-16 units.
 
void RebaseToUtf16 (nlohmann::json &answer, const TextIndex &index, const absl::flat_hash_map< std::string, TextIndex > &documents)
 Rebase each document with its own pinned source index.
 
ParseResult Parse (std::string_view source, CompilationLimits limits, CompilationBudget *budget)
 
absl::StatusOr< syntax::TypeExpression > ParseTypeExpression (std::string_view source, CompilationLimits limits, CompilationBudget *budget)
 
ParseResult ParseTokens (std::string_view source, absl::Span< const Token > tokens, std::vector< Diagnostic > diagnostics, CompilationLimits limits, CompilationBudget *budget)
 
ParseResult Parse (std::string_view source, CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr)
 Parses Flow source into a recoverable tree and diagnostics.
 
absl::StatusOr< syntax::TypeExpression > ParseTypeExpression (std::string_view source, CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr)
 Parse a standalone type with the same grammar and limits as a declaration.
 
ParseResult ParseTokens (std::string_view source, absl::Span< const Token > tokens, std::vector< Diagnostic > diagnostics, CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr)
 Parse an already-lexed stream, sharing the lex diagnostics.
 
std::string_view SymbolKindName (SymbolKind kind)
 The name of a symbol kind, for a message and for the JSON.
 
ResolveResult Resolve (std::string_view source, const ParseResult &parsed, bool build_graph, const Program *context, CompilationLimits limits, CompilationBudget *budget)
 
ResolveResult Resolve (std::string_view source, const ParseResult &parsed, bool build_graph=false, const Program *absl_nullable context=nullptr, CompilationLimits limits={}, CompilationBudget *absl_nullable budget=nullptr)
 Resolves names, ports, scopes, node maps, and types in a parsed program.
 
absl::StatusOr< actions::ActionHandler > MakeHandler (std::shared_ptr< const CompiledProgram > program, std::string_view flow, RunOptions options={})
 The action handler that runs one flow of program.
 
absl::StatusOr< actions::ActionHandler > MakeEntryHandler (std::shared_ptr< const CompiledProgram > program, RunOptions options={})
 The action handler that runs the program's entry flow.
 
absl::StatusOr< actions::ActionSchema > FlowSchema (const FlowPlan &plan, const Program *absl_nullable shapes=nullptr)
 The [actions::ActionSchema] a flow presents.
 
ActionDeclaration DeclareAction (const actions::ActionSchema &schema)
 
absl::StatusOr< actions::ActionSchema > FlowSchema (const FlowPlan &plan, const Program *shapes)
 
nlohmann::json DtoToJsonSchema (const DtoPlan &dto, const Program &program)
 Converts a Flow shape to JSON Schema Draft 2020-12.
 
SchemaImport JsonSchemaToDtos (const nlohmann::json &schema, std::string_view name)
 Imports shapes from schema, using name when the root has no name.
 
std::string DtoToFlow (const DtoPlan &dto)
 Renders one shape as formatted Flow source.
 
absl::Span< const std::string_view > Methods ()
 Every method [Handle] knows, in the order --help lists them.
 
std::string_view MethodSummary (std::string_view method)
 What a method takes and gives back, one line, for --help.
 
nlohmann::json Handle (const nlohmann::json &request, ModuleResolver resolver={}, CompilationLimits limits={})
 Handles one language service request and returns its JSON envelope.
 
bool CheckSingleItemStructure (const graph::FlowGraph &flow)
 Validate graph structure independently of transport candidate discovery.
 
SingleItemAnalysis AnalyseSingleItems (const graph::FlowGraph &flow, CompilationBudget *budget=nullptr, size_t max_work=200000)
 Infer and verify prefix emission bounds, with a bounded optional work quota.
 
nlohmann::json SingleItemsToJson (const graph::FlowGraph &flow, const SingleItemAnalysis &analysis, bool enabled)
 Explain transport decisions without changing the public source plan.
 
absl::Duration SecondsDuration (double total)
 A duration of total seconds, including negative and infinite values.
 
std::optional< absl::Duration > ParseDuration (std::string_view text)
 Parse duration text, including compound units and bare seconds.
 
std::optional< absl::Time > ParseTime (std::string_view text)
 Parse an instant as RFC 3339 text or a UTC calendar date.
 
std::string_view KindName (TokenKind kind)
 The name of a kind, as a11.flow.lexer spells it.
 
TokenKind KindFromName (std::string_view name)
 The kind a name from [KindName] refers to, or kBad if it is not one.
 
bool operator== (const Value &left, const Value &right)
 
std::unique_ptr< HostBridge > NativeHostBridge ()
 A host bridge backed by the C++ serialization registry.
 
std::optional< Value > LookupOptional (const Value &value, const Value &key)
 
absl::StatusOr< Value > LookupChecked (const Value &value, const Value &key)
 
Value Lookup (const Value &value, const Value &key)
 Take key out of value: a mapping key, an index, or a field.
 
bool Truthy (const Value &value)
 Whether value counts as true, as an if and a where decide it.
 
std::string AsText (const Value &value)
 value as text, the way the text stage and builtin render it.
 
Value AsNumber (const Value &value)
 value as a number, or zero when there is nothing to read.
 
std::optional< std::int64_t > ExactInt64 (const Value &value)
 
double AsDouble (const Value &value)
 AsNumber as a double, for the places that only want the magnitude.
 
Value AsHole (pattern::HoleType type, std::string_view text)
 One hole's text, read as the hole said to read it.
 
absl::StatusOr< Value > MatchPattern (std::string_view pattern, std::string_view subject)
 The fields a pattern pulls out of subject, or null where it does not fit.
 
Value MatchCompiled (const pattern::Pattern &pattern, std::string_view subject)
 The same, against a pattern already compiled.
 
Value AsJson (const Value &value)
 Text parsed as JSON; anything already decoded is left alone.
 
Value Truncate (const Value &value, std::int64_t size)
 The first size of a value: characters, bytes, elements or pairs.
 
std::string JsonText (const Value &value)
 Renders JSON with sorted keys, spaced separators, and escaped non-ASCII.
 
double DurationSeconds (absl::Duration value)
 A duration as a number of seconds, for every duration there is.
 
absl::Duration AsDuration (const Value &value)
 A duration from a duration, from written text, or from seconds.
 
absl::Time AsTime (const Value &value)
 An instant from an instant, from RFC 3339 text, or from epoch seconds.
 
std::string DurationText (absl::Duration value, std::string_view spec={})
 A duration as text: 1m30s by default, or one unit when spec names one.
 
std::string TimeText (absl::Time value, std::string_view spec={})
 An instant as text: RFC 3339 in UTC, a strftime pattern, or epoch.
 
FormatTemplate CompileStrformat (std::string_view text)
 
std::string StrformatCompiled (const FormatTemplate &parts, absl::Span< const Value > arguments)
 
std::string Strformat (const Value &format, absl::Span< const Value > arguments)
 format with each % conversion replaced by one of arguments.
 
absl::StatusOr< Value > CallBuiltin (std::string_view name, absl::Span< const Value > arguments, HostBridge *absl_nullable bridge, const PreparedExpressions *prepared)
 
absl::StatusOr< Value > CoerceShape (const DtoPlan &shape, const Value &value, const CoerceContext &context)
 Make value a value of shape: fill its defaults, check its bounds, and coerce every field to the type the shape gives it.
 
absl::StatusOr< Value > Coerce (const Value &value, const syntax::TypeExpression &type, const CoerceContext &context)
 Make value a value of the type type names.
 
int Order (const Value &left, const Value &right)
 Where two values sit relative to one another: -1, 0 or 1.
 
absl::StatusOr< Value > Add (const Value &left, const Value &right)
 left + right, as an expression means it.
 
absl::StatusOr< Value > Evaluate (const syntax::Node &node, const EvalContext &context)
 Evaluate one expression.
 
Value StatusRecord (const absl::Status &status)
 A status as the record a flow sees when it looks at an outcome.
 
Value FailureRecord (const absl::Status &status, Value item, std::int64_t seq)
 A tolerated stage failure, with the original item and zero-based position.
 
std::optional< absl::StatusCode > StatusCodeOf (const Value &value)
 The canonical code value names, by name or by number, or nullopt.
 
absl::Status StatusOfRecord (const Value &record)
 The status a record like the one above describes.
 
absl::StatusOr< Value > CallBuiltin (std::string_view name, absl::Span< const Value > arguments, HostBridge *absl_nullable bridge, const PreparedExpressions *absl_nullable prepared=nullptr)
 Call one of the language's fixed functions.
 

Variables

constexpr std::string_view kCompletionsFormat = "flow.completions/v1"
 The format field of the completions envelope.
 
constexpr std::string_view kDiagnosticsFormat = "flow.diagnostics/v1"
 Envelope format identifiers. Readers ignore unknown fields in a version.
 
constexpr std::string_view kCodesFormat = "flow.codes/v1"
 
constexpr std::string_view kSyntaxFormat = "flow.syntax/v1"
 
constexpr std::string_view kTokensFormat = "flow.tokens/v1"
 
constexpr std::string_view kVocabularyFormat = "flow.vocabulary/v1"
 
constexpr std::string_view kFormatFormat = "flow.format/v1"
 
constexpr std::string_view kSymbolsFormat = "flow.symbols/v1"
 The format field of the symbols envelope.
 
constexpr std::string_view kHoverFormat = "flow.hover/v1"
 The format field of the hover envelope.
 
constexpr std::string_view kDefinitionFormat = "flow.definition/v1"
 The format field of the definition envelope.
 
constexpr std::string_view kPlanFormat = "flow.plan/v1"
 The format field of the plan envelope.
 
constexpr size_t kQueueDepth = 8
 Maximum values a pipe may hold ahead of its reader.
 
constexpr std::string_view kSchemaFormat = "flow.schema/v1"
 The format field of the schema envelope.
 
constexpr std::string_view kFlowTypeKey = "x-a11-type"
 The extension key that says which Flow type a string really is.
 
constexpr std::string_view kFlowOrderKey = "x-a11-order"
 Extension key preserving a shape's field declaration order.
 

Typedef Documentation

◆ FormatTemplate

using a11::flow::FormatTemplate = typedef std::vector<FormatPart>

◆ ModuleLimits

Limits applied before imported source is parsed or linked.

◆ ModuleResolver

using a11::flow::ModuleResolver = typedef std::function<absl::StatusOr<ModuleSource>( std::string_view reference, std::string_view importer)>

◆ ModuleSources

using a11::flow::ModuleSources = typedef absl::flat_hash_map<std::string, std::string>

Enumeration Type Documentation

◆ ExpressionCategory

enum class a11::flow::ExpressionCategory
strong

Native result categories used by resolution and editor queries.

Enumerator
kSink 
kUnknown 
kValue 
kStream 
kCall 
kNode 
kCompletion 

◆ Family

enum class a11::flow::Family
strong

Diagnostic category used by editors and build gates.

Enumerator
kSyntax 

Missing or misplaced Flow syntax.

kForm 

Invalid language form or form in an invalid position.

kName 

Unresolved name or invalid use of a resolved name.

kSequence 

Stage or access sequence with invalid or ineffective behavior.

kBarrier 

Invalid barrier, loop termination, or execution order.

kUnused 

Unread status, unused binding, or unused declaration.

◆ OffsetBasis

enum class a11::flow::OffsetBasis
strong

Which basis the offsets in a request and its answer are counted in.

Enumerator
kBytes 

Bytes from the start of the file: the language's own, and the default.

kUtf16 

UTF-16 code units from the start of the file: what a JVM or JavaScript editor host indexes its document buffer with.

◆ ProposalKind

enum class a11::flow::ProposalKind
strong

Completion categories published by flow.completions/v1.

Enumerator
kStatement 

A word that opens a statement: run, wait, for.

kDeclaration 

A word that declares something: in, header, describe.

kModifier 

A word that follows a call: tee, timeout, forward headers.

kStage 

A pipeline stage, offered after a |.

kFunction 

One of the fixed functions.

kType 

A port type.

kStatusCode 

A canonical status code, as fail names one.

kLogLevel 

A log level, as log and logf name one.

kConstant 

true, false, null, it.

kPortModifier 

What a port says about itself: stream, required.

kFlow 

A flow of this file, offered as a call target.

kPort 

A port of this flow, or of a call.

kNode 

A node of the flow's own.

kNodeMap 

A node map.

kCall 

A bound run/call step.

kBarrier 

A bound wait/close.

kVariable 

A loop variable, the index a loop binds, or what a repeat carries.

kHeader 

A header, under its alias.

kField 

A field of something: a status's code, a node's id.

◆ Refinement

enum class a11::flow::Refinement
strong

Whether available metadata proves payload refinement.

Enumerator
kYes 
kNo 
kUnknown 

◆ SemanticKind

enum class a11::flow::SemanticKind
strong

What a token means where it stands, which is what a reader colours by.

Finer-grained than the grammar needs: a word is significant or not to a parser, but a reader wants to tell a port type from a pipeline stage from a status code, because that is the distinction they are making. These are the names the output format uses and the names an editor maps to its own palette, so they are part of the contract.

Enumerator
kComment 
kString 
kStringEscape 
kNumber 
kDuration 
kDeclarationKeyword 

flow, in, out, header, node, nodes, as, default.

kStatementKeyword 

run, call, try, wait, for, if, fail, and the rest.

kModifierKeyword 

tee, via, timeout, after, with, id, forward headers.

kStage 

A stage, after a | or as a bare then/where.

kBuiltin 

One of the fixed functions, where it is being called.

kType 

A port type: string, list, a11.sdk.AudioBuffer.

kBuiltinType 

A standard type, using the primitive-type keyword palette.

kStatusCode 

A canonical status code: not_found, NOT_FOUND.

kLogLevel 

A log level a log or logf named: warning, DEBUG.

kConstant 

true, false, null, it.

kWordOperator 

and, or, not.

kFlowName 

The name a flow declaration gives.

kActionName 

The action a run/call names.

kNodeMapName 

The name a nodes declaration, or a via, gives a node map.

kNamespaceName 

A module declaration, alias, or qualifier before ::.

kMember 

What follows a .: a port, a field, a node's id.

kPortName 

A port of the flow: its declaration, and every mention of it.

Told apart from every other name a flow binds because a port is the one thing that crosses the flow's boundary – it is the interface, and a reader following where data comes from and goes wants to see which names are the outside world and which are local plumbing. Deciding it needs the resolver, so it is [RefinePorts] rather than [Highlight] that says so.

kIdentifier 

Any other word: a node, a step, a loop variable, a value value.

kFlowOperator 

->, <-, |: where a stream is going.

kOperator 

=, ==, <, +, and the rest.

kBrace 
kParenthesis 
kBracket 
kPunctuation 

., :, ,.

kBad 

Something the language has no meaning for.

◆ Severity

enum class a11::flow::Severity
strong

Severity of a Flow diagnostic.

Enumerator
kError 

Compilation fails. a11 flow check exits nonzero.

kWarning 

Compilation succeeds, but behavior may differ from the source's intent.

kWeakWarning 

Compilation succeeds, but a source element has no effect.

kInformation 

Non-blocking information.

◆ SymbolClass

enum class a11::flow::SymbolClass
strong

Moving around a document: what is under the caret, what the file declares, and where a name was bound.

Navigation uses the parser and resolver so hover, completion, diagnostics, and editor integrations assign the same role and binding to each name. What a thing is, which is what an editor turns into an icon.

Serialized in flow.symbols/v1 and flow.hover/v1.

Enumerator
kModule 
kFlow 
kDto 
kField 
kPort 
kHeader 
kNodeMap 
kNode 
kCall 
kBarrier 
kVariable 
kExternal 

Something the language knows about but the document did not declare: an action, a registered type, a stage, a built-in.

◆ SymbolKind

enum class a11::flow::SymbolKind
strong

What a name means inside a flow.

Enumerator
kSink 

A transfer handle: writable continuation, never payload or a source.

kInputPort 

An in port: read, never written.

kOutputPort 

An out port: written, never read... except by this flow, which may read back what it wrote to one only when it is a node of its own.

See Symbol::readable.

kHeader 

A header, under its alias.

kCall 

A run/call step, bound to a name.

kNode 

A node of the flow's own, from node().

kNodeMap 

A node map, from nodes.

kBarrier 

A bound wait or close: a barrier that also reads as its outcome.

kLoopVariable 

A for variable, or the index every loop binds.

kCarry 

What a repeat carries.

kValue 

One value, read from a stream and given a name by value.

Read as a value wherever an expression is accepted. It is never a write target.

◆ SyntaxTarget

enum class a11::flow::SyntaxTarget
strong

An editor definition the language can write for itself.

Enumerator
kSublime 

editors/sublime-text/A11 Flow.sublime-syntax: a Sublime/TextMate-family YAML grammar, which is also what Zed and a few others read.

kPygments 

editors/pygments/a11flow_lexer.py: a Pygments lexer, which is what colours a fenced flow in A11's own documentation and in anything else built on Pygments (MkDocs, Sphinx, pygmentize).

kVsCode 

editors/vscode/a11flow.tmLanguage.json: a TextMate grammar in the JSON dialect VSCode reads.

Provides lexical highlighting until semantic tokens are available.

kVsCodeInjection 

editors/vscode/a11flow-injection.tmLanguage.json: Flow in host strings.

kBrowser 

Native vocabulary data for the browser fallback highlighter.

◆ TokenKind

enum class a11::flow::TokenKind
strong

What kind of thing a token is.

The same set a11.flow.lexer produces, under the same names – [KindName] returns exactly the strings the Python lexer uses – with one addition: a comment is a token here. The Python lexer drops comments because a parser has no use for them; a highlighter and a formatter do, and one lexer that keeps them serves all three.

Enumerator
kNewline 

The end of a statement. One per run of blank lines, never leading.

kSemicolon 
kComment 

# to the end of the line.

kString 

A quoted string. string_value holds it with escapes resolved.

kNumber 

A number, integral or not. number holds it.

kDuration 

A number with a duration unit: 250ms. duration holds it.

kWord 

A bare word. What it means is the grammar's business, not the lexer's.

kDot 
kQuestionDot 
kQuestionBracket 
kRange 

.. – the range between two bounds, either of which may be left out.

kSpread 

... or ... – everything the thing after it holds, spread in here.

kArrow 
kCarry 
kEqual 
kEqualEqual 
kBangEqual 
kLess 
kLessEqual 
kGreater 
kGreaterEqual 
kPlus 
kMinus 
kPipe 
kColon 
kScope 

Static namespace qualification, distinct from runtime projection.

kStar 
kSlash 
kPercent 
kComma 
kLeftBrace 
kRightBrace 
kLeftParen 
kRightParen 
kLeftBracket 
kRightBracket 
kBad 

A character the language has no meaning for.

Carried rather than thrown so the rest of the file is still read.

kEnd 

One past the last token, so lookahead never runs off the end.

Function Documentation

◆ ActionMarkdown()

std::string a11::flow::ActionMarkdown ( const catalogue::ActionInfo &  action)

An action, written out as the Markdown a reader wants to see: what it does, then every port it has.

Shared by hover and completion.

◆ Add()

absl::StatusOr< Value > a11::flow::Add ( const Value &  left,
const Value &  right 
)

left + right, as an expression means it.

For | sum, | avg and | fold, which add values the way + does: numbers as numbers, durations as durations, an instant and a duration as the shifted instant, and text as text.

◆ AnalyseSingleItems()

SingleItemAnalysis a11::flow::AnalyseSingleItems ( const graph::FlowGraph &  flow,
CompilationBudget *  budget,
size_t  max_work 
)

Infer and verify prefix emission bounds, with a bounded optional work quota.

◆ AsDouble()

double a11::flow::AsDouble ( const Value &  value)

AsNumber as a double, for the places that only want the magnitude.

◆ AsDuration()

absl::Duration a11::flow::AsDuration ( const Value &  value)

A duration from a duration, from written text, or from seconds.

◆ AsHole()

Value a11::flow::AsHole ( pattern::HoleType  type,
std::string_view  text 
)

One hole's text, read as the hole said to read it.

◆ AsJson()

Value a11::flow::AsJson ( const Value &  value)

Text parsed as JSON; anything already decoded is left alone.

◆ AsNumber()

Value a11::flow::AsNumber ( const Value &  value)

value as a number, or zero when there is nothing to read.

Integral where the value was integral, so d of a count is the count.

◆ AsText()

std::string a11::flow::AsText ( const Value &  value)

value as text, the way the text stage and builtin render it.

◆ AsTime()

absl::Time a11::flow::AsTime ( const Value &  value)

An instant from an instant, from RFC 3339 text, or from epoch seconds.

◆ BuiltinMarkdown()

std::string a11::flow::BuiltinMarkdown ( std::string_view  name)

A built-in function, the same way.

◆ CallAt()

const syntax::CallExpression * a11::flow::CallAt ( const ParseResult &  parsed,
size_t  offset 
)

◆ CallBuiltin() [1/2]

absl::StatusOr< Value > a11::flow::CallBuiltin ( std::string_view  name,
absl::Span< const Value >  arguments,
HostBridge *absl_nullable  bridge,
const PreparedExpressions *absl_nullable  prepared = nullptr 
)

Call one of the language's fixed functions.

Public because the strformat stage is the one-value shorthand for the builtin and must not become a second implementation of it.

◆ CallBuiltin() [2/2]

absl::StatusOr< Value > a11::flow::CallBuiltin ( std::string_view  name,
absl::Span< const Value >  arguments,
HostBridge *absl_nullable  bridge,
const PreparedExpressions *  prepared 
)

◆ CanonicalPayloadType()

std::string a11::flow::CanonicalPayloadType ( std::string_view  type)

Canonical payload spelling for alias and generic equality.

◆ CheckImplementation()

absl::Status a11::flow::CheckImplementation ( const FlowPlan &  actual,
const FlowPlan &  declared,
const Program &  program 
)

Validate the actual implementation against every declared obligation.

◆ CheckSingleItemStructure()

bool a11::flow::CheckSingleItemStructure ( const graph::FlowGraph &  flow)

Validate graph structure independently of transport candidate discovery.

◆ CodesToJsonValue()

nlohmann::json a11::flow::CodesToJsonValue ( )

The published code table, as flow.codes/v1.

◆ Coerce()

absl::StatusOr< Value > a11::flow::Coerce ( const Value &  value,
const syntax::TypeExpression &  type,
const CoerceContext &  context 
)

Make value a value of the type type names.

A built-in name coerces the way the matching builtin does; a shape the program declared is validated against, field by field; a tag or a mimetype goes to the host, which is the only place that knows what has been registered.

◆ CoerceShape()

absl::StatusOr< Value > a11::flow::CoerceShape ( const DtoPlan &  shape,
const Value &  value,
const CoerceContext &  context 
)

Make value a value of shape: fill its defaults, check its bounds, and coerce every field to the type the shape gives it.

The one implementation of what a shape means. The resolver checks what it can before anything runs – a key the shape does not have, a constant of the wrong kind – and this checks the rest, when a value actually arrives. A failure names the field it was about, by path (parent.tags[2]), because a flow's data comes from somewhere else and "invalid" without a path is a message nobody can act on.

A key the shape does not have is dropped, not refused: extra data is how {...it, ..} is useful, and a producer that sends more than a reader declared has done nothing wrong. Writing such a key out by hand is a different thing and the resolver says so.

◆ CompileStrformat()

FormatTemplate a11::flow::CompileStrformat ( std::string_view  text)

◆ CompleteAt() [1/2]

CompleteResult a11::flow::CompleteAt ( std::string_view  source,
size_t  offset,
const catalogue::Catalogue &  known,
CompilationLimits  limits,
CompilationBudget *  budget,
const LinkedModule *  linked 
)

◆ CompleteAt() [2/2]

CompleteResult a11::flow::CompleteAt ( std::string_view  source,
size_t  offset,
const catalogue::Catalogue &  known = catalogue::Catalogue::Builtin(),
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr,
const LinkedModule *absl_nullable  linked = nullptr 
)

Returns grammar and scope-aware proposals at offset in source.

Incomplete source produces narrower proposals. Source without a flow is treated as a flow body. known supplies available actions and types.

◆ CompletionsToJsonValue()

nlohmann::json a11::flow::CompletionsToJsonValue ( const CompleteResult &  result)

The flow.completions/v1 envelope: what may be written at an offset.

◆ ConstantToJsonValue()

nlohmann::json a11::flow::ConstantToJsonValue ( const syntax::Constant &  constant)

A constant as the syntax format writes it.

◆ ConstructRange()

Range a11::flow::ConstructRange ( const LineIndex &  lines,
absl::Span< const Token >  tokens,
const syntax::Location &  opened,
const Range &  selection 
)

◆ DeclarationSource()

absl::StatusOr< std::string > a11::flow::DeclarationSource ( const FlowPlan &  plan)

Emit a declaration without introducing an action-layer dependency.

◆ DeclareAction()

ActionDeclaration a11::flow::DeclareAction ( const actions::ActionSchema &  schema)

◆ Describe() [1/2]

Description a11::flow::Describe ( std::string_view  source,
size_t  offset,
const catalogue::Catalogue &  known,
CompilationLimits  limits,
CompilationBudget *  budget,
const LinkedModule *  linked 
)

◆ Describe() [2/2]

Description a11::flow::Describe ( std::string_view  source,
size_t  offset,
const catalogue::Catalogue &  known = catalogue::Catalogue::Builtin(),
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr,
const LinkedModule *absl_nullable  linked = nullptr 
)

What is at offset, and where it came from.

◆ DiagnosticFromJsonValue()

Diagnostic a11::flow::DiagnosticFromJsonValue ( const nlohmann::json &  value)

Reads a diagnostic, ignoring unknown fields and defaulting missing ones.

◆ DiagnosticsToJson()

std::string a11::flow::DiagnosticsToJson ( std::string_view  source,
absl::Span< const Diagnostic >  diagnostics 
)

The envelope, serialised with a trailing newline and two-space indent.

◆ DiagnosticsToJsonValue()

nlohmann::json a11::flow::DiagnosticsToJsonValue ( std::string_view  source,
absl::Span< const Diagnostic >  diagnostics 
)

The flow.diagnostics/v1 envelope, with source and severity counts.

◆ DiagnosticsToSarif()

std::string a11::flow::DiagnosticsToSarif ( std::string_view  source,
absl::Span< const Diagnostic >  diagnostics 
)

The SARIF log, serialised with a trailing newline.

◆ DiagnosticsToSarifValue()

nlohmann::json a11::flow::DiagnosticsToSarifValue ( std::string_view  source,
absl::Span< const Diagnostic >  diagnostics 
)

A SARIF 2.1.0 log for one file, with rule metadata from [KnownCodes].

◆ DiagnosticToJsonValue()

nlohmann::json a11::flow::DiagnosticToJsonValue ( const Diagnostic &  diagnostic)

One diagnostic, as it appears in the envelope.

◆ DiagnosticToText()

std::string a11::flow::DiagnosticToText ( std::string_view  source,
const Diagnostic &  diagnostic 
)

path:line:column: severity: message [code] on one line.

An empty source omits the path prefix.

◆ DtoToFlow()

std::string a11::flow::DtoToFlow ( const DtoPlan &  dto)

Renders one shape as formatted Flow source.

◆ DtoToJsonSchema()

nlohmann::json a11::flow::DtoToJsonSchema ( const DtoPlan &  dto,
const Program &  program 
)

Converts a Flow shape to JSON Schema Draft 2020-12.

Referenced shapes use $defs and $ref, including self-references. bytes, time, and duration use strings with x-a11-type metadata.

◆ DtoToJsonValue()

nlohmann::json a11::flow::DtoToJsonValue ( const DtoPlan &  dto,
const Program *absl_nullable  program = nullptr 
)

A resolved shape.

With program, referenced shapes appear under nested. A self-reference appears once, in struct.

◆ DurationSeconds()

double a11::flow::DurationSeconds ( absl::Duration  value)

A duration as a number of seconds, for every duration there is.

Infinite ones answer an infinity rather than failing: a timeout that never fires is a duration a flow can hold, and so is the negative one two instants subtracted the wrong way round give.

◆ DurationText()

std::string a11::flow::DurationText ( absl::Duration  value,
std::string_view  spec 
)

A duration as text: 1m30s by default, or one unit when spec names one.

◆ Evaluate()

absl::StatusOr< Value > a11::flow::Evaluate ( const syntax::Node &  node,
const EvalContext &  context 
)

Evaluate one expression.

Fails for unsupported operations such as an unknown type or adding two instants. Other invalid values use the language defaults: incompatible comparisons use text, a missing key is null, and an unreadable number is zero.

◆ ExactInt64()

std::optional< std::int64_t > a11::flow::ExactInt64 ( const Value &  value)

◆ FailureRecord()

Value a11::flow::FailureRecord ( const absl::Status &  status,
Value  item,
std::int64_t  seq 
)

A tolerated stage failure, with the original item and zero-based position.

◆ FamilyFromName()

Family a11::flow::FamilyFromName ( std::string_view  name)

Family for a name from the output formats, or kSyntax if unknown.

◆ FamilyName()

std::string_view a11::flow::FamilyName ( Family  family)

The spelling of a family in the output formats.

◆ FieldTypeNames()

std::vector< std::string_view > a11::flow::FieldTypeNames ( const FieldPlan &  field)

Every type named by a field, including nested container parameters.

◆ FileModuleIdentity()

std::string a11::flow::FileModuleIdentity ( std::string_view  reference)
inline

Lexical source identity; normalizing it performs no target-path inspection.

◆ FileModuleResolver()

ModuleResolver a11::flow::FileModuleResolver ( size_t  max_bytes = 8 * 1024 * 1024,
ModuleSources  overrides = {},
std::vector< std::string >  approved_roots = {} 
)
inline

Filesystem imports confined to explicitly approved roots without symlinks.

◆ FindCode()

const CodeInfo *absl_nullable a11::flow::FindCode ( std::string_view  code)

The entry for a code, or nullptr if nothing publishes it.

◆ FirstError()

const Diagnostic *absl_nullable a11::flow::FirstError ( absl::Span< const Diagnostic >  diagnostics)

The first error in diagnostics, or nullptr if none is an error.

What every strict entry point turns into its one raised failure, so that "the first thing wrong with this file" means the same in each of them.

◆ FlowMarkdown()

std::string a11::flow::FlowMarkdown ( const FlowPlan &  flow)

A flow of the document, written out the same way: what it does, then its ports and which direction each runs.

◆ FlowSchema() [1/2]

absl::StatusOr< actions::ActionSchema > a11::flow::FlowSchema ( const FlowPlan &  plan,
const Program *absl_nullable  shapes = nullptr 
)

The [actions::ActionSchema] a flow presents.

A flow is an action: it has ports, headers and a name, so anything that can dispatch an action can dispatch a composition without being told it is one.

◆ FlowSchema() [2/2]

absl::StatusOr< actions::ActionSchema > a11::flow::FlowSchema ( const FlowPlan &  plan,
const Program *  shapes 
)

◆ Format() [1/2]

FormatResult a11::flow::Format ( std::string_view  source,
FormatOptions  options,
CompilationLimits  limits,
CompilationBudget *  budget 
)

◆ Format() [2/2]

FormatResult a11::flow::Format ( std::string_view  source,
FormatOptions  options = {},
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr 
)

Formats Flow source with stable whitespace and equivalent syntax.

Parse errors leave the source unchanged and appear in diagnostics. Formatting is idempotent; comments and literal values are preserved.

◆ FormatToJsonValue()

nlohmann::json a11::flow::FormatToJsonValue ( const FormatResult &  result)

The flow.format/v1 envelope: the formatted text, and what it took.

◆ FragmentStartPattern()

std::string a11::flow::FragmentStartPattern ( )

Native document-start pattern used by host-string injectors.

◆ GenerateSyntax()

std::string a11::flow::GenerateSyntax ( SyntaxTarget  target)

Generates the target grammar from the Flow vocabulary.

Output is deterministic and ends with a newline.

◆ Handle()

nlohmann::json a11::flow::Handle ( const nlohmann::json &  request,
ModuleResolver  resolver = {},
CompilationLimits  limits = {} 
)

Handles one language service request and returns its JSON envelope.

Requests name a method and source; an optional id is echoed in the result. Invalid requests return ok: false; source problems return diagnostics. describe accepts snippet: true for a Flow body fragment.

◆ HeaderBytes()

std::string a11::flow::HeaderBytes ( const syntax::Constant &  v)

Encode a constant using the native action-header textual convention.

◆ Highlight()

std::vector< SemanticToken > a11::flow::Highlight ( absl::Span< const Token >  tokens)

Classify a token stream.

The rules are the ones the grammar itself uses, which is why this reads a stream rather than one token at a time: a word is only a stage directly after a |, only a function where it is called, only a type past a port's :, and whatever follows a . is a member however it is spelled. Two of them need a look ahead rather than behind – a bare then/where is a stage only with an operand after it, and node is the keyword only where its parentheses open – and having the whole stream is what makes those cheap and exact.

The tokens are expected to include comments (LexOptions::keep_comments), and each string token is split around its escape ranges. Other tokens keep one entry each, except the final end.

◆ Inspect()

std::vector< Diagnostic > a11::flow::Inspect ( std::string_view  source,
const ParseResult &  parsed,
const ResolveResult &  resolved 
)

Reports nonfatal Flow diagnostics from parsed and resolved source.

Findings include unused values, unwritten outputs, and ineffective stages.

◆ InvocationNote()

std::string a11::flow::InvocationNote ( std::string_view  mode)

◆ JsonSchemaToDtos()

SchemaImport a11::flow::JsonSchemaToDtos ( const nlohmann::json &  schema,
std::string_view  name 
)

Imports shapes from schema, using name when the root has no name.

Unsupported keywords produce diagnostics alongside imported fields.

◆ JsonText()

std::string a11::flow::JsonText ( const Value &  value)

Renders JSON with sorted keys, spaced separators, and escaped non-ASCII.

◆ KindFromName()

TokenKind a11::flow::KindFromName ( std::string_view  name)

The kind a name from [KindName] refers to, or kBad if it is not one.

◆ KindName()

std::string_view a11::flow::KindName ( TokenKind  kind)

The name of a kind, as a11.flow.lexer spells it.

Punctuation is named by itself ("->", "{"), which is what makes a token dump comparable between the two implementations token for token.

◆ KnownCodes()

absl::Span< const CodeInfo > a11::flow::KnownCodes ( )

Every diagnostic code the language can produce, sorted by code.

◆ Lex()

LexResult a11::flow::Lex ( std::string_view  source,
LexOptions  options = {} 
)

Lexes Flow source, ending with one end token.

Newlines delimit statements; malformed tokens produce diagnostics while lexing continues. Strict compilation checks the reported errors.

◆ LinkModules() [1/2]

LinkedModule a11::flow::LinkModules ( std::string  source,
std::string  identity,
const ModuleSources &  sources,
ModuleResolver  resolver,
ModuleLimits  limits,
CompilationBudget *  budget 
)

◆ LinkModules() [2/2]

LinkedModule a11::flow::LinkModules ( std::string  source,
std::string  identity,
const ModuleSources &  sources = {},
ModuleResolver  resolver = {},
ModuleLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr 
)

Link lexical imports and private dependencies using host-supplied sources.

◆ Lookup()

Value a11::flow::Lookup ( const Value &  value,
const Value &  key 
)

Take key out of value: a mapping key, an index, or a field.

Answers null when it is not there, because a flow reading a field a producer did not send should be able to say if not thing.field rather than fall over.

◆ LookupChecked()

absl::StatusOr< Value > a11::flow::LookupChecked ( const Value &  value,
const Value &  key 
)

◆ LookupOptional()

std::optional< Value > a11::flow::LookupOptional ( const Value &  value,
const Value &  key 
)

◆ MakeEntryHandler()

absl::StatusOr< actions::ActionHandler > a11::flow::MakeEntryHandler ( std::shared_ptr< const CompiledProgram >  program,
RunOptions  options = {} 
)

The action handler that runs the program's entry flow.

A separate function rather than MakeHandler(program, ""), because the entry flow is reached by being the entry flow and not by having an empty name – the same reason Program::Entry() exists. What an interpreter calls.

◆ MakeHandler()

absl::StatusOr< actions::ActionHandler > a11::flow::MakeHandler ( std::shared_ptr< const CompiledProgram >  program,
std::string_view  flow,
RunOptions  options = {} 
)

The action handler that runs one flow of program.

Registering this makes the composition an action like any other: a peer can dispatch it, another flow can call it, and a model can be offered it as a tool, without any of them knowing it is a composition.

◆ MarkBinaryTypes() [1/2]

void a11::flow::MarkBinaryTypes ( std::vector< DtoPlan > &  types,
CompilationBudget *absl_nullable  budget = nullptr 
)

Propagate byte payloads through the shape dependency graph.

◆ MarkBinaryTypes() [2/2]

void a11::flow::MarkBinaryTypes ( std::vector< DtoPlan > &  types,
CompilationBudget *  budget 
)

◆ MatchCompiled()

Value a11::flow::MatchCompiled ( const pattern::Pattern &  pattern,
std::string_view  subject 
)

The same, against a pattern already compiled.

What a stage uses: the pattern is written once in the source and the stream may be ten thousand values, so compiling it per value would be paying for the same scan over and over.

◆ MatchPattern()

absl::StatusOr< Value > a11::flow::MatchPattern ( std::string_view  pattern,
std::string_view  subject 
)

The fields a pattern pulls out of subject, or null where it does not fit.

One implementation for both senses of match: the stage drops a value this answers null for, and the function hands the null on. A record when every hole is named, and a list when they are not – {} is read by position, so it[0] is what a positional pattern gives.

See [pattern::Compile] for the language. A pattern that does not compile is an invalid_argument naming what is wrong with it, because a pattern is a literal almost every time and a silent no-match would hide a typo in it.

◆ MergeContract()

absl::Status a11::flow::MergeContract ( FlowPlan &  effective,
const FlowPlan &  other,
const Program &  program 
)

Conjoin compatible interfaces without changing executable identity.

◆ Methods()

absl::Span< const std::string_view > a11::flow::Methods ( )

Every method [Handle] knows, in the order --help lists them.

◆ MethodSummary()

std::string_view a11::flow::MethodSummary ( std::string_view  method)

What a method takes and gives back, one line, for --help.

◆ NativeHostBridge()

std::unique_ptr< HostBridge > a11::flow::NativeHostBridge ( )

A host bridge backed by the C++ serialization registry.

◆ NodeToJsonValue()

nlohmann::json a11::flow::NodeToJsonValue ( const syntax::Node &  node)

A syntax node and its subtree.

Every node carries kind and at. Durations use {"$duration": seconds}.

◆ OffsetBasisFromName()

bool a11::flow::OffsetBasisFromName ( std::string_view  name,
OffsetBasis &  basis 
)

The basis a request named, or kBytes when it named none.

false when the name is not one of the two, so a client with a typo is told rather than quietly served the wrong arithmetic.

◆ OffsetBasisName()

std::string_view a11::flow::OffsetBasisName ( OffsetBasis  basis)

The name of a basis, for a message and for the JSON.

◆ operator==()

bool a11::flow::operator== ( const Value &  left,
const Value &  right 
)

◆ Order()

int a11::flow::Order ( const Value &  left,
const Value &  right 
)

Where two values sit relative to one another: -1, 0 or 1.

What < and > mean in an expression, and so what | sort means: two instants or two durations compare as themselves, a number as a number, and everything else as text, so nothing dies on "3" < 5.

◆ Parse() [1/2]

ParseResult a11::flow::Parse ( std::string_view  source,
CompilationLimits  limits,
CompilationBudget *  budget 
)

◆ Parse() [2/2]

ParseResult a11::flow::Parse ( std::string_view  source,
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr 
)

Parses Flow source into a recoverable tree and diagnostics.

Recovery skips to statement ends or inserts syntax::ErrorNode for values.

◆ ParseDuration()

std::optional< absl::Duration > a11::flow::ParseDuration ( std::string_view  text)

Parse duration text, including compound units and bare seconds.

◆ ParseTime()

std::optional< absl::Time > a11::flow::ParseTime ( std::string_view  text)

Parse an instant as RFC 3339 text or a UTC calendar date.

◆ ParseTokens() [1/2]

ParseResult a11::flow::ParseTokens ( std::string_view  source,
absl::Span< const Token >  tokens,
std::vector< Diagnostic >  diagnostics,
CompilationLimits  limits,
CompilationBudget *  budget 
)

◆ ParseTokens() [2/2]

ParseResult a11::flow::ParseTokens ( std::string_view  source,
absl::Span< const Token >  tokens,
std::vector< Diagnostic >  diagnostics,
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr 
)

Parse an already-lexed stream, sharing the lex diagnostics.

For a frontend that has the tokens in hand – a formatter, a highlighter that then wants a tree – so one file is lexed once. Comment tokens are stepped over here, which is what lets the same stream serve both.

◆ ParseTypeExpression() [1/2]

absl::StatusOr< syntax::TypeExpression > a11::flow::ParseTypeExpression ( std::string_view  source,
CompilationLimits  limits,
CompilationBudget *  budget 
)

◆ ParseTypeExpression() [2/2]

absl::StatusOr< syntax::TypeExpression > a11::flow::ParseTypeExpression ( std::string_view  source,
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr 
)

Parse a standalone type with the same grammar and limits as a declaration.

◆ PlanToJson()

std::string a11::flow::PlanToJson ( std::string_view  source_name,
const Program &  program 
)

The envelope, serialised with a trailing newline and two-space indent.

◆ PlanToJsonValue()

nlohmann::json a11::flow::PlanToJsonValue ( std::string_view  source_name,
const Program &  program 
)

The flow.plan/v1 envelope for resolved flows.

◆ PortMarkdown()

std::string a11::flow::PortMarkdown ( std::string_view  name,
std::string_view  type,
bool  required,
bool  unary,
std::string_view  description 
)

One port, written out as the Markdown a reader wants beside its name.

Used by hover and completion to show the same full port description.

◆ ProposalKindName()

std::string_view a11::flow::ProposalKindName ( ProposalKind  kind)

The name of a proposal kind in the output format, in kebab case.

◆ RebaseToUtf16() [1/2]

void a11::flow::RebaseToUtf16 ( nlohmann::json &  answer,
const TextIndex &  index 
)

Rewrite every document offset in an answer from bytes into UTF-16 units.

The rule, and it is the whole rule: a numeric field named start, end, offset or prefix_start is a byte offset into the document, at any depth. That is true of every flow.* envelope by construction – those four names are not used for anything else in any of them – so this converts exactly the right set and needs no table of shapes to fall out of step with the emitters.

Two near matches are left unchanged. range.start and range.end are objects, and the offset inside each is the offset field this does convert. A proposal's caret counts into the text that proposal inserts, not into the document, so a document-basis conversion of it would be wrong.

◆ RebaseToUtf16() [2/2]

void a11::flow::RebaseToUtf16 ( nlohmann::json &  answer,
const TextIndex &  inherited,
const absl::flat_hash_map< std::string, TextIndex > &  documents 
)

Rebase each document with its own pinned source index.

◆ RefinePorts()

void a11::flow::RefinePorts ( std::string_view  source,
std::vector< SemanticToken > &  semantic 
)

Refine lexical tokens using parsed type positions and resolved bindings.

Ports include declarations, references, argument labels and called ports. Resolved locals retain identifier styling when shadowing a port or keyword. Parsing recovers from incomplete source, without reading imported files.

◆ RefinesType()

Refinement a11::flow::RefinesType ( std::string_view  actual,
std::string_view  expected,
const Program &  program 
)

Compare payload types using native aliases and document shapes.

◆ Resolve() [1/2]

ResolveResult a11::flow::Resolve ( std::string_view  source,
const ParseResult &  parsed,
bool  build_graph,
const Program *  context,
CompilationLimits  limits,
CompilationBudget *  budget 
)

◆ Resolve() [2/2]

ResolveResult a11::flow::Resolve ( std::string_view  source,
const ParseResult &  parsed,
bool  build_graph = false,
const Program *absl_nullable  context = nullptr,
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr 
)

Resolves names, ports, scopes, node maps, and types in a parsed program.

Returns partial results and diagnostics for invalid source. build_graph adds executable graphs that borrow from parsed.

◆ SecondsDuration()

absl::Duration a11::flow::SecondsDuration ( double  total)

A duration of total seconds, including negative and infinite values.

◆ SelectPipelinePorts()

absl::StatusOr< PipelinePorts > a11::flow::SelectPipelinePorts ( const FlowPlan &  flow,
absl::Span< const std::string >  supplied 
)

◆ SelectPipelineStarterOutput()

absl::StatusOr< const PortPlan * > a11::flow::SelectPipelineStarterOutput ( const FlowPlan &  flow,
absl::Span< const std::string >  supplied 
)

The unique output of a call with every input supplied explicitly.

◆ SemanticKindFromName()

SemanticKind a11::flow::SemanticKindFromName ( std::string_view  name)

The kind a name refers to, or kIdentifier if it is not one.

◆ SemanticKindName()

std::string_view a11::flow::SemanticKindName ( SemanticKind  kind)

The name of a semantic kind in the output formats, in kebab case.

◆ SeverityFromName()

Severity a11::flow::SeverityFromName ( std::string_view  name)

Severity for a name from the output formats, or kError if unknown.

◆ SeverityName()

std::string_view a11::flow::SeverityName ( Severity  severity)

The spelling of a severity in the output formats.

◆ ShapeMarkdown()

std::string a11::flow::ShapeMarkdown ( const DtoPlan &  shape)

A struct, written out the same way: how many fields, then each of them.

◆ SingleItemsToJson()

nlohmann::json a11::flow::SingleItemsToJson ( const graph::FlowGraph &  flow,
const SingleItemAnalysis &  analysis,
bool  enabled 
)

Explain transport decisions without changing the public source plan.

◆ SortDiagnostics()

void a11::flow::SortDiagnostics ( std::vector< Diagnostic > &  diagnostics)

Sorts diagnostics into the order every frontend presents them in: by position, then by code, so two runs over the same file agree byte for byte.

◆ StageMarkdown()

std::string a11::flow::StageMarkdown ( std::string_view  name)

A pipeline stage, written out as reference.

Uses the stage role when a word also has a built-in function meaning.

◆ StatusCodeOf()

std::optional< absl::StatusCode > a11::flow::StatusCodeOf ( const Value &  value)

The canonical code value names, by name or by number, or nullopt.

Either case of a canonical name, and any number Abseil defines a code for, which is what lets a flow re-raise a status it was handed without knowing how it was spelled.

◆ StatusOfRecord()

absl::Status a11::flow::StatusOfRecord ( const Value &  record)

The status a record like the one above describes.

◆ StatusRecord()

Value a11::flow::StatusRecord ( const absl::Status &  status)

A status as the record a flow sees when it looks at an outcome.

{"ok": .., "code": "NOT_FOUND", "number": 5, "message": ..} – data, so a flow can branch on it, put it on an output, or raise it again, without any of the language knowing what a status is.

◆ Strformat()

std::string a11::flow::Strformat ( const Value &  format,
absl::Span< const Value >  arguments 
)

format with each % conversion replaced by one of arguments.

printf's syntax, because a format string is a thing people already know how to read, and because it is only a format string: no attribute access, no indexing, nothing a template can reach through. A flow's templates can come from a model, so that matters more here than the convenience of a richer template language would.

%(SPEC)s applies a spec to the value first – a duration unit, a strftime pattern, epoch – and a conversion with no value behind it is left as it was written, because a visible %3$s in the output is easier to diagnose than a flow that died formatting a log line.

◆ StrformatCompiled()

std::string a11::flow::StrformatCompiled ( const FormatTemplate &  parts,
absl::Span< const Value >  arguments 
)

◆ SymbolClassName()

std::string_view a11::flow::SymbolClassName ( SymbolClass  kind)

◆ SymbolKindName()

std::string_view a11::flow::SymbolKindName ( SymbolKind  kind)

The name of a symbol kind, for a message and for the JSON.

◆ Symbols() [1/2]

std::vector< DocumentSymbol > a11::flow::Symbols ( std::string_view  source,
CompilationLimits  limits,
CompilationBudget *  budget 
)

◆ Symbols() [2/2]

std::vector< DocumentSymbol > a11::flow::Symbols ( std::string_view  source,
CompilationLimits  limits = {},
CompilationBudget *absl_nullable  budget = nullptr 
)

Every symbol a document declares, nested as it is written.

Top-level flows and shapes contain their ports, fields, and local bindings.

◆ SyntaxTargetFromName()

bool a11::flow::SyntaxTargetFromName ( std::string_view  name,
SyntaxTarget &  target 
)

A target from its name, or nullopt.

◆ SyntaxTargetName()

std::string_view a11::flow::SyntaxTargetName ( SyntaxTarget  target)

The name a target is asked for by: sublime.

◆ SyntaxTargetPath()

std::string_view a11::flow::SyntaxTargetPath ( SyntaxTarget  target)

Where the generated file belongs, relative to the repository root.

◆ SyntaxTargets()

absl::Span< const SyntaxTarget > a11::flow::SyntaxTargets ( )

Every target, for a command that offers a choice of them.

◆ SyntaxToJson()

std::string a11::flow::SyntaxToJson ( std::string_view  source,
const ParseResult &  result 
)

The envelope, serialised with a trailing newline and two-space indent.

◆ SyntaxToJsonValue()

nlohmann::json a11::flow::SyntaxToJsonValue ( std::string_view  source,
const ParseResult &  result 
)

The flow.syntax/v1 envelope, including partial trees and diagnostics.

◆ TimeText()

std::string a11::flow::TimeText ( absl::Time  value,
std::string_view  spec 
)

An instant as text: RFC 3339 in UTC, a strftime pattern, or epoch.

◆ TokensToJson()

std::string a11::flow::TokensToJson ( std::string_view  source_name,
std::string_view  source 
)

The envelope, serialised with a trailing newline and two-space indent.

◆ TokensToJsonValue()

nlohmann::json a11::flow::TokensToJsonValue ( std::string_view  source_name,
std::string_view  source 
)

The flow.tokens/v1 envelope, with token kinds and semantic classes.

Token offsets cover the source; unclassified spans are whitespace.

◆ Truncate()

Value a11::flow::Truncate ( const Value &  value,
std::int64_t  size 
)

The first size of a value: characters, bytes, elements or pairs.

◆ Truthy()

bool a11::flow::Truthy ( const Value &  value)

Whether value counts as true, as an if and a where decide it.

◆ VocabularyToJsonValue()

nlohmann::json a11::flow::VocabularyToJsonValue ( )

The language word sets as flow.vocabulary/v1.

◆ Widened()

Range a11::flow::Widened ( const LineIndex &  lines,
const Range &  range,
const Range &  selection 
)

Expands a symbol range to include its selection.

◆ WordMarkdown()

std::string a11::flow::WordMarkdown ( std::string_view  name,
vocabulary::WordRole  role 
)

One word or mark of the language, written out as reference: what it does, what it takes, how it behaves, and a line of Flow using it.

Empty where nothing documents the name. role says which position the name was read in, since a word can mean two things; where that role's table has no entry the other tables are asked, because a word set may list a word that a neighbouring set documents (vocabulary::AnyDocumentation).

The name may be written in either case, as the language allows: TRUNCATE is documented and shown as written.

Variable Documentation

◆ kCodesFormat

constexpr std::string_view a11::flow::kCodesFormat = "flow.codes/v1"
inlineconstexpr

◆ kCompletionsFormat

constexpr std::string_view a11::flow::kCompletionsFormat = "flow.completions/v1"
inlineconstexpr

The format field of the completions envelope.

◆ kDefinitionFormat

constexpr std::string_view a11::flow::kDefinitionFormat = "flow.definition/v1"
inlineconstexpr

The format field of the definition envelope.

◆ kDiagnosticsFormat

constexpr std::string_view a11::flow::kDiagnosticsFormat = "flow.diagnostics/v1"
inlineconstexpr

Envelope format identifiers. Readers ignore unknown fields in a version.

◆ kFlowOrderKey

constexpr std::string_view a11::flow::kFlowOrderKey = "x-a11-order"
inlineconstexpr

Extension key preserving a shape's field declaration order.

◆ kFlowTypeKey

constexpr std::string_view a11::flow::kFlowTypeKey = "x-a11-type"
inlineconstexpr

The extension key that says which Flow type a string really is.

◆ kFormatFormat

constexpr std::string_view a11::flow::kFormatFormat = "flow.format/v1"
inlineconstexpr

◆ kHoverFormat

constexpr std::string_view a11::flow::kHoverFormat = "flow.hover/v1"
inlineconstexpr

The format field of the hover envelope.

◆ kPlanFormat

constexpr std::string_view a11::flow::kPlanFormat = "flow.plan/v1"
inlineconstexpr

The format field of the plan envelope.

◆ kQueueDepth

constexpr size_t a11::flow::kQueueDepth = 8
inlineconstexpr

Maximum values a pipe may hold ahead of its reader.

◆ kSchemaFormat

constexpr std::string_view a11::flow::kSchemaFormat = "flow.schema/v1"
inlineconstexpr

The format field of the schema envelope.

◆ kSymbolsFormat

constexpr std::string_view a11::flow::kSymbolsFormat = "flow.symbols/v1"
inlineconstexpr

The format field of the symbols envelope.

◆ kSyntaxFormat

constexpr std::string_view a11::flow::kSyntaxFormat = "flow.syntax/v1"
inlineconstexpr

◆ kTokensFormat

constexpr std::string_view a11::flow::kTokensFormat = "flow.tokens/v1"
inlineconstexpr

◆ kVocabularyFormat

constexpr std::string_view a11::flow::kVocabularyFormat = "flow.vocabulary/v1"
inlineconstexpr