Update documentation and enhance chain inspection logic
Node.js build / build (20.x) (push) Waiting to run
Node.js build / build (22.x) (push) Waiting to run

- Revamped the README to provide comprehensive documentation for the Mindnet Causal Assistant plugin, including user, administrator, developer, and architect guides.
- Added specialized documentation sections for installation, deployment, and troubleshooting.
- Enhanced the chain inspection logic to determine effective required links based on template definitions, profiles, and defaults, improving the accuracy of findings related to link completeness.
This commit is contained in:
Lars committed 2026-01-20 11:34:58 +01:00
1 parent 86c88bc275
commit 74cacdd41d
12 files changed
+5381 -41

No files matched your search

+12 -1
View File
@@ -1063,6 +1063,15 @@ export async function inspectChains(
// Add template-based findings with profile thresholds
for (const match of templateMatches) {
// Find the template definition to check for template-level required_links override
const templateDef = chainTemplates?.templates?.find(t => t.name === match.templateName);
// Determine effective required_links: template.matching > profile > defaults.matching > false
const effectiveRequiredLinks = templateDef?.matching?.required_links ??
profile?.required_links ??
chainTemplates?.defaults?.matching?.required_links ??
false;
// missing_slot_<slotId> findings (with profile thresholds)
if (match.missingSlots.length > 0) {
const slotsFilled = Object.keys(match.slotAssignments).length;
@@ -1086,7 +1095,9 @@ export async function inspectChains(
}
// missing_link_constraints finding
if (match.slotsComplete && match.requiredLinks > 0 && !match.linksComplete) {
// Only emit if required_links=true (strict mode)
// In soft mode (required_links=false), suppress this finding even if links are incomplete
if (effectiveRequiredLinks && match.slotsComplete && match.requiredLinks > 0 && !match.linksComplete) {
findings.push({
code: "missing_link_constraints",
severity: applySeverityPolicy(profileName as "discovery" | "decisioning" | undefined, "missing_link_constraints", "info"),