@reddb-io/red-skills 2.73.1 → 2.74.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/brain.bundle.min.mjs +57 -43
- package/dist/code-nav.bundle.min.mjs +1 -1
- package/dist/dev.bundle.min.mjs +145 -145
- package/dist/memory.bundle.min.mjs +1 -1
- package/dist/rsp.bundle.min.mjs +98 -98
- package/package.json +1 -1
|
@@ -6578,7 +6578,7 @@ Usage:
|
|
|
6578
6578
|
${n} archive --candidate <json> [--root <dir>] [--archive-dir <rel>]
|
|
6579
6579
|
${n} restore <name> [--root <dir>] [--archive-dir <rel>]`}function Ex(n){return LYn(typeof n.root=="string"?n.root:process.cwd())}function Gdt(n){return typeof n["archive-dir"]=="string"?n["archive-dir"]:void 0}async function Jj(n){let a=await Jo(n);return a?a.mode!=="graph"?{ok:!1,message:`curate: skill telemetry needs graph mode (this project is "${a.mode}") \u2014 run \`${eHe}\``}:GZ(a)?{ok:!0}:{ok:!1,message:`curate: skill telemetry is not enabled here \u2014 run \`${eHe}\``}:{ok:!1,message:`curate: memory is not initialized here \u2014 run \`${eHe}\``}}function zYn(){let n=AYn(xYn(import.meta.url));return n.includes("dist/curate-skill")||n.endsWith("dist/curate-skill")?odt(n,"..","cli.js"):odt(n,"..","cli.ts")}async function OYn(n,a){let i=["curate","skills","--json"];a!==void 0&&i.push("--stale-days",String(a));let d=zYn(),h=d.endsWith(".ts")?sdt(process.execPath,["--import","tsx",d,...i,"--root",n],{encoding:"utf8"}):sdt(process.execPath,[d,...i,"--root",n],{encoding:"utf8"}),g=h.status??1;if(g!==0)throw new Error(`memory curate skills exited ${g}`);return cdt(h.stdout??"")}function UYn(n){return typeof n.flags["stale-days"]=="string"?Number(n.flags["stale-days"]):void 0}async function mdt(n,a){return(a.loadCuratorReport??OYn)(Ex(n.flags),UYn(n))}async function MYn(n){let a=Ex(n.flags),i=await Jj(a);return i.ok?(console.log("curate: skill telemetry is enabled \u2014 ready to curate"),0):(console.error(i.message),2)}async function BYn(n,a){let i=Ex(n.flags),d=await Jj(i);if(!d.ok)return console.error(d.message),2;let u;try{u=await mdt(n,a)}catch(J){return console.error(`curate: ${J.message}`),1}let{candidates:h,byCategory:g,filtered:f}=qwe(u);return console.log(JSON.stringify({candidates:h,byCategory:g,filtered:f,totals:{totalSkills:u.totalSkills,curatableSkills:u.curatableSkills,readOnlySkills:u.readOnlySkills}},null,2)),0}async function SYn(n,a){let i=Ex(n.flags),d=await Jj(i);if(!d.ok)return console.error(d.message),2;let u;try{u=await mdt(n,a)}catch(J){return console.error(`curate: ${J.message}`),1}let{byCategory:h}=qwe(u);if($we(h)===0)return console.error("curate: no candidates \u2014 no issue filed"),0;let g=typeof n.flags.label=="string"?n.flags.label:void 0,f=await idt({byCategory:h,totals:{totalSkills:u.totalSkills,curatableSkills:u.curatableSkills,readOnlySkills:u.readOnlySkills},generatedAt:u.generatedAt},{cwd:i,label:g});return console.log(`curate: filed background issue \u2014 ${f.output||f.title}`),0}async function TYn(n){let a=Ex(n.flags),i=await Jj(a);if(!i.ok)return console.error(i.message),2;let d=n.flags.candidate;if(typeof d!="string")return console.error("curate archive: --candidate <json> is required"),2;let u;try{u=JSON.parse(d)}catch(g){return console.error(`curate archive: invalid --candidate JSON: ${g.message}`),2}let h=await ldt(u,{rootDir:a,archiveDir:Gdt(n.flags)});return h.ok?(console.log(`curate: archived "${h.receipt.name}" \u2192 ${h.receipt.archiveRoot} (${h.receipt.files.length} file(s), manifest at ${h.receipt.manifestPath})`),0):(console.error(`curate archive: refused \u2014 ${h.rejection.reason}: ${h.rejection.detail}`),3)}async function jYn(n){let a=Ex(n.flags),i=await Jj(a);if(!i.ok)return console.error(i.message),2;let d=n.positional[0];if(!d)return console.error("curate restore: skill name is required"),2;let u=await adt(d,{rootDir:a,archiveDir:Gdt(n.flags)});return console.log(`curate: restored "${u.name}" \u2192 ${u.restoredRoot} (${u.files.length} file(s) hash-verified)`),0}async function udt(n,a={}){switch(n.command){case"check":return MYn(n);case"list":return BYn(n,a);case"background":return SYn(n,a);case"archive":return TYn(n);case"restore":return jYn(n);case void 0:case"--help":case"-h":return console.log(ddt(a.usageCommand)),0;default:return console.error(`unknown curate subcommand: ${n.command}
|
|
6580
6580
|
|
|
6581
|
-
${ddt(a.usageCommand)}`),2}}function bdt(n){let a={app:n,version:DYn(_x("__RED_BUILD_VERSION__",()=>"2.
|
|
6581
|
+
${ddt(a.usageCommand)}`),2}}function bdt(n){let a={app:n,version:DYn(_x("__RED_BUILD_VERSION__",()=>"2.74.1")??"0.0.0-dev"),gitSha:_x("__RED_BUILD_GIT_SHA__",()=>"abfe1a21e9fc1d8683dd071b1fe067c045fed2c0")??"unknown",buildTime:_x("__RED_BUILD_TIME__",()=>"2026-07-18T13:48:46-03:00")??"unknown",bundleAsset:_x("__RED_BUNDLE_ASSET__",()=>"memory.bundle.min.mjs")??"unknown"},i=_x("__REDDB_SDK_VERSION__",()=>"1.23.1"),d=_x("__REDDB_BINARY_TAG__",()=>"v1.23.1");return i&&(a.reddbSdkVersion=i),d&&(a.reddbBinaryTag=d),a}function DYn(n){return n.startsWith("v")?n.slice(1):n}function pdt(n){return`${n.app} ${n.version} ${n.gitSha}`}function _x(n,a){try{let i=a();return typeof i=="string"&&i.length>0?i:void 0}catch{return process.env[n.replace(/^__|__$/g,"")]}}var Zdt=`memory \u2014 governed operational memory for code agents
|
|
6582
6582
|
|
|
6583
6583
|
Common workflows:
|
|
6584
6584
|
remember one fact memory store "Decision: ..."
|