Profile Enum Unification
Profile Enum Unification
Section titled “Profile Enum Unification”Janus 2026.6.2+ (branch feature/grok/priority-sprint) unifies the profile
system across layers that previously disagreed on enum variants, alias resolution,
and feature gates.
What changed
Section titled “What changed”Canonical six-profile ladder
Section titled “Canonical six-profile ladder”:script ⊆ :core ⊆ :service ⊆ :cluster ⊆ :compute ⊆ :sovereignAll compiler subsystems now resolve to this ladder. There is no separate :npu
or :full enum — those spellings are aliases that map to :compute and
:sovereign respectively.
Bug fix: :script → :sovereign mapping
Section titled “Bug fix: :script → :sovereign mapping”parseProfileNameToSemantic previously mapped :script to .sovereign. That
was wrong: :script is the bottom exploratory tier, not the top capability tier.
Script modules now resolve to .script through semantic analysis, the effect
graph, and the pipeline.
Rank-based feature gating
Section titled “Rank-based feature gating”Feature.availableInProfile in src/profiles.zig uses profile rank instead
of ad-hoc per-layer switches:
| Minimum profile | Features unlocked |
|---|---|
:script | Basic types, functions, control flow |
:service | Structured concurrency, channels, contexts, error handling |
:cluster | Actors |
:sovereign | Effects, capabilities, comptime magic, multiple dispatch |
Actors require :cluster, not :sovereign.
LSP alignment
Section titled “LSP alignment”- Default LSP profile is
:sovereign(was:full). - Keyword availability follows the same rank ladder as the CLI.
- Daemon LSP exposes all six canonical profiles.
Stable aliases
Section titled “Stable aliases”Old spellings keep working. Examples:
janus --profile=main build app.jan # → :corejanus --profile=go build server.jan # → :servicejanus --profile=npu build kernel.jan # → :computejanus --profile=full build driver.jan # → :sovereignSource annotations follow the same alias table:
{.profile :main.} // :core{.profile :async.} // :service{.profile :actor.} // :cluster{.profile :tensor.} // :compute{.profile :unsafe.} // :sovereignMigration notes
Section titled “Migration notes”- If diagnostics suddenly mention
:clusterfor actor code that compiled under a looser gate, escalate the module profile or use a function-level override. - Replace
:fullin LSP configs with:sovereign(alias still accepted). - Replace
:npuwith:computein new code (alias still accepted).