use super::*;
const RELEASE_DENY: &[&str] = &[
"atlas",
"credit",
"diff",
"foundry",
"hub",
"proposals",
"publication",
"reproduce-external",
];
#[cfg(test)]
pub(crate) const HIDDEN_FROM_ADVANCED_HELP: &[&str] = &[
"atlas",
"completions",
"credit",
"diff",
"foundry",
"hub",
"proposals",
"publication",
"reproduce-external",
];
fn released_command_names() -> &'static std::collections::HashSet<String> {
use std::sync::OnceLock;
static NAMES: OnceLock<std::collections::HashSet<String>> = OnceLock::new();
NAMES.get_or_init(|| {
use clap::CommandFactory;
let mut set = std::collections::HashSet::new();
for c in Cli::command().get_subcommands() {
set.insert(c.get_name().to_string());
for a in c.get_all_aliases() {
set.insert(a.to_string());
}
}
set
})
}
pub fn is_science_subcommand(name: &str) -> bool {
if RELEASE_DENY.contains(&name) {
return false;
}
released_command_names().contains(name)
}
pub(crate) fn print_strict_help() {
print!("{}", strict_help_text());
}
pub(crate) fn strict_help_text() -> String {
let retired_line = RELEASE_DENY.join(", ");
format!(
r#"Vela {}
Version control for scientific state.
Agents land. Verifiers reproduce. Humans approve. Git publishes.
Usage:
vela <COMMAND>
Daily product:
init Create a minimal Git-native frontier
status Compact frontier identity, roots, counts, and next action
next Ranked producer work only
work Claim one target and open a private typed session
land Land Receipt v1; policy admits, defers, or denies
review Inspect, decide, or producer-withdraw one exact proposal
check Replay, signatures, parity, and strict signals
reproduce Re-run stored witnesses with frozen verifiers
verify Retain non-authorizing proposal-scoped verifier evidence
log Recent signed events or one finding's history
doctor Blockers plus one safe next action
migrate Preview or apply a root-preserving repository migration
Nouns and setup:
finding record, standing, evidence, and attribution views
artifact content-addressed evidence lifecycle
frontier materialize, compare, recover publication, release, audit
policy standing authority rules and their human ceremonies
actor governed frontier identities
id local identity and key custody setup
agents regenerate agent adapters from VELA.md
config closed local/frontier configuration
Advanced verification and integration:
gate claim-level verification projections
proof proof packet export, verify, and explain
ci deterministic CI verdicts
serve read-only or nonfinalizing draft MCP/HTTP surface
sign historical batch and detached-file signing compatibility
Advanced setup:
target-index inspect, diagnose, or seal derived producer targets
Hidden utility:
completions generate shell completion scripts
Retired from the core product: {}
"#,
env!("CARGO_PKG_VERSION"),
retired_line,
)
}