dsh-auto-ontology 0.2.1 → 0.2.2

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.
@@ -12,17 +12,17 @@ const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "..");
12
12
  const argv = process.argv.slice(2);
13
13
  const [cmd, ...rest] = argv;
14
14
 
15
- let script_file = "build_ontology.py";
16
- if (cmd === "eval") {
17
- script_file = "eval_evidence.py"; // auto-ontology eval --from x.json [--n 20] [--seed 42]
18
- } else if (cmd === "validate") {
19
- script_file = "validate_format.py"; // auto-ontology validate ontologies/*.json
20
- }
15
+ const SUBCOMMANDS = { // named subcommands: strip the name, route the script
16
+ build: "build_ontology.py",
17
+ eval: "eval_evidence.py", // auto-ontology eval --from x.json [--n 20] [--seed 42]
18
+ validate: "validate_format.py", // auto-ontology validate ontologies/*.json
19
+ };
20
+ let script_file = SUBCOMMANDS[cmd] || "build_ontology.py";
21
21
  let pass;
22
- if (cmd === "build") {
22
+ if (SUBCOMMANDS[cmd]) {
23
23
  pass = rest;
24
24
  } else {
25
- pass = argv; // engine args pass through verbatim (build is the default)
25
+ pass = argv; // bare engine args pass through verbatim (build is the default)
26
26
  }
27
27
 
28
28
  // Artifacts land in the caller's cwd (the engine reads ONTOLOGY_HOME).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-auto-ontology",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Auto ontology construction for DeepSeek Harness — two-pass LLM pipeline (TBox schema from corpus, ABox assertions per document) with an evidence quote on every entity/relation, a type guard against silent drops, append-only incremental merge, conservative coreference, JSON-LD export and evidence-span queries. Zero-infra stdlib CLI + typed agent tools.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -52,4 +52,4 @@
52
52
  "@deepseek-ai/cordis": "^4.0.0",
53
53
  "@deepseek-ai/dsh-tools": ">=0.0.1-rc.1"
54
54
  }
55
- }
55
+ }