theprogrammablemind 8.7.0 → 8.8.0-beta.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.
Files changed (2) hide show
  1. package/client.js +5 -3
  2. package/package.json +1 -1
package/client.js CHANGED
@@ -873,7 +873,7 @@ const defaultInnerProcess = (config, errorHandler, responses) => {
873
873
  console.log('')
874
874
  const screen_width = process.stdout.columns
875
875
  // || 0 for when running without a console
876
- const widths = [60, 10, Math.max(80, screen_width-71 || 0)]
876
+ const widths = [70, 10, Math.max(80, screen_width-71 || 0)]
877
877
  const lines = new Lines(widths)
878
878
  lines.setElement(0, 0, '--- The paraphrases are ----------')
879
879
  lines.setElement(0, 2, '--- The response strings are ----------')
@@ -1078,7 +1078,6 @@ const rebuildTemplate = async ({ config, target, previousResultss, startOfChange
1078
1078
  }
1079
1079
 
1080
1080
  const checkTemplate = (template) => {
1081
- return
1082
1081
  if (!template) {
1083
1082
  return
1084
1083
  }
@@ -1097,6 +1096,9 @@ const checkTest = (testConfig) => {
1097
1096
  if (!testConfig.contents) {
1098
1097
  throw new Error("The 'test' property is missing the 'contents' property that contains contents of the '<km>.test.json' file")
1099
1098
  }
1099
+ if (testConfig.checks?.context && typeof testConfig.checks.context == 'function') {
1100
+ throw new Error(`The 'test.check.context' property should not be a function for ${testConfig.name}. If you are using defaultContextCheck then do this defaultContextCheck().`)
1101
+ }
1100
1102
  }
1101
1103
 
1102
1104
  const knowledgeModuleImpl = async ({
@@ -1286,7 +1288,7 @@ const knowledgeModuleImpl = async ({
1286
1288
  throw new Error('Error for the checkForLoop argument. Expected a JSON array of operator keys of the form "[<id>, <level>]"')
1287
1289
  }
1288
1290
  } catch (e) {
1289
- throw new Error('Error for the checkForLoop argument. Expected a JSON array of operator keys of the form "[<id>, <level>]"')
1291
+ throw new Error('Error for the checkForLoop argument. Expected a JSON array of operator keys of the form "[<id>, <level>]". For example \'[["op1", 0], ["op2", 1]]\'.')
1290
1292
  }
1291
1293
  } else {
1292
1294
  if (process.argv.includes('--checkForLoop') || process.argv.includes('-cl')) {
package/package.json CHANGED
@@ -65,6 +65,6 @@
65
65
  "sort-json": "^2.0.0",
66
66
  "uuid": "^8.3.2"
67
67
  },
68
- "version": "8.7.0",
68
+ "version": "8.8.0-beta.1",
69
69
  "license": "UNLICENSED"
70
70
  }