cove v0.1.0 - Contextual stepping for kont suspensions #3
hayabusa-cloud
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Introduction
coveis the context layer of the nonblocking I/O stack. Around akontcomputation that is advanced one suspension at a time,covekeeps ambient state — dispatch budget, ring capabilities, protocol phase, buffer-group validity, and similar runtime facts — as typed, composable data instead of hidden globals or ad-hoc side maps.takt,iox, anduring.covepackage:Viewas the ambient carrier,SuspensionViewas the contextual observation boundary overkont.Suspension,Cmdfor contextual commands,Req/ReqExprfor context predicates in closure and data form,Rule/RuleExprplusReportfor named diagnostics, and requirement-gated value carriersCheckedandGuarded.Usage
Highlights
coveships an explicit context algebra forkontsuspensions without becoming a runtime. The surface covers contextual stepping, contextual commands, composable requirements (closure and data forms), named rule diagnostics with reports, requirement- and rule-gated value carriers, and bridge helpers between the closure and expression worlds.Features
Public Surface
View[C, A]withObserve,Extract,Ask,Map,MapContext,Replace,WithContext,Duplicate, andExtend.Cmd[C, A, B]withRun,ExtractCmd,LiftCmd, andComposefor command composition throughExtend.SuspensionView[C, A],ObserveSuspension,StepWith,StepExprWith,Step,StepExpr,Op,Resume,ResumeWith, andDiscardfor steppingkontcomputations under ambient context;MapContextSuspensionandWithContextSuspensionfor explicit context transport on already-observed suspensions.Req[C]withNeed,Pullback,All,Any,Not,True,False;ReqExpr[C]withNeedExpr,ExprAtom,ExprPullback,ExprAll,ExprAny,ExprNot,ExprTrue,ExprFalseas a defunctionalized Boolean algebra over predicates.Rule[C],RuleExpr[C],Report,RuleError,Require,RequireExpr,PullbackRule,CheckRule,CheckRules,CheckRuleExpr, andCheckRulesExprfor named, ordered diagnostic checks.Checked[C, A],CheckedExpr[C, A],Guarded[C, A], andGuardedExpr[C, A]as requirement-gated and rule-gated value carriers, withGuard,GuardExpr,GuardRule,GuardRuleExpr,IntoView,MustView,MapChecked,MapGuarded,PullbackChecked, andPullbackGuarded.Reify,Reflect,ReifyReq, andReflectReqbetween the closure and expression worlds.CheckSuspensionandCheckSuspensionExprgate contextualization of a rawkont.Suspensionon a requirement.Behavioural contracts
SuspensionViewis affine: each suspension is consumed exactly once viaResume,ResumeWith, orDiscard.sv.Suspensionbecomesnilwhilesv.Ask()still returns the ambient context.coveperforms no scheduling, retry, or outcome classification; semantic outcome branching belongs toiox, kernel mechanics belong touring, and proactor advancement belongs totakt.Laws
Duplicate(v).Extract() == vExtend(v, func(w View[C, A]) A { return w.Extract() }) == vCompose(g, f)(v) == g(Extend(v, f))Compose(ExtractCmd, f) == fandCompose(g, ExtractCmd) == gCompatibility
1.26+This discussion was created from the release cove v0.1.0 - Contextual stepping for kont suspensions.
All reactions