@polintpro/proposit-core 0.1.1 → 0.1.3

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 (119) hide show
  1. package/README.md +182 -8
  2. package/dist/cli/commands/analysis.d.ts +3 -0
  3. package/dist/cli/commands/analysis.d.ts.map +1 -0
  4. package/dist/cli/commands/analysis.js +324 -0
  5. package/dist/cli/commands/analysis.js.map +1 -0
  6. package/dist/cli/commands/arguments.d.ts +3 -0
  7. package/dist/cli/commands/arguments.d.ts.map +1 -0
  8. package/dist/cli/commands/arguments.js +118 -0
  9. package/dist/cli/commands/arguments.js.map +1 -0
  10. package/dist/cli/commands/expressions.d.ts +3 -0
  11. package/dist/cli/commands/expressions.d.ts.map +1 -0
  12. package/dist/cli/commands/expressions.js +240 -0
  13. package/dist/cli/commands/expressions.js.map +1 -0
  14. package/dist/cli/commands/meta.d.ts +3 -0
  15. package/dist/cli/commands/meta.d.ts.map +1 -0
  16. package/dist/cli/commands/meta.js +14 -0
  17. package/dist/cli/commands/meta.js.map +1 -0
  18. package/dist/cli/commands/premises.d.ts +3 -0
  19. package/dist/cli/commands/premises.d.ts.map +1 -0
  20. package/dist/cli/commands/premises.js +224 -0
  21. package/dist/cli/commands/premises.js.map +1 -0
  22. package/dist/cli/commands/render.d.ts +3 -0
  23. package/dist/cli/commands/render.d.ts.map +1 -0
  24. package/dist/cli/commands/render.js +25 -0
  25. package/dist/cli/commands/render.js.map +1 -0
  26. package/dist/cli/commands/roles.d.ts +3 -0
  27. package/dist/cli/commands/roles.d.ts.map +1 -0
  28. package/dist/cli/commands/roles.js +94 -0
  29. package/dist/cli/commands/roles.js.map +1 -0
  30. package/dist/cli/commands/variables.d.ts +3 -0
  31. package/dist/cli/commands/variables.d.ts.map +1 -0
  32. package/dist/cli/commands/variables.js +173 -0
  33. package/dist/cli/commands/variables.js.map +1 -0
  34. package/dist/cli/commands/versionShow.d.ts +3 -0
  35. package/dist/cli/commands/versionShow.d.ts.map +1 -0
  36. package/dist/cli/commands/versionShow.js +31 -0
  37. package/dist/cli/commands/versionShow.js.map +1 -0
  38. package/dist/cli/config.d.ts +7 -0
  39. package/dist/cli/config.d.ts.map +1 -0
  40. package/dist/cli/config.js +21 -0
  41. package/dist/cli/config.js.map +1 -0
  42. package/dist/cli/engine.d.ts +13 -0
  43. package/dist/cli/engine.d.ts.map +1 -0
  44. package/dist/cli/engine.js +71 -0
  45. package/dist/cli/engine.js.map +1 -0
  46. package/dist/cli/output.d.ts +5 -0
  47. package/dist/cli/output.d.ts.map +1 -0
  48. package/dist/cli/output.js +34 -0
  49. package/dist/cli/output.js.map +1 -0
  50. package/dist/cli/router.d.ts +14 -0
  51. package/dist/cli/router.d.ts.map +1 -0
  52. package/dist/cli/router.js +56 -0
  53. package/dist/cli/router.js.map +1 -0
  54. package/dist/cli/storage/analysis.d.ts +8 -0
  55. package/dist/cli/storage/analysis.d.ts.map +1 -0
  56. package/dist/cli/storage/analysis.js +70 -0
  57. package/dist/cli/storage/analysis.js.map +1 -0
  58. package/dist/cli/storage/arguments.d.ts +12 -0
  59. package/dist/cli/storage/arguments.d.ts.map +1 -0
  60. package/dist/cli/storage/arguments.js +80 -0
  61. package/dist/cli/storage/arguments.js.map +1 -0
  62. package/dist/cli/storage/premises.d.ts +9 -0
  63. package/dist/cli/storage/premises.d.ts.map +1 -0
  64. package/dist/cli/storage/premises.js +67 -0
  65. package/dist/cli/storage/premises.js.map +1 -0
  66. package/dist/cli/storage/roles.d.ts +4 -0
  67. package/dist/cli/storage/roles.d.ts.map +1 -0
  68. package/dist/cli/storage/roles.js +26 -0
  69. package/dist/cli/storage/roles.js.map +1 -0
  70. package/dist/cli/storage/variables.d.ts +4 -0
  71. package/dist/cli/storage/variables.d.ts.map +1 -0
  72. package/dist/cli/storage/variables.js +28 -0
  73. package/dist/cli/storage/variables.js.map +1 -0
  74. package/dist/cli.d.ts +3 -0
  75. package/dist/cli.d.ts.map +1 -0
  76. package/dist/cli.js +51 -0
  77. package/dist/cli.js.map +1 -0
  78. package/dist/lib/core/ArgumentEngine.d.ts +12 -11
  79. package/dist/lib/core/ArgumentEngine.d.ts.map +1 -1
  80. package/dist/lib/core/ArgumentEngine.js +13 -5
  81. package/dist/lib/core/ArgumentEngine.js.map +1 -1
  82. package/dist/lib/core/ExpressionManager.d.ts +8 -8
  83. package/dist/lib/core/ExpressionManager.d.ts.map +1 -1
  84. package/dist/lib/core/ExpressionManager.js +1 -1
  85. package/dist/lib/core/ExpressionManager.js.map +1 -1
  86. package/dist/lib/core/PremiseManager.d.ts +30 -22
  87. package/dist/lib/core/PremiseManager.d.ts.map +1 -1
  88. package/dist/lib/core/PremiseManager.js +27 -22
  89. package/dist/lib/core/PremiseManager.js.map +1 -1
  90. package/dist/lib/core/VariableManager.d.ts +7 -6
  91. package/dist/lib/core/VariableManager.d.ts.map +1 -1
  92. package/dist/lib/core/VariableManager.js +13 -0
  93. package/dist/lib/core/VariableManager.js.map +1 -1
  94. package/dist/lib/core/evaluation/shared.d.ts +4 -4
  95. package/dist/lib/core/evaluation/shared.d.ts.map +1 -1
  96. package/dist/lib/core/evaluation/shared.js.map +1 -1
  97. package/dist/lib/index.d.ts +3 -3
  98. package/dist/lib/index.d.ts.map +1 -1
  99. package/dist/lib/index.js +3 -3
  100. package/dist/lib/index.js.map +1 -1
  101. package/dist/lib/schemata/analysis.d.ts +8 -0
  102. package/dist/lib/schemata/analysis.d.ts.map +1 -0
  103. package/dist/lib/schemata/analysis.js +10 -0
  104. package/dist/lib/schemata/analysis.js.map +1 -0
  105. package/dist/lib/schemata/argument.d.ts +36 -2
  106. package/dist/lib/schemata/argument.d.ts.map +1 -1
  107. package/dist/lib/schemata/argument.js +34 -3
  108. package/dist/lib/schemata/argument.js.map +1 -1
  109. package/dist/lib/schemata/index.d.ts +4 -3
  110. package/dist/lib/schemata/index.d.ts.map +1 -1
  111. package/dist/lib/schemata/index.js +4 -3
  112. package/dist/lib/schemata/index.js.map +1 -1
  113. package/dist/lib/schemata/propositional.d.ts +52 -23
  114. package/dist/lib/schemata/propositional.d.ts.map +1 -1
  115. package/dist/lib/schemata/propositional.js +26 -30
  116. package/dist/lib/schemata/propositional.js.map +1 -1
  117. package/dist/lib/types/evaluation.d.ts +35 -38
  118. package/dist/lib/types/evaluation.d.ts.map +1 -1
  119. package/package.json +7 -2
@@ -0,0 +1,8 @@
1
+ import Type, { type Static } from "typebox";
2
+ export declare const CoreAnalysisFileSchema: Type.TObject<{
3
+ argumentId: Type.TString;
4
+ argumentVersion: Type.TNumber;
5
+ assignments: Type.TRecord<"^.*$", Type.TBoolean>;
6
+ }>;
7
+ export type TCoreAnalysisFile = Static<typeof CoreAnalysisFileSchema>;
8
+ //# sourceMappingURL=analysis.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"analysis.d.ts","sourceRoot":"","sources":["../../../src/lib/schemata/analysis.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,EAAE,EAAE,KAAK,MAAM,EAAE,MAAM,SAAS,CAAA;AAG3C,eAAO,MAAM,sBAAsB;;;;EAMjC,CAAA;AACF,MAAM,MAAM,iBAAiB,GAAG,MAAM,CAAC,OAAO,sBAAsB,CAAC,CAAA"}
@@ -0,0 +1,10 @@
1
+ import Type, {} from "typebox";
2
+ import { UUID } from "./shared.js";
3
+ export const CoreAnalysisFileSchema = Type.Object({
4
+ argumentId: UUID,
5
+ argumentVersion: Type.Number(),
6
+ assignments: Type.Record(Type.String(), Type.Boolean(), {
7
+ description: "Variable symbol → truth-value mapping.",
8
+ }),
9
+ });
10
+ //# sourceMappingURL=analysis.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"analysis.js","sourceRoot":"","sources":["../../../src/lib/schemata/analysis.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,EAAE,EAAe,MAAM,SAAS,CAAA;AAC3C,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAElC,MAAM,CAAC,MAAM,sBAAsB,GAAG,IAAI,CAAC,MAAM,CAAC;IAC9C,UAAU,EAAE,IAAI;IAChB,eAAe,EAAE,IAAI,CAAC,MAAM,EAAE;IAC9B,WAAW,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,OAAO,EAAE,EAAE;QACpD,WAAW,EAAE,wCAAwC;KACxD,CAAC;CACL,CAAC,CAAA"}
@@ -1,9 +1,43 @@
1
1
  import Type, { type Static } from "typebox";
2
- export declare const ArgumentSchema: Type.TObject<{
2
+ export declare const CoreArgumentMetaSchema: Type.TObject<{
3
3
  id: Type.TString;
4
+ title: Type.TString;
5
+ description: Type.TString;
6
+ }>;
7
+ export type TCoreArgumentMeta = Static<typeof CoreArgumentMetaSchema>;
8
+ export declare const CoreArgumentVersionedSchema: Type.TObject<{
4
9
  version: Type.TNumber;
10
+ createdAt: Type.TNumber;
11
+ }>;
12
+ export type TCoreArgumentVersioned = Static<typeof CoreArgumentVersionedSchema>;
13
+ export declare const CoreArgumentMutableDataSchema: Type.TObject<{
14
+ published: Type.TBoolean;
15
+ publishedAt: Type.TOptional<Type.TNumber>;
16
+ }>;
17
+ export type TCoreArgumentMutableData = Static<typeof CoreArgumentMutableDataSchema>;
18
+ export declare const CoreArgumentSchema: Type.TIntersect<[Type.TObject<{
19
+ id: Type.TString;
5
20
  title: Type.TString;
6
21
  description: Type.TString;
22
+ }>, Type.TObject<{
23
+ version: Type.TNumber;
24
+ createdAt: Type.TNumber;
25
+ }>, Type.TObject<{
26
+ published: Type.TBoolean;
27
+ publishedAt: Type.TOptional<Type.TNumber>;
28
+ }>]>;
29
+ export type TCoreArgument = Static<typeof CoreArgumentSchema>;
30
+ export declare const CoreArgumentVersionMetaSchema: Type.TIntersect<[Type.TObject<{
31
+ version: Type.TNumber;
32
+ createdAt: Type.TNumber;
33
+ }>, Type.TObject<{
34
+ published: Type.TBoolean;
35
+ publishedAt: Type.TOptional<Type.TNumber>;
36
+ }>]>;
37
+ export type TCoreArgumentVersionMeta = Static<typeof CoreArgumentVersionMetaSchema>;
38
+ export declare const CoreArgumentRoleStateSchema: Type.TObject<{
39
+ conclusionPremiseId: Type.TOptional<Type.TString>;
40
+ supportingPremiseIds: Type.TArray<Type.TString>;
7
41
  }>;
8
- export type TArgument = Static<typeof ArgumentSchema>;
42
+ export type TCoreArgumentRoleState = Static<typeof CoreArgumentRoleStateSchema>;
9
43
  //# sourceMappingURL=argument.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"argument.d.ts","sourceRoot":"","sources":["../../../src/lib/schemata/argument.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,EAAE,EAAE,KAAK,MAAM,EAAE,MAAM,SAAS,CAAA;AAG3C,eAAO,MAAM,cAAc;;;;;EAKzB,CAAA;AACF,MAAM,MAAM,SAAS,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAA"}
1
+ {"version":3,"file":"argument.d.ts","sourceRoot":"","sources":["../../../src/lib/schemata/argument.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,EAAE,EAAE,KAAK,MAAM,EAAE,MAAM,SAAS,CAAA;AAG3C,eAAO,MAAM,sBAAsB;;;;EAUlC,CAAA;AACD,MAAM,MAAM,iBAAiB,GAAG,MAAM,CAAC,OAAO,sBAAsB,CAAC,CAAA;AAErE,eAAO,MAAM,2BAA2B;;;EAavC,CAAA;AACD,MAAM,MAAM,sBAAsB,GAAG,MAAM,CAAC,OAAO,2BAA2B,CAAC,CAAA;AAE/E,eAAO,MAAM,6BAA6B;;;EAczC,CAAA;AACD,MAAM,MAAM,wBAAwB,GAAG,MAAM,CACzC,OAAO,6BAA6B,CACvC,CAAA;AAED,eAAO,MAAM,kBAAkB;;;;;;;;;;IAI7B,CAAA;AACF,MAAM,MAAM,aAAa,GAAG,MAAM,CAAC,OAAO,kBAAkB,CAAC,CAAA;AAE7D,eAAO,MAAM,6BAA6B;;;;;;IAGxC,CAAA;AACF,MAAM,MAAM,wBAAwB,GAAG,MAAM,CACzC,OAAO,6BAA6B,CACvC,CAAA;AAED,eAAO,MAAM,2BAA2B;;;EAGtC,CAAA;AACF,MAAM,MAAM,sBAAsB,GAAG,MAAM,CAAC,OAAO,2BAA2B,CAAC,CAAA"}
@@ -1,9 +1,40 @@
1
1
  import Type, {} from "typebox";
2
- import { UUID } from "./shared";
3
- export const ArgumentSchema = Type.Object({
2
+ import { UUID } from "./shared.js";
3
+ export const CoreArgumentMetaSchema = Type.Object({
4
4
  id: UUID,
5
- version: Type.Number(),
6
5
  title: Type.String(),
7
6
  description: Type.String(),
7
+ }, {
8
+ description: "Metadata for an argument that does not change for different versions of the same argument.",
9
+ });
10
+ export const CoreArgumentVersionedSchema = Type.Object({
11
+ version: Type.Number(),
12
+ createdAt: Type.Number({
13
+ description: "Unix timestamp in milliseconds of when the argument was created.",
14
+ default: () => Date.now(),
15
+ }),
16
+ }, {
17
+ description: "Data for an argument that will differ between different versions of the same argument",
18
+ });
19
+ export const CoreArgumentMutableDataSchema = Type.Object({
20
+ published: Type.Boolean(),
21
+ publishedAt: Type.Optional(Type.Number({
22
+ description: "Unix timestamp in milliseconds of when the argument was published.",
23
+ })),
24
+ }, {
25
+ description: "Data for an argument that can be changed (e.g. published status).",
26
+ });
27
+ export const CoreArgumentSchema = Type.Intersect([
28
+ CoreArgumentMetaSchema,
29
+ CoreArgumentVersionedSchema,
30
+ CoreArgumentMutableDataSchema,
31
+ ]);
32
+ export const CoreArgumentVersionMetaSchema = Type.Intersect([
33
+ CoreArgumentVersionedSchema,
34
+ CoreArgumentMutableDataSchema,
35
+ ]);
36
+ export const CoreArgumentRoleStateSchema = Type.Object({
37
+ conclusionPremiseId: Type.Optional(UUID),
38
+ supportingPremiseIds: Type.Array(UUID),
8
39
  });
9
40
  //# sourceMappingURL=argument.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"argument.js","sourceRoot":"","sources":["../../../src/lib/schemata/argument.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,EAAE,EAAe,MAAM,SAAS,CA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,CACJ,CAAA;AAKD,MAAM,CAAC,MAAM,kBAAkB,GAAG,IAAI,CAAC,SAAS,CAAC;IAC7C,sBAAsB;IACtB,2BAA2B;IAC3B,6BAA6B;CAChC,CAAC,CAAA;AAGF,MAAM,CAAC,MAAM,6BAA6B,GAAG,IAAI,CAAC,SAAS,CAAC;IACxD,2BAA2B;IAC3B,6BAA6B;CAChC,CAAC,CAAA;AAKF,MAAM,CAAC,MAAM,2BAA2B,GAAG,IAAI,CAAC,MAAM,CAAC;IACnD,mBAAmB,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC;IACxC,oBAAoB,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC;CACzC,CAAC,CAAA"}
@@ -1,4 +1,5 @@
1
- export * from "./argument";
2
- export * from "./propositional";
3
- export * from "./shared";
1
+ export * from "./analysis.js";
2
+ export * from "./argument.js";
3
+ export * from "./propositional.js";
4
+ export * from "./shared.js";
4
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/schemata/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA;AAC1B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,UAAU,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/schemata/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAA;AAC7B,cAAc,eAAe,CAAA;AAC7B,cAAc,oBAAoB,CAAA;AAClC,cAAc,aAAa,CAAA"}
@@ -1,4 +1,5 @@
1
- export * from "./argument";
2
- export * from "./propositional";
3
- export * from "./shared";
1
+ export * from "./analysis.js";
2
+ export * from "./argument.js";
3
+ export * from "./propositional.js";
4
+ export * from "./shared.js";
4
5
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/schemata/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA;AAC1B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,UAAU,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/schemata/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAA;AAC7B,cAAc,eAAe,CAAA;AAC7B,cAAc,oBAAoB,CAAA;AAClC,cAAc,aAAa,CAAA"}
@@ -1,7 +1,7 @@
1
1
  import Type, { type Static } from "typebox";
2
- export declare const PropositionalExpressionTypes: Type.TUnion<[Type.TLiteral<"variable">, Type.TLiteral<"operator">, Type.TLiteral<"formula">]>;
3
- export type TPropositionalExpressionTypes = Static<typeof PropositionalExpressionTypes>;
4
- export declare const PropositionalVariableExpressionSchema: Type.TObject<{
2
+ export declare const CorePropositionalExpressionTypes: Type.TUnion<[Type.TLiteral<"variable">, Type.TLiteral<"operator">, Type.TLiteral<"formula">]>;
3
+ export type TCorePropositionalExpressionTypes = Static<typeof CorePropositionalExpressionTypes>;
4
+ export declare const CorePropositionalVariableExpressionSchema: Type.TObject<{
5
5
  id: Type.TString;
6
6
  argumentId: Type.TString;
7
7
  argumentVersion: Type.TNumber;
@@ -10,10 +10,10 @@ export declare const PropositionalVariableExpressionSchema: Type.TObject<{
10
10
  type: Type.TLiteral<"variable">;
11
11
  variableId: Type.TString;
12
12
  }>;
13
- export type TPropositionalVariableExpression = Static<typeof PropositionalVariableExpressionSchema>;
14
- export declare const LogicalOperatorType: Type.TUnion<[Type.TLiteral<"not">, Type.TLiteral<"and">, Type.TLiteral<"or">, Type.TLiteral<"implies">, Type.TLiteral<"iff">]>;
15
- export type TLogicalOperatorType = Static<typeof LogicalOperatorType>;
16
- export declare const OperatorExpressionSchema: Type.TObject<{
13
+ export type TCorePropositionalVariableExpression = Static<typeof CorePropositionalVariableExpressionSchema>;
14
+ export declare const CoreLogicalOperatorType: Type.TUnion<[Type.TLiteral<"not">, Type.TLiteral<"and">, Type.TLiteral<"or">, Type.TLiteral<"implies">, Type.TLiteral<"iff">]>;
15
+ export type TCoreLogicalOperatorType = Static<typeof CoreLogicalOperatorType>;
16
+ export declare const CoreOperatorExpressionSchema: Type.TObject<{
17
17
  id: Type.TString;
18
18
  argumentId: Type.TString;
19
19
  argumentVersion: Type.TNumber;
@@ -22,8 +22,8 @@ export declare const OperatorExpressionSchema: Type.TObject<{
22
22
  type: Type.TLiteral<"operator">;
23
23
  operator: Type.TUnion<[Type.TLiteral<"not">, Type.TLiteral<"and">, Type.TLiteral<"or">, Type.TLiteral<"implies">, Type.TLiteral<"iff">]>;
24
24
  }>;
25
- export type TOperatorExpression = Static<typeof OperatorExpressionSchema>;
26
- export declare const FormulaExpressionSchema: Type.TObject<{
25
+ export type TCoreOperatorExpression = Static<typeof CoreOperatorExpressionSchema>;
26
+ export declare const CoreFormulaExpressionSchema: Type.TObject<{
27
27
  id: Type.TString;
28
28
  argumentId: Type.TString;
29
29
  argumentVersion: Type.TNumber;
@@ -31,8 +31,8 @@ export declare const FormulaExpressionSchema: Type.TObject<{
31
31
  position: Type.TUnion<[Type.TInteger, Type.TNull]>;
32
32
  type: Type.TLiteral<"formula">;
33
33
  }>;
34
- export type TFormulaExpression = Static<typeof FormulaExpressionSchema>;
35
- export declare const PropositionalExpressionSchema: Type.TUnion<[Type.TObject<{
34
+ export type TCoreFormulaExpression = Static<typeof CoreFormulaExpressionSchema>;
35
+ export declare const CorePropositionalExpressionSchema: Type.TUnion<[Type.TObject<{
36
36
  id: Type.TString;
37
37
  argumentId: Type.TString;
38
38
  argumentVersion: Type.TNumber;
@@ -56,26 +56,57 @@ export declare const PropositionalExpressionSchema: Type.TUnion<[Type.TObject<{
56
56
  position: Type.TUnion<[Type.TInteger, Type.TNull]>;
57
57
  type: Type.TLiteral<"formula">;
58
58
  }>]>;
59
- export type TPropositionalExpressionCombined = Static<typeof PropositionalExpressionSchema>;
60
- export type TPropositionalExpression<T extends TPropositionalExpressionTypes = TPropositionalExpressionTypes> = Extract<TPropositionalExpressionCombined, {
59
+ export type TCorePropositionalExpressionCombined = Static<typeof CorePropositionalExpressionSchema>;
60
+ export type TCorePropositionalExpression<T extends TCorePropositionalExpressionTypes = TCorePropositionalExpressionTypes> = Extract<TCorePropositionalExpressionCombined, {
61
61
  type: T;
62
62
  }>;
63
- export declare const PropositionalVariableSchema: Type.TObject<{
63
+ export declare const CorePropositionalVariableSchema: Type.TObject<{
64
64
  id: Type.TString;
65
65
  argumentId: Type.TString;
66
66
  argumentVersion: Type.TNumber;
67
67
  symbol: Type.TString;
68
68
  }>;
69
- export type TPropositionalVariable = Static<typeof PropositionalVariableSchema>;
70
- export declare const PremiseSchema: Type.TObject<{
69
+ export type TCorePropositionalVariable = Static<typeof CorePropositionalVariableSchema>;
70
+ export declare const CorePremiseMetaSchema: Type.TObject<{
71
71
  id: Type.TString;
72
+ title: Type.TOptional<Type.TString>;
73
+ }>;
74
+ export type TCorePremiseMeta = Static<typeof CorePremiseMetaSchema>;
75
+ export declare const CorePremiseDataSchema: Type.TObject<{
72
76
  rootExpressionId: Type.TOptional<Type.TString>;
73
- variables: Type.TArray<Type.TObject<{
77
+ variables: Type.TArray<Type.TString>;
78
+ expressions: Type.TArray<Type.TUnion<[Type.TObject<{
79
+ id: Type.TString;
80
+ argumentId: Type.TString;
81
+ argumentVersion: Type.TNumber;
82
+ parentId: Type.TUnion<[Type.TString, Type.TNull]>;
83
+ position: Type.TUnion<[Type.TInteger, Type.TNull]>;
84
+ type: Type.TLiteral<"variable">;
85
+ variableId: Type.TString;
86
+ }>, Type.TObject<{
74
87
  id: Type.TString;
75
88
  argumentId: Type.TString;
76
89
  argumentVersion: Type.TNumber;
77
- symbol: Type.TString;
78
- }>>;
90
+ parentId: Type.TUnion<[Type.TString, Type.TNull]>;
91
+ position: Type.TUnion<[Type.TInteger, Type.TNull]>;
92
+ type: Type.TLiteral<"operator">;
93
+ operator: Type.TUnion<[Type.TLiteral<"not">, Type.TLiteral<"and">, Type.TLiteral<"or">, Type.TLiteral<"implies">, Type.TLiteral<"iff">]>;
94
+ }>, Type.TObject<{
95
+ id: Type.TString;
96
+ argumentId: Type.TString;
97
+ argumentVersion: Type.TNumber;
98
+ parentId: Type.TUnion<[Type.TString, Type.TNull]>;
99
+ position: Type.TUnion<[Type.TInteger, Type.TNull]>;
100
+ type: Type.TLiteral<"formula">;
101
+ }>]>>;
102
+ }>;
103
+ export type TCorePremiseData = Static<typeof CorePremiseDataSchema>;
104
+ export declare const CorePremiseSchema: Type.TIntersect<[Type.TObject<{
105
+ id: Type.TString;
106
+ title: Type.TOptional<Type.TString>;
107
+ }>, Type.TObject<{
108
+ rootExpressionId: Type.TOptional<Type.TString>;
109
+ variables: Type.TArray<Type.TString>;
79
110
  expressions: Type.TArray<Type.TUnion<[Type.TObject<{
80
111
  id: Type.TString;
81
112
  argumentId: Type.TString;
@@ -100,8 +131,6 @@ export declare const PremiseSchema: Type.TObject<{
100
131
  position: Type.TUnion<[Type.TInteger, Type.TNull]>;
101
132
  type: Type.TLiteral<"formula">;
102
133
  }>]>>;
103
- type: Type.TUnion<[Type.TLiteral<"inference">, Type.TLiteral<"constraint">]>;
104
- title: Type.TOptional<Type.TString>;
105
- }>;
106
- export type TPremise = Static<typeof PremiseSchema>;
134
+ }>]>;
135
+ export type TCorePremise = Static<typeof CorePremiseSchema>;
107
136
  //# sourceMappingURL=propositional.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"propositional.d.ts","sourceRoot":"","sources":["../../../src/lib/schemata/propositional.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,EAAE,EAAE,KAAK,MAAM,EAAE,MAAM,SAAS,CAAA;AAO3C,eAAO,MAAM,4BAA4B,+FAIvC,CAAA;AACF,MAAM,MAAM,6BAA6B,GAAG,MAAM,CAC9C,OAAO,4BAA4B,CACtC,CAAA;AAoBD,eAAO,MAAM,qCAAqC;;;;;;;;EAMjD,CAAA;AAED,MAAM,MAAM,gCAAgC,GAAG,MAAM,CACjD,OAAO,qCAAqC,CAC/C,CAAA;AAED,eAAO,MAAM,m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} from "./shared";
2
+ import { UUID, Nullable } from "./shared.js";
3
3
  const VariableType = Type.Literal("variable");
4
4
  const OperatorType = Type.Literal("operator");
5
5
  const FormulaType = Type.Literal("formula");
6
- export const PropositionalExpressionTypes = Type.Union([
6
+ export const CorePropositionalExpressionTypes = Type.Union([
7
7
  VariableType,
8
8
  OperatorType,
9
9
  FormulaType,
@@ -20,58 +20,54 @@ const BasePropositionalExpressionSchema = Type.Object({
20
20
  description: "The ordering of this expression among its siblings under the same parent. Must be unique within (parentId, argumentId, argumentVersion).",
21
21
  })),
22
22
  });
23
- export const PropositionalVariableExpressionSchema = Type.Interface([BasePropositionalExpressionSchema], {
23
+ export const CorePropositionalVariableExpressionSchema = Type.Interface([BasePropositionalExpressionSchema], {
24
24
  type: VariableType,
25
25
  variableId: UUID,
26
26
  });
27
- export const LogicalOperatorType = Type.Union([
27
+ export const CoreLogicalOperatorType = Type.Union([
28
28
  Type.Literal("not"), // unary
29
29
  Type.Literal("and"), // variadic (≥2)
30
30
  Type.Literal("or"), // variadic (≥2)
31
31
  Type.Literal("implies"), // binary (ordered)
32
32
  Type.Literal("iff"), // binary (unordered but fixed 2)
33
33
  ]);
34
- export const OperatorExpressionSchema = Type.Interface([BasePropositionalExpressionSchema], {
34
+ export const CoreOperatorExpressionSchema = Type.Interface([BasePropositionalExpressionSchema], {
35
35
  type: OperatorType,
36
- operator: LogicalOperatorType,
36
+ operator: CoreLogicalOperatorType,
37
37
  });
38
- export const FormulaExpressionSchema = Type.Interface([BasePropositionalExpressionSchema], {
38
+ export const CoreFormulaExpressionSchema = Type.Interface([BasePropositionalExpressionSchema], {
39
39
  type: FormulaType,
40
40
  });
41
- export const PropositionalExpressionSchema = Type.Union([
42
- PropositionalVariableExpressionSchema,
43
- OperatorExpressionSchema,
44
- FormulaExpressionSchema,
41
+ export const CorePropositionalExpressionSchema = Type.Union([
42
+ CorePropositionalVariableExpressionSchema,
43
+ CoreOperatorExpressionSchema,
44
+ CoreFormulaExpressionSchema,
45
45
  ]);
46
- export const PropositionalVariableSchema = Type.Object({
46
+ export const CorePropositionalVariableSchema = Type.Object({
47
47
  id: UUID,
48
48
  argumentId: UUID,
49
49
  argumentVersion: Type.Number(),
50
50
  symbol: Type.String(),
51
51
  });
52
- export const PremiseSchema = Type.Object({
52
+ export const CorePremiseMetaSchema = Type.Object({
53
53
  // Auto-generated UUID
54
54
  id: UUID,
55
- // If the premise has expressions in it, this is the ID of the root expression
56
- // which must be a relation operator if the type is "inference", else. it can
57
- // be any type of expression.
55
+ title: Type.Optional(Type.String({
56
+ description: "An optional title for this premise, for display purposes.",
57
+ })),
58
+ });
59
+ export const CorePremiseDataSchema = Type.Object({
60
+ // If the premise has expressions in it, this is the ID of the root expression.
58
61
  rootExpressionId: Type.Optional(UUID),
59
- variables: Type.Array(PropositionalVariableSchema, {
60
- description: "All variables referenced in this premise.",
62
+ variables: Type.Array(UUID, {
63
+ description: "IDs of all variables referenced in this premise.",
61
64
  }),
62
- expressions: Type.Array(PropositionalExpressionSchema, {
65
+ expressions: Type.Array(CorePropositionalExpressionSchema, {
63
66
  description: "All expressions that are part of this premise, including sub-expressions. The root of the premise will have a null parentId.",
64
67
  }),
65
- type: Type.Union([
66
- Type.Literal("inference", {
67
- description: "A premise whose core operator is one of inference like implies or iff",
68
- }),
69
- Type.Literal("constraint", {
70
- description: "A premise without an inference operator, it restricts the possible valuations of variables but is not part of the chain of logical reasoning.",
71
- }),
72
- ]),
73
- title: Type.Optional(Type.String({
74
- description: "An optional title for this premise, for display purposes.",
75
- })),
76
68
  });
69
+ export const CorePremiseSchema = Type.Intersect([
70
+ CorePremiseMetaSchema,
71
+ CorePremiseDataSchema,
72
+ ]);
77
73
  //# sourceMappingURL=propositional.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"propositional.js","sourceRoot":"","sources":["../../../src/lib/schemata/propositional.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,EAAE,EAAe,MAAM,SAAS,CAAA;AAC3C,OAAO,EAAE,IAAI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AgB,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC;IACrC,SAAS,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE;QACxB,WAAW,EAAE,kDAAkD;KAClE,CAAC;IACF,WAAW,EAAE,IAAI,CAAC,KAAK,CAAC,iCAAiC,EAAE;QACvD,WAAW,EACP,8HAA8H;KACrI,CAAC;CACL,CAAC,CAAA;AAGF,MAAM,CAAC,MAAM,iBAAiB,GAAG,IAAI,CAAC,SAAS,CAAC;IAC5C,qBAAqB;IACrB,qBAAqB;CACxB,CAAC,CAAA"}
@@ -1,37 +1,34 @@
1
- import type { TArgument, TPremise } from "../schemata";
2
- export type TPremiseRole = "supporting" | "conclusion";
3
- export interface TArgumentRoleState {
4
- supportingPremiseIds: string[];
5
- conclusionPremiseId?: string;
1
+ import type { TCoreArgument, TCoreArgumentRoleState, TCorePremise } from "../schemata/index.js";
2
+ export type TCorePremiseRole = "supporting" | "conclusion";
3
+ export type { TCoreArgumentRoleState };
4
+ export interface TCoreArgumentEngineData {
5
+ argument: TCoreArgument;
6
+ premises: TCorePremise[];
7
+ roles: TCoreArgumentRoleState;
6
8
  }
7
- export interface TArgumentEngineData {
8
- argument: TArgument;
9
- premises: TPremise[];
10
- roles: TArgumentRoleState;
11
- }
12
- export type TVariableAssignment = Record<string, boolean>;
13
- export type TValidationSeverity = "error" | "warning";
14
- export type TValidationCode = "ARGUMENT_NO_CONCLUSION" | "ARGUMENT_CONCLUSION_NOT_FOUND" | "ARGUMENT_SUPPORTING_PREMISE_NOT_FOUND" | "ARGUMENT_ROLE_OVERLAP" | "ARGUMENT_VARIABLE_ID_SYMBOL_MISMATCH" | "ARGUMENT_VARIABLE_SYMBOL_AMBIGUOUS" | "PREMISE_EMPTY" | "PREMISE_ROOT_MISSING" | "PREMISE_ROOT_MISMATCH" | "EXPR_CHILD_COUNT_INVALID" | "EXPR_BINARY_POSITIONS_INVALID" | "EXPR_VARIABLE_UNDECLARED" | "ASSIGNMENT_MISSING_VARIABLE" | "ASSIGNMENT_UNKNOWN_VARIABLE";
15
- export interface TValidationIssue {
16
- code: TValidationCode;
17
- severity: TValidationSeverity;
9
+ export type TCoreVariableAssignment = Record<string, boolean>;
10
+ export type TCoreValidationSeverity = "error" | "warning";
11
+ export type TCoreValidationCode = "ARGUMENT_NO_CONCLUSION" | "ARGUMENT_CONCLUSION_NOT_FOUND" | "ARGUMENT_SUPPORTING_PREMISE_NOT_FOUND" | "ARGUMENT_ROLE_OVERLAP" | "ARGUMENT_VARIABLE_ID_SYMBOL_MISMATCH" | "ARGUMENT_VARIABLE_SYMBOL_AMBIGUOUS" | "PREMISE_EMPTY" | "PREMISE_ROOT_MISSING" | "PREMISE_ROOT_MISMATCH" | "EXPR_CHILD_COUNT_INVALID" | "EXPR_BINARY_POSITIONS_INVALID" | "EXPR_VARIABLE_UNDECLARED" | "ASSIGNMENT_MISSING_VARIABLE" | "ASSIGNMENT_UNKNOWN_VARIABLE";
12
+ export interface TCoreValidationIssue {
13
+ code: TCoreValidationCode;
14
+ severity: TCoreValidationSeverity;
18
15
  message: string;
19
16
  premiseId?: string;
20
17
  expressionId?: string;
21
18
  variableId?: string;
22
19
  }
23
- export interface TValidationResult {
20
+ export interface TCoreValidationResult {
24
21
  ok: boolean;
25
- issues: TValidationIssue[];
22
+ issues: TCoreValidationIssue[];
26
23
  }
27
- export interface TDirectionalVacuity {
24
+ export interface TCoreDirectionalVacuity {
28
25
  antecedentTrue: boolean;
29
26
  consequentTrue: boolean;
30
27
  implicationValue: boolean;
31
28
  isVacuouslyTrue: boolean;
32
29
  fired: boolean;
33
30
  }
34
- export type TPremiseInferenceDiagnostic = {
31
+ export type TCorePremiseInferenceDiagnostic = {
35
32
  kind: "implies";
36
33
  premiseId: string;
37
34
  rootExpressionId: string;
@@ -50,59 +47,59 @@ export type TPremiseInferenceDiagnostic = {
50
47
  leftValue: boolean;
51
48
  rightValue: boolean;
52
49
  rootValue: boolean;
53
- leftToRight: TDirectionalVacuity;
54
- rightToLeft: TDirectionalVacuity;
50
+ leftToRight: TCoreDirectionalVacuity;
51
+ rightToLeft: TCoreDirectionalVacuity;
55
52
  bothSidesTrue: boolean;
56
53
  bothSidesFalse: boolean;
57
54
  };
58
- export interface TPremiseEvaluationResult {
55
+ export interface TCorePremiseEvaluationResult {
59
56
  premiseId: string;
60
57
  premiseType: "inference" | "constraint";
61
58
  rootExpressionId?: string;
62
59
  rootValue?: boolean;
63
60
  expressionValues: Record<string, boolean>;
64
61
  variableValues: Record<string, boolean>;
65
- inferenceDiagnostic?: TPremiseInferenceDiagnostic;
62
+ inferenceDiagnostic?: TCorePremiseInferenceDiagnostic;
66
63
  }
67
- export interface TArgumentEvaluationOptions {
64
+ export interface TCoreArgumentEvaluationOptions {
68
65
  strictUnknownAssignmentKeys?: boolean;
69
66
  includeExpressionValues?: boolean;
70
67
  includeDiagnostics?: boolean;
71
68
  validateFirst?: boolean;
72
69
  }
73
- export interface TArgumentEvaluationResult {
70
+ export interface TCoreArgumentEvaluationResult {
74
71
  ok: boolean;
75
- validation?: TValidationResult;
76
- assignment?: TVariableAssignment;
72
+ validation?: TCoreValidationResult;
73
+ assignment?: TCoreVariableAssignment;
77
74
  referencedVariableIds?: string[];
78
- conclusion?: TPremiseEvaluationResult;
79
- supportingPremises?: TPremiseEvaluationResult[];
80
- constraintPremises?: TPremiseEvaluationResult[];
75
+ conclusion?: TCorePremiseEvaluationResult;
76
+ supportingPremises?: TCorePremiseEvaluationResult[];
77
+ constraintPremises?: TCorePremiseEvaluationResult[];
81
78
  isAdmissibleAssignment?: boolean;
82
79
  allSupportingPremisesTrue?: boolean;
83
80
  conclusionTrue?: boolean;
84
81
  isCounterexample?: boolean;
85
82
  preservesTruthUnderAssignment?: boolean;
86
83
  }
87
- export interface TValidityCheckOptions {
84
+ export interface TCoreValidityCheckOptions {
88
85
  mode?: "firstCounterexample" | "exhaustive";
89
86
  maxVariables?: number;
90
87
  maxAssignmentsChecked?: number;
91
88
  includeCounterexampleEvaluations?: boolean;
92
89
  validateFirst?: boolean;
93
90
  }
94
- export interface TCounterexample {
95
- assignment: TVariableAssignment;
96
- result: TArgumentEvaluationResult;
91
+ export interface TCoreCounterexample {
92
+ assignment: TCoreVariableAssignment;
93
+ result: TCoreArgumentEvaluationResult;
97
94
  }
98
- export interface TValidityCheckResult {
95
+ export interface TCoreValidityCheckResult {
99
96
  ok: boolean;
100
- validation?: TValidationResult;
97
+ validation?: TCoreValidationResult;
101
98
  isValid?: boolean;
102
99
  checkedVariableIds?: string[];
103
100
  numAssignmentsChecked?: number;
104
101
  numAdmissibleAssignments?: number;
105
- counterexamples?: TCounterexample[];
102
+ counterexamples?: TCoreCounterexample[];
106
103
  truncated?: boolean;
107
104
  }
108
105
  //# sourceMappingURL=evaluation.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"evaluation.d.ts","sourceRoot":"","sources":["../../../src/lib/types/evaluation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AAEtD,MAAM,MAAM,YAAY,GAAG,YAAY,GAAG,YAAY,CAAA;AAEtD,MAAM,WAAW,kBAAkB;IAE/B,oBAAoB,EAAE,MAAM,EAAE,CAAA;IAE9B,mBAAmB,CAAC,EAAE,MAAM,CAAA;CAC/B;AAED,MAAM,WAAW,mBAAmB;IAEhC,QAAQ,EAAE,SAAS,CAAA;IAEnB,QAAQ,EAAE,QAAQ,EAAE,CAAA;IAEpB,KAAK,EAAE,kBAAkB,CAAA;CAC5B;AAED,MAAM,MAAM,mBAAmB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;AAEzD,MAAM,MAAM,mBAAmB,GAAG,OAAO,GAAG,SAAS,CAAA;AAErD,MAAM,MAAM,eAAe,GACrB,wBAAwB,GACxB,+BAA+B,GAC/B,uCAAuC,GACvC,uBAAuB,GACvB,sCAAsC,GACtC,oCAAoC,GACpC,eAAe,GACf,sBAAsB,GACtB,u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A;IAE3C,YAAY,CAAC,EAAE,MAAM,CAAA;IAErB,qBAAqB,CAAC,EAAE,MAAM,CAAA;IAE9B,gCAAgC,CAAC,EAAE,OAAO,CAAA;IAE1C,aAAa,CAAC,EAAE,OAAO,CAAA;CAC1B;AAED,MAAM,WAAW,mBAAmB;IAEhC,UAAU,EAAE,uBAAuB,CAAA;IAEnC,MAAM,EAAE,6BAA6B,CAAA;CACxC;AAED,MAAM,WAAW,wBAAwB;IAErC,EAAE,EAAE,OAAO,CAAA;IAEX,UAAU,CAAC,EAAE,qBAAqB,CAAA;IAElC,OAAO,CAAC,EAAE,OAAO,CAAA;IAEjB,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAA;IAE7B,qBAAqB,CAAC,EAAE,MAAM,CAAA;IAE9B,wBAAwB,CAAC,EAAE,MAAM,CAAA;IAEjC,eAAe,CAAC,EAAE,mBAAmB,EAAE,CAAA;IAEvC,SAAS,CAAC,EAAE,OAAO,CAAA;CACtB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@polintpro/proposit-core",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "description": "Core engine for building and manipulating propositional logic arguments.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -12,6 +12,9 @@
12
12
  "import": "./dist/index.js"
13
13
  }
14
14
  },
15
+ "bin": {
16
+ "proposit-core": "./dist/cli.js"
17
+ },
15
18
  "files": [
16
19
  "dist"
17
20
  ],
@@ -32,6 +35,7 @@
32
35
  "vitest": "^4.0.18"
33
36
  },
34
37
  "dependencies": {
38
+ "commander": "^14.0.3",
35
39
  "typebox": "^1.1.0"
36
40
  },
37
41
  "scripts": {
@@ -41,6 +45,7 @@
41
45
  "prettify": "pnpm prettier -w .",
42
46
  "prettify:check": "pnpm prettier --check .",
43
47
  "test": "pnpm vitest run",
44
- "check": "pnpm run typecheck && pnpm run lint && pnpm run test && pnpm run build"
48
+ "check": "pnpm run typecheck && pnpm run lint && pnpm run test && pnpm run build",
49
+ "cli": "node dist/cli.js"
45
50
  }
46
51
  }