@duplojs/agents-kit 0.1.0-beta.7 → 0.1.0-beta.9

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.
Files changed (100) hide show
  1. package/README.md +17 -9
  2. package/dist/bin/index.mjs +2 -2
  3. package/dist/bin/skills/index.d.ts +5 -0
  4. package/dist/bin/skills/index.mjs +11 -0
  5. package/dist/bin/{installSkill/index.d.ts → skills/install.d.ts} +1 -1
  6. package/dist/bin/{installSkill/index.mjs → skills/install.mjs} +2 -2
  7. package/dist/bin/{installSkill → skills}/skill.d.ts +7 -0
  8. package/dist/bin/{installSkill → skills}/skill.mjs +10 -8
  9. package/dist/bin/skills/update.d.ts +2 -0
  10. package/dist/bin/skills/update.mjs +19 -0
  11. package/docs/API/10-lang/10-common/10-asyncLoop.ts +4 -6
  12. package/docs/API/10-lang/10-common/10-asyncLoopAccumulator.ts +40 -0
  13. package/docs/API/10-lang/10-common/10-loop.ts +5 -7
  14. package/docs/API/10-lang/10-common/10-loopAccumulator.ts +35 -0
  15. package/docs/API/10-lang/10-common/10-loopAccumulatorFrom.ts +29 -0
  16. package/docs/API/10-lang/10-common/index.llms.md +14 -2
  17. package/docs/API/10-lang/10-generator/10-asyncLoop.ts +11 -20
  18. package/docs/API/10-lang/10-generator/10-asyncLoopAccumulator.ts +40 -0
  19. package/docs/API/10-lang/10-generator/10-loop.ts +11 -20
  20. package/docs/API/10-lang/10-generator/10-loopAccumulator.ts +33 -0
  21. package/docs/API/10-lang/10-generator/10-loopAccumulatorFrom.ts +30 -0
  22. package/docs/API/10-lang/10-generator/index.llms.md +14 -2
  23. package/docs/API/10-lang/10-object/10-discriminate.ts +84 -37
  24. package/docs/API/10-lang/10-object/index.llms.md +1 -5
  25. package/docs/API/20-server/10-file/10-appendFile.ts +50 -0
  26. package/docs/API/20-server/10-file/10-appendTextFile.ts +49 -0
  27. package/docs/API/20-server/10-file/10-copy.ts +50 -0
  28. package/docs/API/20-server/10-file/10-createEntryInterface.ts +13 -0
  29. package/docs/API/20-server/10-file/10-createFileInterface.ts +22 -0
  30. package/docs/API/20-server/10-file/10-createFolderInterface.ts +20 -0
  31. package/docs/API/20-server/10-file/10-createUnknownEntryInterface.ts +13 -0
  32. package/docs/API/20-server/10-file/10-ensureDirectory.ts +39 -0
  33. package/docs/API/20-server/10-file/10-ensureFile.ts +40 -0
  34. package/docs/API/20-server/10-file/10-exists.ts +36 -0
  35. package/docs/API/20-server/10-file/10-link.ts +51 -0
  36. package/docs/API/20-server/10-file/10-linkStat.ts +37 -0
  37. package/docs/API/20-server/10-file/10-makeDirectory.ts +41 -0
  38. package/docs/API/20-server/10-file/10-makeTemporaryDirectory.ts +35 -0
  39. package/docs/API/20-server/10-file/10-makeTemporaryFile.ts +40 -0
  40. package/docs/API/20-server/10-file/10-move.ts +51 -0
  41. package/docs/API/20-server/10-file/10-readDirectory.ts +52 -0
  42. package/docs/API/20-server/10-file/10-readFile.ts +38 -0
  43. package/docs/API/20-server/10-file/10-readJsonFile.ts +38 -0
  44. package/docs/API/20-server/10-file/10-readLink.ts +37 -0
  45. package/docs/API/20-server/10-file/10-readTextFile.ts +38 -0
  46. package/docs/API/20-server/10-file/10-realPath.ts +36 -0
  47. package/docs/API/20-server/10-file/10-relocate.ts +51 -0
  48. package/docs/API/20-server/10-file/10-remove.ts +40 -0
  49. package/docs/API/20-server/10-file/10-rename.ts +43 -0
  50. package/docs/API/20-server/10-file/10-setMode.ts +37 -0
  51. package/docs/API/20-server/10-file/10-setOwner.ts +38 -0
  52. package/docs/API/20-server/10-file/10-setTime.ts +42 -0
  53. package/docs/API/20-server/10-file/10-stat.ts +37 -0
  54. package/docs/API/20-server/10-file/10-symlink.ts +49 -0
  55. package/docs/API/20-server/10-file/10-truncate.ts +41 -0
  56. package/docs/API/20-server/10-file/10-walkDirectory.ts +75 -0
  57. package/docs/API/20-server/10-file/10-writeFile.ts +50 -0
  58. package/docs/API/20-server/10-file/10-writeJsonFile.ts +41 -0
  59. package/docs/API/20-server/10-file/10-writeTextFile.ts +49 -0
  60. package/docs/API/20-server/10-file/index.llms.md +144 -0
  61. package/docs/API/20-server/10-file/index.md +3 -0
  62. package/docs/API/20-server/20-common/10-environmentVariable.ts +57 -0
  63. package/docs/API/20-server/20-common/10-environmentVariableOrThrow.ts +21 -0
  64. package/docs/API/20-server/20-common/10-exitProcess.ts +9 -0
  65. package/docs/API/20-server/20-common/10-getCurrentDirectoryName.ts +10 -0
  66. package/docs/API/20-server/20-common/10-getCurrentWorkDirectory.ts +10 -0
  67. package/docs/API/20-server/20-common/10-getCurrentWorkDirectoryOrThrow.ts +10 -0
  68. package/docs/API/20-server/20-common/10-getProcessArguments.ts +10 -0
  69. package/docs/API/20-server/20-common/10-setCurrentWorkingDirectory.ts +14 -0
  70. package/docs/API/20-server/20-common/10-setCurrentWorkingDirectoryOrThrow.ts +12 -0
  71. package/docs/API/20-server/20-common/index.llms.md +40 -0
  72. package/docs/API/20-server/20-common/index.md +3 -0
  73. package/docs/API/20-server/30-dataStructure/10-file.ts +14 -0
  74. package/docs/API/20-server/30-dataStructure/10-fileExist.ts +27 -0
  75. package/docs/API/20-server/30-dataStructure/10-folder.ts +14 -0
  76. package/docs/API/20-server/30-dataStructure/10-folderExist.ts +14 -0
  77. package/docs/API/20-server/30-dataStructure/10-mimeType.ts +14 -0
  78. package/docs/API/20-server/30-dataStructure/10-size.ts +32 -0
  79. package/docs/API/20-server/30-dataStructure/index.llms.md +28 -0
  80. package/docs/API/20-server/30-dataStructure/index.md +3 -0
  81. package/docs/API/20-server/40-command/10-create.ts +39 -0
  82. package/docs/API/20-server/40-command/10-createArgument.ts +39 -0
  83. package/docs/API/20-server/40-command/10-createArrayOption.ts +36 -0
  84. package/docs/API/20-server/40-command/10-createBooleanOption.ts +28 -0
  85. package/docs/API/20-server/40-command/10-createOption.ts +46 -0
  86. package/docs/API/20-server/40-command/10-exec.ts +51 -0
  87. package/docs/API/20-server/40-command/10-execOptions.ts +30 -0
  88. package/docs/API/20-server/40-command/index.llms.md +32 -0
  89. package/docs/API/20-server/40-command/index.md +3 -0
  90. package/docs/API/20-server/index.md +3 -0
  91. package/docs/API.llms.md +20 -0
  92. package/package.json +14 -14
  93. package/skills/fundamental/SKILL.md +33 -33
  94. package/skills/fundamental/references/composition.md +9 -25
  95. package/skills/fundamental/references/constraints-and-validation.md +14 -51
  96. package/skills/fundamental/references/examples/iterations.ts +112 -0
  97. package/skills/fundamental/references/examples/result-selection.ts +65 -0
  98. package/skills/fundamental/references/iterations.md +24 -0
  99. package/skills/fundamental/references/results-and-errors.md +20 -45
  100. package/docs/API/10-lang/10-object/10-deepDiscriminate.ts +0 -63
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @title DSDataStructure.file
3
+ *
4
+ * Décrire une interface de fichier serveur.
5
+ */
6
+ import * as DSDataStructure from "@duplojs/server/dataStructure";
7
+
8
+ declare const input: unknown;
9
+
10
+ const structure = DSDataStructure.file([DSDataStructure.fileExist()]);
11
+ const result = await structure.asyncDecode(DSDataStructure.codecsString, input);
12
+
13
+ // Le codec construit une interface ; la contrainte inspecte le disque.
14
+ // Le résultat distingue le décodage réussi de l’échec de validation.
@@ -0,0 +1,27 @@
1
+ /**
2
+ * @title DSDataStructure.fileExist
3
+ *
4
+ * Exiger que l’interface représente un fichier existant.
5
+ */
6
+ import * as DEither from "@duplojs/lang/either";
7
+ import * as DSDataStructure from "@duplojs/server/dataStructure";
8
+ import * as DSFile from "@duplojs/server/file";
9
+
10
+ declare const input: unknown;
11
+
12
+ const structure = DSDataStructure.file([DSDataStructure.fileExist()]);
13
+
14
+ // Le codec transforme le chemin textuel en FileInterface. La contrainte
15
+ // interroge ensuite le système de fichiers : utiliser asyncDecode.
16
+ const result = await structure.asyncDecode(DSDataStructure.codecsString, input);
17
+
18
+ if (DEither.isRight(result)) {
19
+ const file = DEither.unwrapRight(result);
20
+
21
+ // La validation a constaté l'existence au moment du contrôle ; le fichier
22
+ // peut avoir changé ou disparu avant cette lecture, qui peut encore échouer.
23
+ const readResult = await DSFile.readTextFile(file.path);
24
+ } else {
25
+ // Le décodage du chemin ou le contrôle de la ressource a échoué.
26
+ const validationError = DEither.unwrapLeft(result);
27
+ }
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @title DSDataStructure.folder
3
+ *
4
+ * Décrire une interface de dossier serveur.
5
+ */
6
+ import * as DSDataStructure from "@duplojs/server/dataStructure";
7
+
8
+ declare const input: unknown;
9
+
10
+ const structure = DSDataStructure.folder([DSDataStructure.folderExist()]);
11
+ const result = await structure.asyncDecode(DSDataStructure.codecsString, input);
12
+
13
+ // Le codec construit une interface ; la contrainte inspecte le disque.
14
+ // Le résultat distingue le décodage réussi de l’échec de validation.
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @title DSDataStructure.folderExist
3
+ *
4
+ * Exiger que l’interface représente un dossier existant.
5
+ */
6
+ import * as DSDataStructure from "@duplojs/server/dataStructure";
7
+
8
+ declare const input: unknown;
9
+
10
+ const structure = DSDataStructure.folder([DSDataStructure.folderExist()]);
11
+ const result = await structure.asyncDecode(DSDataStructure.codecsString, input);
12
+
13
+ // La vérification asynchrone constate l’état du disque au moment du décodage.
14
+ // Le résultat distingue le décodage réussi de l’échec de validation.
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @title DSDataStructure.mimeType
3
+ *
4
+ * Contraindre le type MIME déduit de l’extension du fichier.
5
+ */
6
+ import * as DSDataStructure from "@duplojs/server/dataStructure";
7
+
8
+ declare const input: unknown;
9
+
10
+ const structure = DSDataStructure.file([DSDataStructure.mimeType("image/png")]);
11
+ const result = await structure.asyncDecode(DSDataStructure.codecsString, input);
12
+
13
+ // Le type MIME est déduit de l’extension, pas du contenu.
14
+ // Le résultat distingue le décodage réussi de l’échec de validation.
@@ -0,0 +1,32 @@
1
+ /**
2
+ * @title DSDataStructure.size
3
+ *
4
+ * Contraindre la taille en octets d’un fichier.
5
+ */
6
+ import * as DEither from "@duplojs/lang/either";
7
+ import * as DSDataStructure from "@duplojs/server/dataStructure";
8
+ import type * as DSFile from "@duplojs/server/file";
9
+
10
+ declare const file: DSFile.FileInterface;
11
+
12
+ const structure = DSDataStructure.file([
13
+ DSDataStructure.fileExist(),
14
+ DSDataStructure.size({
15
+ min: 1,
16
+ max: "1mb",
17
+ }),
18
+ ]);
19
+
20
+ // La taille est lue dans les métadonnées : asyncCheck est nécessaire même
21
+ // lorsque l'entrée est déjà une interface et ne nécessite pas de codec.
22
+ const result = await structure.asyncCheck(file);
23
+
24
+ if (DEither.isRight(result)) {
25
+ const checkedFile = DEither.unwrapRight(result);
26
+
27
+ // Les bornes sont vérifiées au moment du contrôle ; elles ne réservent pas
28
+ // le fichier et ne valident pas le contenu de ses octets.
29
+ const path = checkedFile.path;
30
+ } else {
31
+ const validationError = DEither.unwrapLeft(result);
32
+ }
@@ -0,0 +1,28 @@
1
+ ## DataStructure
2
+
3
+ Décoder et valider les interfaces de fichiers et dossiers avec les contraintes serveur.
4
+
5
+ ### [DSDataStructure.file](10-file.ts)
6
+
7
+ Décrire une interface de fichier serveur.
8
+
9
+ ### [DSDataStructure.fileExist](10-fileExist.ts)
10
+
11
+ Exiger que l’interface représente un fichier existant.
12
+
13
+ ### [DSDataStructure.folder](10-folder.ts)
14
+
15
+ Décrire une interface de dossier serveur.
16
+
17
+ ### [DSDataStructure.folderExist](10-folderExist.ts)
18
+
19
+ Exiger que l’interface représente un dossier existant.
20
+
21
+ ### [DSDataStructure.mimeType](10-mimeType.ts)
22
+
23
+ Contraindre le type MIME déduit de l’extension du fichier.
24
+
25
+ ### [DSDataStructure.size](10-size.ts)
26
+
27
+ Contraindre la taille en octets d’un fichier.
28
+
@@ -0,0 +1,3 @@
1
+ ## DataStructure
2
+
3
+ Décoder et valider les interfaces de fichiers et dossiers avec les contraintes serveur.
@@ -0,0 +1,39 @@
1
+ /**
2
+ * @title DSCommand.create
3
+ *
4
+ * Construire une commande nommée à placer dans un arbre de commandes.
5
+ */
6
+ import * as DDataStructure from "@duplojs/lang/dataStructure";
7
+ import * as DSCommand from "@duplojs/server/command";
8
+
9
+ declare function inspect(source: string): Promise<void>;
10
+
11
+ const inspectCommand = DSCommand.create(
12
+ "inspect",
13
+ {
14
+ description: "Inspect a resource",
15
+ subjects: [
16
+ DSCommand.createArgument(
17
+ "source",
18
+ DDataStructure.string(),
19
+ ),
20
+ ],
21
+ },
22
+ async({ args }) => {
23
+ await inspect(args.source);
24
+ },
25
+ );
26
+
27
+ const result = await DSCommand.exec(
28
+ { subjects: [inspectCommand] },
29
+ () => {},
30
+ );
31
+
32
+ // La sous-commande sélectionnée exécute son callback sans exécuter celui du parent.
33
+
34
+ // Exemple avec un fichier cli.ts exécuté par tsx :
35
+ // tsx cli.ts inspect ./resources
36
+ // « inspect » sélectionne la sous-commande, puis source reçoit ./resources.
37
+ // Un tableau subjects contient des arguments OU des sous-commandes : ces
38
+ // deux catégories ne peuvent pas être mélangées dans une même commande.
39
+ // Les options du parent ne sont pas héritées par les sous-commandes.
@@ -0,0 +1,39 @@
1
+ /**
2
+ * @title DSCommand.createArgument
3
+ *
4
+ * Déclarer un argument positionnel validé et transmis à une commande.
5
+ */
6
+ import type * as DCommon from "@duplojs/lang/common";
7
+ import * as DDataStructure from "@duplojs/lang/dataStructure";
8
+ import * as DSCommand from "@duplojs/server/command";
9
+
10
+ const command = DSCommand.create(
11
+ "generate",
12
+ {
13
+ subjects: [
14
+ DSCommand.createArgument(
15
+ "source",
16
+ DDataStructure.string(),
17
+ ),
18
+ DSCommand.createArgument(
19
+ "destination",
20
+ DDataStructure.string(),
21
+ { optional: true },
22
+ ),
23
+ ],
24
+ },
25
+ ({ args }) => {
26
+ // Les arguments facultatifs suivent les arguments obligatoires.
27
+ type _CheckArgs = DCommon.ExpectType<
28
+ typeof args,
29
+ {
30
+ readonly source: string;
31
+ readonly destination: string | undefined;
32
+ },
33
+ "strict"
34
+ >;
35
+ },
36
+ );
37
+
38
+ // Dans subjects, les arguments facultatifs suivent les obligatoires.
39
+ // Le même tableau ne peut pas mélanger arguments et sous-commandes.
@@ -0,0 +1,36 @@
1
+ /**
2
+ * @title DSCommand.createArrayOption
3
+ *
4
+ * Déclarer une option contenant plusieurs valeurs décodées.
5
+ */
6
+ import * as DArray from "@duplojs/lang/array";
7
+ import type * as DCommon from "@duplojs/lang/common";
8
+ import * as DDataStructure from "@duplojs/lang/dataStructure";
9
+ import * as DSCommand from "@duplojs/server/command";
10
+
11
+ const command = DSCommand.create(
12
+ "inspect",
13
+ {
14
+ options: [
15
+ DSCommand.createArrayOption(
16
+ "include",
17
+ DDataStructure.string(),
18
+ {
19
+ required: true,
20
+ min: 1,
21
+ },
22
+ ),
23
+ ],
24
+ },
25
+ ({ options }) => {
26
+ // La liste obligatoire et sa borne minimale garantissent un premier élément.
27
+ const first = DArray.first(options.include);
28
+ type _CheckFirst = DCommon.ExpectType<
29
+ typeof first,
30
+ string,
31
+ "strict"
32
+ >;
33
+ },
34
+ );
35
+
36
+ // Par défaut les éléments d'une valeur sont séparés par des virgules.
@@ -0,0 +1,28 @@
1
+ /**
2
+ * @title DSCommand.createBooleanOption
3
+ *
4
+ * Déclarer un flag représentant la présence d’une option.
5
+ */
6
+ import type * as DCommon from "@duplojs/lang/common";
7
+ import * as DSCommand from "@duplojs/server/command";
8
+
9
+ const command = DSCommand.create(
10
+ "inspect",
11
+ {
12
+ options: [
13
+ DSCommand.createBooleanOption(
14
+ "verbose",
15
+ { aliases: ["v"] },
16
+ ),
17
+ ],
18
+ },
19
+ ({ options }) => {
20
+ type _CheckVerbose = DCommon.ExpectType<
21
+ typeof options.verbose,
22
+ boolean,
23
+ "strict"
24
+ >;
25
+ },
26
+ );
27
+
28
+ // Le flag vaut false si absent, true si présent ; il n'accepte pas de valeur.
@@ -0,0 +1,46 @@
1
+ /**
2
+ * @title DSCommand.createOption
3
+ *
4
+ * Déclarer une option à valeur décodée par une data structure.
5
+ */
6
+ import type * as DCommon from "@duplojs/lang/common";
7
+ import * as DDataStructure from "@duplojs/lang/dataStructure";
8
+ import * as DSCommand from "@duplojs/server/command";
9
+
10
+ const command = DSCommand.create(
11
+ "generate",
12
+ {
13
+ options: [
14
+ DSCommand.createOption(
15
+ "format",
16
+ DDataStructure.literal(["json", "text"]),
17
+ {
18
+ required: true,
19
+ aliases: ["f"],
20
+ },
21
+ ),
22
+ DSCommand.createOption(
23
+ "output",
24
+ DDataStructure.string(),
25
+ ),
26
+ ],
27
+ },
28
+ ({ options }) => {
29
+ type _CheckFormat = DCommon.ExpectType<
30
+ typeof options.format,
31
+ "json" | "text",
32
+ "strict"
33
+ >;
34
+ type _CheckOutput = DCommon.ExpectType<
35
+ typeof options.output,
36
+ string | undefined,
37
+ "strict"
38
+ >;
39
+ },
40
+ );
41
+
42
+ // Une option présente sans valeur est invalide, même lorsqu'elle est facultative.
43
+
44
+ // Les noms et alias doivent éviter les collisions dans la commande ;
45
+ // help et h sont réservés à l’aide intégrée.
46
+ // Les formes --format=json, --format json et -f json sont acceptées.
@@ -0,0 +1,51 @@
1
+ /**
2
+ * @title DSCommand.exec
3
+ *
4
+ * Lire les arguments du processus, valider une commande racine et exécuter son traitement.
5
+ */
6
+ import type * as DCommon from "@duplojs/lang/common";
7
+ import * as DDataStructure from "@duplojs/lang/dataStructure";
8
+ import * as DEither from "@duplojs/lang/either";
9
+ import * as DSCommand from "@duplojs/server/command";
10
+
11
+ declare function generate(source: string, format: "json" | "text"): Promise<void>;
12
+
13
+ const result = await DSCommand.exec(
14
+ {
15
+ displayName: "generator",
16
+ subjects: [
17
+ DSCommand.createArgument(
18
+ "source",
19
+ DDataStructure.string(),
20
+ ),
21
+ ],
22
+ options: [
23
+ DSCommand.createOption(
24
+ "format",
25
+ DDataStructure.literal(["json", "text"]),
26
+ { required: true },
27
+ ),
28
+ ],
29
+ },
30
+ async({ args, options }) => {
31
+ type _CheckFormat = DCommon.ExpectType<
32
+ typeof options.format,
33
+ "json" | "text",
34
+ "strict"
35
+ >;
36
+
37
+ await generate(args.source, options.format);
38
+ },
39
+ );
40
+
41
+ if (DEither.isLeft(result)) {
42
+ // Le parsing invalide empêche le callback ; exec affiche le diagnostic.
43
+ const error = DEither.unwrapLeft(result);
44
+ }
45
+
46
+ // Pour un fichier cli.ts exécuté avec tsx :
47
+ // tsx cli.ts ./source --format=json
48
+ // Ici exec définit directement la commande racine : aucun nom de
49
+ // sous-commande ne précède l'argument source.
50
+ // Les noms d'options doivent être uniques dans la commande. subjects
51
+ // contient soit des arguments positionnels, soit des sous-commandes.
@@ -0,0 +1,30 @@
1
+ /**
2
+ * @title DSCommand.execOptions
3
+ *
4
+ * Décoder les options du processus sans déclarer de commande positionnelle.
5
+ */
6
+ import * as DEither from "@duplojs/lang/either";
7
+ import type * as DCommon from "@duplojs/lang/common";
8
+ import * as DDataStructure from "@duplojs/lang/dataStructure";
9
+ import * as DSCommand from "@duplojs/server/command";
10
+
11
+ const result = await DSCommand.execOptions([
12
+ DSCommand.createOption(
13
+ "format",
14
+ DDataStructure.literal(["json", "text"]),
15
+ ),
16
+ DSCommand.createBooleanOption("verbose"),
17
+ ]);
18
+
19
+ if (DEither.hasInformation(result, "success")) {
20
+ const options = DEither.unwrapRight(result);
21
+
22
+ type _CheckFormat = DCommon.ExpectType<
23
+ typeof options.format,
24
+ "json" | "text" | undefined,
25
+ "strict"
26
+ >;
27
+ }
28
+
29
+ // L'aide est également un Right, identifié par log-help ; une erreur est
30
+ // affichée puis renvoyée dans un Left.
@@ -0,0 +1,32 @@
1
+ ## Command
2
+
3
+ Déclarer et exécuter des commandes CLI et leurs entrées typées.
4
+
5
+ ### [DSCommand.create](10-create.ts)
6
+
7
+ Construire une commande nommée à placer dans un arbre de commandes.
8
+
9
+ ### [DSCommand.createArgument](10-createArgument.ts)
10
+
11
+ Déclarer un argument positionnel validé et transmis à une commande.
12
+
13
+ ### [DSCommand.createArrayOption](10-createArrayOption.ts)
14
+
15
+ Déclarer une option contenant plusieurs valeurs décodées.
16
+
17
+ ### [DSCommand.createBooleanOption](10-createBooleanOption.ts)
18
+
19
+ Déclarer un flag représentant la présence d’une option.
20
+
21
+ ### [DSCommand.createOption](10-createOption.ts)
22
+
23
+ Déclarer une option à valeur décodée par une data structure.
24
+
25
+ ### [DSCommand.exec](10-exec.ts)
26
+
27
+ Lire les arguments du processus, valider une commande racine et exécuter son traitement.
28
+
29
+ ### [DSCommand.execOptions](10-execOptions.ts)
30
+
31
+ Décoder les options du processus sans déclarer de commande positionnelle.
32
+
@@ -0,0 +1,3 @@
1
+ ## Command
2
+
3
+ Déclarer et exécuter des commandes CLI et leurs entrées typées.
@@ -0,0 +1,3 @@
1
+ # @duplojs/server
2
+
3
+ Capacités portables de fichiers, environnement, validation de ressources et commandes CLI.
package/docs/API.llms.md CHANGED
@@ -58,6 +58,26 @@ Fonctions de manipulation, recherche, validation et transformation des chaînes
58
58
 
59
59
  Manipulation et typage des tuples : convertir les garanties de cardinalité en positions typées, puis transformer leurs éléments en conservant leur forme.
60
60
 
61
+ # @duplojs/server
62
+
63
+ Capacités portables de fichiers, environnement, validation de ressources et commandes CLI.
64
+
65
+ ## [File](API/20-server/10-file/index.llms.md)
66
+
67
+ Lire et modifier les ressources du système de fichiers, leurs chemins et leurs métadonnées.
68
+
69
+ ## [Common](API/20-server/20-common/index.llms.md)
70
+
71
+ Accéder à la configuration, aux arguments et aux capacités du processus.
72
+
73
+ ## [DataStructure](API/20-server/30-dataStructure/index.llms.md)
74
+
75
+ Décoder et valider les interfaces de fichiers et dossiers avec les contraintes serveur.
76
+
77
+ ## [Command](API/20-server/40-command/index.llms.md)
78
+
79
+ Déclarer et exécuter des commandes CLI et leurs entrées typées.
80
+
61
81
  # @duplojs/json-web-token
62
82
 
63
83
  Politiques JWT réutilisables, signature, chiffrement facultatif et primitives cryptographiques.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@duplojs/agents-kit",
3
- "version": "0.1.0-beta.7",
3
+ "version": "0.1.0-beta.9",
4
4
  "license": "MIT",
5
5
  "author": {
6
6
  "name": "DuploJS",
@@ -32,19 +32,19 @@
32
32
  "./docs/API/*/index.llms.md": "./docs/API/*/index.llms.md"
33
33
  },
34
34
  "dependencies": {
35
- "@duplojs/lang": "0.1.0-beta.7",
36
- "@duplojs/server": "0.1.0-beta.7"
35
+ "@duplojs/lang": "0.1.0-beta.9",
36
+ "@duplojs/server": "0.1.0-beta.9"
37
37
  },
38
38
  "peerDependencies": {
39
- "@duplojs/code-config": "0.1.0-beta.7",
40
- "@duplojs/eslint": "0.1.0-beta.7",
41
- "@duplojs/form": "0.1.0-beta.7",
42
- "@duplojs/http": "0.1.0-beta.7",
43
- "@duplojs/json-web-token": "0.1.0-beta.7",
44
- "@duplojs/lang": "0.1.0-beta.7",
45
- "@duplojs/playwright": "0.1.0-beta.7",
46
- "@duplojs/server": "0.1.0-beta.7",
47
- "@duplojs/tools": "0.1.0-beta.7"
39
+ "@duplojs/code-config": "0.1.0-beta.9",
40
+ "@duplojs/eslint": "0.1.0-beta.9",
41
+ "@duplojs/form": "0.1.0-beta.9",
42
+ "@duplojs/http": "0.1.0-beta.9",
43
+ "@duplojs/json-web-token": "0.1.0-beta.9",
44
+ "@duplojs/lang": "0.1.0-beta.9",
45
+ "@duplojs/playwright": "0.1.0-beta.9",
46
+ "@duplojs/server": "0.1.0-beta.9",
47
+ "@duplojs/tools": "0.1.0-beta.9"
48
48
  },
49
49
  "peerDependenciesMeta": {
50
50
  "@duplojs/code-config": {
@@ -70,8 +70,8 @@
70
70
  }
71
71
  },
72
72
  "devDependencies": {
73
- "@duplojs/code-config": "0.1.0-beta.7",
74
- "@duplojs/eslint": "0.1.0-beta.7",
73
+ "@duplojs/code-config": "0.1.0-beta.9",
74
+ "@duplojs/eslint": "0.1.0-beta.9",
75
75
  "@types/node": "24.13.3",
76
76
  "@types/web": "0.0.358",
77
77
  "vue": "3.5.43",