skillnet
skillnet is a CLI for reconciling local AI skill directories into a checked-in mirror, editing mirrored skills, syncing selected mirror state back to live agent directories, and recording calibration data for multi-phase-plan.
The supported interface in 0.2.0 is the skillnet binary. This crate does not commit to a stable embeddable Rust API yet.
Install
For a source checkout:
Nix Home Manager
Add the flake input and import the module:
inputs.skillnet.url = "git+ssh://git@codeberg.org/caniko/skillnet.git";
# In your Home Manager config:
imports = [ inputs.skillnet.hmModules.default ];
programs.skillnet = {
enable = true;
settings = {
mirror_root = "/home/alice/skills-mirror";
scopes = [
{
name = "global";
sources = [ "/home/alice/.claude/skills" ];
}
];
};
database = {
backend = "postgres";
urlFile = config.age.secrets.skillnet-pg-url.path;
};
};
The module is exported as both hmModules.default and hmModules.skillnet.
It installs skillnet on PATH. When settings is declared, the module
renders skillnet.toml and exports SKILLNET_CONFIG, SKILLNET_CATALOG_CONFIG,
and SKILLNET_MIRROR_ROOT for the CLI. Without settings, you can still drop
your own TOMLs and point programs.skillnet.configFile at them. When SQLite is
selected, the module also creates the runtime data directory and exports
skillnet_DATA_DIR and SKILLNET_DATA_DIR.
If you also want the module to define where the ai-skills checkout lives,
set skillsRoot. On atlas, that path is:
programs.skillnet.skillsRoot = "/data/nvme0/can/Projects/ai-skills";
When configured, the module exports AI_SKILLS_REPO and warns if the checkout
directory is missing. skillsRoot points at the skills checkout;
dataDir remains skillnet's runtime database and cache location.
Postgres is the default calibration backend and requires a connection URL. SQLite is also supported by selecting it explicitly:
programs.skillnet = {
enable = true;
package = inputs.skillnet.packages.${pkgs.system}.skillnet;
database = {
backend = "sqlite";
};
};
The Postgres backend is included in default builds. If you override
programs.skillnet.package with a custom --no-default-features build, choose
a package that includes the postgres feature when using the Postgres backend.
The database.url value is written into the Nix store. For production secrets,
prefer database.urlFile, which reads the Postgres URL from a file at shell
initialization time.
Options:
programs.skillnet.dataDirdefaults to${config.xdg.dataHome}/skillnet. This is skillnet's runtime database and cache location.programs.skillnet.skillsRootoptionally sets theai-skillscheckout root and exports it asAI_SKILLS_REPO; atlas uses/data/nvme0/can/Projects/ai-skills.programs.skillnet.database.backendselectssqliteorpostgresand defaults topostgres.programs.skillnet.database.pathoptionally sets the SQLite database path; when unset, calibration data lives at<dataDir>/multi-phase-plan/calibration.sqlite.programs.skillnet.database.urlsetsSKILLNET_DATABASE_URLand is required whenprograms.skillnet.database.backend = "postgres"andurlFileis unset.programs.skillnet.database.urlFilereads a Postgres URL from a file at shell initialization time.programs.skillnet.settingsandprograms.skillnet.catalogSettingsrenderskillnet.tomlandskillnet.catalog.tomlfrom Nix.programs.skillnet.configFileandprograms.skillnet.catalogConfigFilepoint the CLI at user-managed TOML files.programs.skillnet.packageoverrides the package. Ifpkgs.skillnetis not available in your package set, useinputs.skillnet.packages.${pkgs.system}.skillnet.
Storage backends
Postgres is the default calibration backend:
[]
= "postgres://skillnet@localhost/skillnet"
SQLite is available by selecting it explicitly:
[]
= "sqlite"
= "/home/alice/.local/share/skillnet/multi-phase-plan/calibration.sqlite"
The path key is optional. Without it, skillnet uses
$skillnet_DATA_DIR/multi-phase-plan/calibration.sqlite,
$SKILLNET_DATA_DIR/multi-phase-plan/calibration.sqlite, or
$XDG_DATA_HOME/skillnet/multi-phase-plan/calibration.sqlite.
Select Postgres with an environment variable:
Or with skillnet.toml:
[]
= "postgres://skillnet@localhost/skillnet"
Or through the Home Manager module:
programs.skillnet = {
enable = true;
package = inputs.skillnet.packages.${pkgs.system}.skillnet;
database = {
backend = "postgres";
urlFile = config.age.secrets.skillnet-pg-url.path;
};
};
--database-url <URL> overrides both environment and config for one command.
Plain URLs in programs.skillnet.database.url are written into the Nix store;
use programs.skillnet.database.urlFile with sops-nix, agenix, or another
secret-backed file for production credentials.
Quick Start
Inspect the configured scopes and current divergence:
Pull live skills into the mirror and then inspect or regenerate catalog output:
Calibration commands are available under the dedicated command group:
Development
Run the default test suite with:
Postgres parity tests run when SKILLNET_TEST_PG_URL points at a test database:
Configuration Model
skillnet keeps the mirror separate from live agent directories:
global/stores the reconciled global skill mirror.projects/<name>/stores reconciled per-project mirrors.- Live global sources typically come from
~/.agents/skills,~/.claude/skills, and~/.codex/skills. - Project scopes can add
.agents/skills,.claude/skills,.codex/skills, rootskills, plugin skill directories, and other configured paths.
Configuration lives in skillnet.toml. Catalog metadata lives in skillnet.catalog.toml.
Command Surface
The current top-level commands are:
statuscompletionssyncskillscopeprojectcatalogcalibration
Generate shell completions with:
Documentation
- Docs: https://docs.rs/skillnet
- Source: https://codeberg.org/caniko/skillnet
Release Validation
The release-prep flow validates the repository with:
RUSTDOCFLAGS="-D warnings"
License
Licensed under either of:
- MIT (LICENSE-MIT)
- Apache-2.0 (LICENSE-APACHE)