@exellix/ai-tasks 7.8.0
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.
- package/.env.example +3 -0
- package/.metadata/instructions-builders/create-expected-output-instructions.md +195 -0
- package/.metadata/readme.md +48 -0
- package/.metadata/shared/audit.md +29 -0
- package/.metadata/skills/professional-answer +32 -0
- package/.metadata/skills/professional-answer.compressed.md +11 -0
- package/.metadata/skills/professional-answer.instructions +33 -0
- package/.metadata/skills/professional-answer.instructions.md +33 -0
- package/.metadata/skills/professional-answer.l2.md +28 -0
- package/.metadata/skills/professional-answer.md +32 -0
- package/.metadata/skills/professional-answer.prompt +1 -0
- package/.metadata/skills/professional-answer.prompt.md +1 -0
- package/.metadata/skills/professional-decision.md +26 -0
- package/BREAKING-CHANGES.md +43 -0
- package/CHANGELOG.md +147 -0
- package/README.md +2497 -0
- package/RUNTASK_REQUEST.md +369 -0
- package/dist/activix/activixClient.d.ts +6 -0
- package/dist/activix/activixClient.d.ts.map +1 -0
- package/dist/activix/activixClient.js +131 -0
- package/dist/activix/activixClient.js.map +1 -0
- package/dist/activix/getTaskActivities.d.ts +10 -0
- package/dist/activix/getTaskActivities.d.ts.map +1 -0
- package/dist/activix/getTaskActivities.js +17 -0
- package/dist/activix/getTaskActivities.js.map +1 -0
- package/dist/activix/phaseTracking.d.ts +17 -0
- package/dist/activix/phaseTracking.d.ts.map +1 -0
- package/dist/activix/phaseTracking.js +85 -0
- package/dist/activix/phaseTracking.js.map +1 -0
- package/dist/aiScoping/index.d.ts +6 -0
- package/dist/aiScoping/index.d.ts.map +1 -0
- package/dist/aiScoping/index.js +4 -0
- package/dist/aiScoping/index.js.map +1 -0
- package/dist/aiScoping/runAiScoping.d.ts +36 -0
- package/dist/aiScoping/runAiScoping.d.ts.map +1 -0
- package/dist/aiScoping/runAiScoping.js +100 -0
- package/dist/aiScoping/runAiScoping.js.map +1 -0
- package/dist/aiScoping/runScopingCall.d.ts +23 -0
- package/dist/aiScoping/runScopingCall.d.ts.map +1 -0
- package/dist/aiScoping/runScopingCall.js +50 -0
- package/dist/aiScoping/runScopingCall.js.map +1 -0
- package/dist/aiScoping/validateAiScoping.d.ts +7 -0
- package/dist/aiScoping/validateAiScoping.d.ts.map +1 -0
- package/dist/aiScoping/validateAiScoping.js +33 -0
- package/dist/aiScoping/validateAiScoping.js.map +1 -0
- package/dist/aiSkillsUpstreamExports.d.ts +13 -0
- package/dist/aiSkillsUpstreamExports.d.ts.map +1 -0
- package/dist/aiSkillsUpstreamExports.js +12 -0
- package/dist/aiSkillsUpstreamExports.js.map +1 -0
- package/dist/analysis/analyzeRunTaskRequest.d.ts +29 -0
- package/dist/analysis/analyzeRunTaskRequest.d.ts.map +1 -0
- package/dist/analysis/analyzeRunTaskRequest.js +85 -0
- package/dist/analysis/analyzeRunTaskRequest.js.map +1 -0
- package/dist/analysis/index.d.ts +3 -0
- package/dist/analysis/index.d.ts.map +1 -0
- package/dist/analysis/index.js +2 -0
- package/dist/analysis/index.js.map +1 -0
- package/dist/builders/task-request-builder.d.ts +310 -0
- package/dist/builders/task-request-builder.d.ts.map +1 -0
- package/dist/builders/task-request-builder.js +581 -0
- package/dist/builders/task-request-builder.js.map +1 -0
- package/dist/compile/compileTaskConfiguration.d.ts +15 -0
- package/dist/compile/compileTaskConfiguration.d.ts.map +1 -0
- package/dist/compile/compileTaskConfiguration.js +184 -0
- package/dist/compile/compileTaskConfiguration.js.map +1 -0
- package/dist/compile/index.d.ts +2 -0
- package/dist/compile/index.d.ts.map +1 -0
- package/dist/compile/index.js +2 -0
- package/dist/compile/index.js.map +1 -0
- package/dist/core/task-sdk.d.ts +36 -0
- package/dist/core/task-sdk.d.ts.map +1 -0
- package/dist/core/task-sdk.js +2432 -0
- package/dist/core/task-sdk.js.map +1 -0
- package/dist/errors/smartInputValidationError.d.ts +39 -0
- package/dist/errors/smartInputValidationError.d.ts.map +1 -0
- package/dist/errors/smartInputValidationError.js +97 -0
- package/dist/errors/smartInputValidationError.js.map +1 -0
- package/dist/errors/taskConfigurationCompileError.d.ts +16 -0
- package/dist/errors/taskConfigurationCompileError.d.ts.map +1 -0
- package/dist/errors/taskConfigurationCompileError.js +20 -0
- package/dist/errors/taskConfigurationCompileError.js.map +1 -0
- package/dist/execution-strategies/applyExecutionStrategyOutputs.d.ts +17 -0
- package/dist/execution-strategies/applyExecutionStrategyOutputs.d.ts.map +1 -0
- package/dist/execution-strategies/applyExecutionStrategyOutputs.js +63 -0
- package/dist/execution-strategies/applyExecutionStrategyOutputs.js.map +1 -0
- package/dist/execution-strategies/constants.d.ts +14 -0
- package/dist/execution-strategies/constants.d.ts.map +1 -0
- package/dist/execution-strategies/constants.js +13 -0
- package/dist/execution-strategies/constants.js.map +1 -0
- package/dist/execution-strategies/executionStrategyCatalogMetadata.d.ts +9 -0
- package/dist/execution-strategies/executionStrategyCatalogMetadata.d.ts.map +1 -0
- package/dist/execution-strategies/executionStrategyCatalogMetadata.js +37 -0
- package/dist/execution-strategies/executionStrategyCatalogMetadata.js.map +1 -0
- package/dist/execution-strategies/genericExecutionFuncxEnvelope.d.ts +94 -0
- package/dist/execution-strategies/genericExecutionFuncxEnvelope.d.ts.map +1 -0
- package/dist/execution-strategies/genericExecutionFuncxEnvelope.js +306 -0
- package/dist/execution-strategies/genericExecutionFuncxEnvelope.js.map +1 -0
- package/dist/execution-strategies/resolveExecutionStrategies.d.ts +14 -0
- package/dist/execution-strategies/resolveExecutionStrategies.d.ts.map +1 -0
- package/dist/execution-strategies/resolveExecutionStrategies.js +108 -0
- package/dist/execution-strategies/resolveExecutionStrategies.js.map +1 -0
- package/dist/execution-strategies/runFuncxExecutionStrategy.d.ts +37 -0
- package/dist/execution-strategies/runFuncxExecutionStrategy.d.ts.map +1 -0
- package/dist/execution-strategies/runFuncxExecutionStrategy.js +72 -0
- package/dist/execution-strategies/runFuncxExecutionStrategy.js.map +1 -0
- package/dist/index.d.ts +99 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +106 -0
- package/dist/index.js.map +1 -0
- package/dist/internal/resolveLlmCallForXynthesis.d.ts +52 -0
- package/dist/internal/resolveLlmCallForXynthesis.d.ts.map +1 -0
- package/dist/internal/resolveLlmCallForXynthesis.js +81 -0
- package/dist/internal/resolveLlmCallForXynthesis.js.map +1 -0
- package/dist/internal/resolveRunTaskRuntimeKnobs.d.ts +19 -0
- package/dist/internal/resolveRunTaskRuntimeKnobs.d.ts.map +1 -0
- package/dist/internal/resolveRunTaskRuntimeKnobs.js +52 -0
- package/dist/internal/resolveRunTaskRuntimeKnobs.js.map +1 -0
- package/dist/internal/runPostStepLlmCall.d.ts +52 -0
- package/dist/internal/runPostStepLlmCall.d.ts.map +1 -0
- package/dist/internal/runPostStepLlmCall.js +170 -0
- package/dist/internal/runPostStepLlmCall.js.map +1 -0
- package/dist/localTasks/collectEvidence.d.ts +3 -0
- package/dist/localTasks/collectEvidence.d.ts.map +1 -0
- package/dist/localTasks/collectEvidence.js +364 -0
- package/dist/localTasks/collectEvidence.js.map +1 -0
- package/dist/localTasks/decideWebScope.d.ts +3 -0
- package/dist/localTasks/decideWebScope.d.ts.map +1 -0
- package/dist/localTasks/decideWebScope.js +56 -0
- package/dist/localTasks/decideWebScope.js.map +1 -0
- package/dist/localTasks/index.d.ts +5 -0
- package/dist/localTasks/index.d.ts.map +1 -0
- package/dist/localTasks/index.js +19 -0
- package/dist/localTasks/index.js.map +1 -0
- package/dist/localTasks/narrixAssetPlayground.d.ts +13 -0
- package/dist/localTasks/narrixAssetPlayground.d.ts.map +1 -0
- package/dist/localTasks/narrixAssetPlayground.js +161 -0
- package/dist/localTasks/narrixAssetPlayground.js.map +1 -0
- package/dist/localTasks/narrixSubnetPlayground.d.ts +14 -0
- package/dist/localTasks/narrixSubnetPlayground.d.ts.map +1 -0
- package/dist/localTasks/narrixSubnetPlayground.js +168 -0
- package/dist/localTasks/narrixSubnetPlayground.js.map +1 -0
- package/dist/localTasks/narrixVulnGroupPlayground.d.ts +13 -0
- package/dist/localTasks/narrixVulnGroupPlayground.d.ts.map +1 -0
- package/dist/localTasks/narrixVulnGroupPlayground.js +161 -0
- package/dist/localTasks/narrixVulnGroupPlayground.js.map +1 -0
- package/dist/localTasks/narrixVulnInstancePlayground.d.ts +13 -0
- package/dist/localTasks/narrixVulnInstancePlayground.d.ts.map +1 -0
- package/dist/localTasks/narrixVulnInstancePlayground.js +165 -0
- package/dist/localTasks/narrixVulnInstancePlayground.js.map +1 -0
- package/dist/localTasks/nodeCallExport.d.ts +6 -0
- package/dist/localTasks/nodeCallExport.d.ts.map +1 -0
- package/dist/localTasks/nodeCallExport.js +99 -0
- package/dist/localTasks/nodeCallExport.js.map +1 -0
- package/dist/localTasks/nodeCallExportBatch.d.ts +3 -0
- package/dist/localTasks/nodeCallExportBatch.d.ts.map +1 -0
- package/dist/localTasks/nodeCallExportBatch.js +52 -0
- package/dist/localTasks/nodeCallExportBatch.js.map +1 -0
- package/dist/localTasks/normalizeNarrixResult.d.ts +3 -0
- package/dist/localTasks/normalizeNarrixResult.d.ts.map +1 -0
- package/dist/localTasks/normalizeNarrixResult.js +106 -0
- package/dist/localTasks/normalizeNarrixResult.js.map +1 -0
- package/dist/localTasks/registry.d.ts +4 -0
- package/dist/localTasks/registry.d.ts.map +1 -0
- package/dist/localTasks/registry.js +8 -0
- package/dist/localTasks/registry.js.map +1 -0
- package/dist/localTasks/types.d.ts +28 -0
- package/dist/localTasks/types.d.ts.map +1 -0
- package/dist/localTasks/types.js +2 -0
- package/dist/localTasks/types.js.map +1 -0
- package/dist/localTasks/validateInput.d.ts +3 -0
- package/dist/localTasks/validateInput.d.ts.map +1 -0
- package/dist/localTasks/validateInput.js +66 -0
- package/dist/localTasks/validateInput.js.map +1 -0
- package/dist/methods/convenience-methods.d.ts +45 -0
- package/dist/methods/convenience-methods.d.ts.map +1 -0
- package/dist/methods/convenience-methods.js +39 -0
- package/dist/methods/convenience-methods.js.map +1 -0
- package/dist/narrix/applyNarrixScope.d.ts +10 -0
- package/dist/narrix/applyNarrixScope.d.ts.map +1 -0
- package/dist/narrix/applyNarrixScope.js +69 -0
- package/dist/narrix/applyNarrixScope.js.map +1 -0
- package/dist/narrix/buildNarrixAttachment.d.ts +9 -0
- package/dist/narrix/buildNarrixAttachment.d.ts.map +1 -0
- package/dist/narrix/buildNarrixAttachment.js +29 -0
- package/dist/narrix/buildNarrixAttachment.js.map +1 -0
- package/dist/narrix/buildWebScopeScopeInput.d.ts +39 -0
- package/dist/narrix/buildWebScopeScopeInput.d.ts.map +1 -0
- package/dist/narrix/buildWebScopeScopeInput.js +193 -0
- package/dist/narrix/buildWebScopeScopeInput.js.map +1 -0
- package/dist/narrix/flags.d.ts +4 -0
- package/dist/narrix/flags.d.ts.map +1 -0
- package/dist/narrix/flags.js +4 -0
- package/dist/narrix/flags.js.map +1 -0
- package/dist/narrix/index.d.ts +11 -0
- package/dist/narrix/index.d.ts.map +1 -0
- package/dist/narrix/index.js +14 -0
- package/dist/narrix/index.js.map +1 -0
- package/dist/narrix/narrixClient.d.ts +9 -0
- package/dist/narrix/narrixClient.d.ts.map +1 -0
- package/dist/narrix/narrixClient.js +46 -0
- package/dist/narrix/narrixClient.js.map +1 -0
- package/dist/narrix/narrixContextMarkdown.d.ts +15 -0
- package/dist/narrix/narrixContextMarkdown.d.ts.map +1 -0
- package/dist/narrix/narrixContextMarkdown.js +98 -0
- package/dist/narrix/narrixContextMarkdown.js.map +1 -0
- package/dist/narrix/narrixRunnerModule.d.ts +11 -0
- package/dist/narrix/narrixRunnerModule.d.ts.map +1 -0
- package/dist/narrix/narrixRunnerModule.js +17 -0
- package/dist/narrix/narrixRunnerModule.js.map +1 -0
- package/dist/narrix/runNarrixForChat.d.ts +3 -0
- package/dist/narrix/runNarrixForChat.d.ts.map +1 -0
- package/dist/narrix/runNarrixForChat.js +51 -0
- package/dist/narrix/runNarrixForChat.js.map +1 -0
- package/dist/narrix/runNarrixForDocs.d.ts +3 -0
- package/dist/narrix/runNarrixForDocs.d.ts.map +1 -0
- package/dist/narrix/runNarrixForDocs.js +50 -0
- package/dist/narrix/runNarrixForDocs.js.map +1 -0
- package/dist/narrix/runNarrixForRecord.d.ts +3 -0
- package/dist/narrix/runNarrixForRecord.d.ts.map +1 -0
- package/dist/narrix/runNarrixForRecord.js +47 -0
- package/dist/narrix/runNarrixForRecord.js.map +1 -0
- package/dist/narrix/runNarrixForText.d.ts +3 -0
- package/dist/narrix/runNarrixForText.d.ts.map +1 -0
- package/dist/narrix/runNarrixForText.js +49 -0
- package/dist/narrix/runNarrixForText.js.map +1 -0
- package/dist/narrix/runnerDispatch.d.ts +12 -0
- package/dist/narrix/runnerDispatch.d.ts.map +1 -0
- package/dist/narrix/runnerDispatch.js +19 -0
- package/dist/narrix/runnerDispatch.js.map +1 -0
- package/dist/narrix/seedBundleRouting.d.ts +15 -0
- package/dist/narrix/seedBundleRouting.d.ts.map +1 -0
- package/dist/narrix/seedBundleRouting.js +46 -0
- package/dist/narrix/seedBundleRouting.js.map +1 -0
- package/dist/narrix/task.d.ts +4 -0
- package/dist/narrix/task.d.ts.map +1 -0
- package/dist/narrix/task.js +143 -0
- package/dist/narrix/task.js.map +1 -0
- package/dist/narrix/types.d.ts +104 -0
- package/dist/narrix/types.d.ts.map +1 -0
- package/dist/narrix/types.js +3 -0
- package/dist/narrix/types.js.map +1 -0
- package/dist/narrix/webContextMarkdown.d.ts +54 -0
- package/dist/narrix/webContextMarkdown.d.ts.map +1 -0
- package/dist/narrix/webContextMarkdown.js +206 -0
- package/dist/narrix/webContextMarkdown.js.map +1 -0
- package/dist/narrix/webScoper.d.ts +43 -0
- package/dist/narrix/webScoper.d.ts.map +1 -0
- package/dist/narrix/webScoper.js +144 -0
- package/dist/narrix/webScoper.js.map +1 -0
- package/dist/observability/debugTrace.d.ts +31 -0
- package/dist/observability/debugTrace.d.ts.map +1 -0
- package/dist/observability/debugTrace.js +117 -0
- package/dist/observability/debugTrace.js.map +1 -0
- package/dist/observability/extractAiTasksObservability.d.ts +7 -0
- package/dist/observability/extractAiTasksObservability.d.ts.map +1 -0
- package/dist/observability/extractAiTasksObservability.js +98 -0
- package/dist/observability/extractAiTasksObservability.js.map +1 -0
- package/dist/observability/graphExecutionRunLogContract.d.ts +19 -0
- package/dist/observability/graphExecutionRunLogContract.d.ts.map +1 -0
- package/dist/observability/graphExecutionRunLogContract.js +11 -0
- package/dist/observability/graphExecutionRunLogContract.js.map +1 -0
- package/dist/packaged-tasks-client.d.ts +66 -0
- package/dist/packaged-tasks-client.d.ts.map +1 -0
- package/dist/packaged-tasks-client.js +100 -0
- package/dist/packaged-tasks-client.js.map +1 -0
- package/dist/planWebScopeQuestions/index.d.ts +78 -0
- package/dist/planWebScopeQuestions/index.d.ts.map +1 -0
- package/dist/planWebScopeQuestions/index.js +282 -0
- package/dist/planWebScopeQuestions/index.js.map +1 -0
- package/dist/planWebScopeQuestions/runResearchPlanQuestionsFuncx.d.ts +18 -0
- package/dist/planWebScopeQuestions/runResearchPlanQuestionsFuncx.d.ts.map +1 -0
- package/dist/planWebScopeQuestions/runResearchPlanQuestionsFuncx.js +42 -0
- package/dist/planWebScopeQuestions/runResearchPlanQuestionsFuncx.js.map +1 -0
- package/dist/post-steps/audit/loadAuditTemplates.d.ts +72 -0
- package/dist/post-steps/audit/loadAuditTemplates.d.ts.map +1 -0
- package/dist/post-steps/audit/loadAuditTemplates.js +62 -0
- package/dist/post-steps/audit/loadAuditTemplates.js.map +1 -0
- package/dist/post-steps/audit/parseAuditOutput.d.ts +11 -0
- package/dist/post-steps/audit/parseAuditOutput.d.ts.map +1 -0
- package/dist/post-steps/audit/parseAuditOutput.js +50 -0
- package/dist/post-steps/audit/parseAuditOutput.js.map +1 -0
- package/dist/post-steps/audit/runAudit.d.ts +22 -0
- package/dist/post-steps/audit/runAudit.d.ts.map +1 -0
- package/dist/post-steps/audit/runAudit.js +406 -0
- package/dist/post-steps/audit/runAudit.js.map +1 -0
- package/dist/post-steps/audit/runAuditCall.d.ts +23 -0
- package/dist/post-steps/audit/runAuditCall.d.ts.map +1 -0
- package/dist/post-steps/audit/runAuditCall.js +32 -0
- package/dist/post-steps/audit/runAuditCall.js.map +1 -0
- package/dist/post-steps/polish/loadPolishTemplates.d.ts +35 -0
- package/dist/post-steps/polish/loadPolishTemplates.d.ts.map +1 -0
- package/dist/post-steps/polish/loadPolishTemplates.js +38 -0
- package/dist/post-steps/polish/loadPolishTemplates.js.map +1 -0
- package/dist/post-steps/polish/parsePolishOutput.d.ts +6 -0
- package/dist/post-steps/polish/parsePolishOutput.d.ts.map +1 -0
- package/dist/post-steps/polish/parsePolishOutput.js +47 -0
- package/dist/post-steps/polish/parsePolishOutput.js.map +1 -0
- package/dist/post-steps/polish/runPolish.d.ts +24 -0
- package/dist/post-steps/polish/runPolish.d.ts.map +1 -0
- package/dist/post-steps/polish/runPolish.js +147 -0
- package/dist/post-steps/polish/runPolish.js.map +1 -0
- package/dist/post-steps/polish/runPolishCall.d.ts +22 -0
- package/dist/post-steps/polish/runPolishCall.d.ts.map +1 -0
- package/dist/post-steps/polish/runPolishCall.js +32 -0
- package/dist/post-steps/polish/runPolishCall.js.map +1 -0
- package/dist/post-steps/resolvePostStepConfig.d.ts +58 -0
- package/dist/post-steps/resolvePostStepConfig.d.ts.map +1 -0
- package/dist/post-steps/resolvePostStepConfig.js +105 -0
- package/dist/post-steps/resolvePostStepConfig.js.map +1 -0
- package/dist/rendrixUpstreamExports.d.ts +7 -0
- package/dist/rendrixUpstreamExports.d.ts.map +1 -0
- package/dist/rendrixUpstreamExports.js +6 -0
- package/dist/rendrixUpstreamExports.js.map +1 -0
- package/dist/skillCatalogExports.d.ts +8 -0
- package/dist/skillCatalogExports.d.ts.map +1 -0
- package/dist/skillCatalogExports.js +8 -0
- package/dist/skillCatalogExports.js.map +1 -0
- package/dist/strategies/direct-execution-strategy.d.ts +31 -0
- package/dist/strategies/direct-execution-strategy.d.ts.map +1 -0
- package/dist/strategies/direct-execution-strategy.js +107 -0
- package/dist/strategies/direct-execution-strategy.js.map +1 -0
- package/dist/strategies/execution-strategy.interface.d.ts +31 -0
- package/dist/strategies/execution-strategy.interface.d.ts.map +1 -0
- package/dist/strategies/execution-strategy.interface.js +2 -0
- package/dist/strategies/execution-strategy.interface.js.map +1 -0
- package/dist/strategies/index.d.ts +9 -0
- package/dist/strategies/index.d.ts.map +1 -0
- package/dist/strategies/index.js +8 -0
- package/dist/strategies/index.js.map +1 -0
- package/dist/strategies/strategy-factory.d.ts +45 -0
- package/dist/strategies/strategy-factory.d.ts.map +1 -0
- package/dist/strategies/strategy-factory.js +59 -0
- package/dist/strategies/strategy-factory.js.map +1 -0
- package/dist/synthesis/index.d.ts +9 -0
- package/dist/synthesis/index.d.ts.map +1 -0
- package/dist/synthesis/index.js +8 -0
- package/dist/synthesis/index.js.map +1 -0
- package/dist/synthesis/resolveSourceMaterial.d.ts +35 -0
- package/dist/synthesis/resolveSourceMaterial.d.ts.map +1 -0
- package/dist/synthesis/resolveSourceMaterial.js +152 -0
- package/dist/synthesis/resolveSourceMaterial.js.map +1 -0
- package/dist/synthesis/runStructuredSynthesisRobust.d.ts +42 -0
- package/dist/synthesis/runStructuredSynthesisRobust.d.ts.map +1 -0
- package/dist/synthesis/runStructuredSynthesisRobust.js +303 -0
- package/dist/synthesis/runStructuredSynthesisRobust.js.map +1 -0
- package/dist/task-strategies/buildTaskStrategyCatalogDescriptor.d.ts +19 -0
- package/dist/task-strategies/buildTaskStrategyCatalogDescriptor.d.ts.map +1 -0
- package/dist/task-strategies/buildTaskStrategyCatalogDescriptor.js +242 -0
- package/dist/task-strategies/buildTaskStrategyCatalogDescriptor.js.map +1 -0
- package/dist/task-strategies/canonicalInputExecutionStrategies.d.ts +171 -0
- package/dist/task-strategies/canonicalInputExecutionStrategies.d.ts.map +1 -0
- package/dist/task-strategies/canonicalInputExecutionStrategies.js +117 -0
- package/dist/task-strategies/canonicalInputExecutionStrategies.js.map +1 -0
- package/dist/task-strategies/canonicalNarrixModes.d.ts +31 -0
- package/dist/task-strategies/canonicalNarrixModes.d.ts.map +1 -0
- package/dist/task-strategies/canonicalNarrixModes.js +35 -0
- package/dist/task-strategies/canonicalNarrixModes.js.map +1 -0
- package/dist/task-strategies/canonicalTaskStrategies.d.ts +104 -0
- package/dist/task-strategies/canonicalTaskStrategies.d.ts.map +1 -0
- package/dist/task-strategies/canonicalTaskStrategies.js +77 -0
- package/dist/task-strategies/canonicalTaskStrategies.js.map +1 -0
- package/dist/task-strategies/cataloxCatalogViews.d.ts +55 -0
- package/dist/task-strategies/cataloxCatalogViews.d.ts.map +1 -0
- package/dist/task-strategies/cataloxCatalogViews.js +65 -0
- package/dist/task-strategies/cataloxCatalogViews.js.map +1 -0
- package/dist/task-strategies/constants.d.ts +49 -0
- package/dist/task-strategies/constants.d.ts.map +1 -0
- package/dist/task-strategies/constants.js +49 -0
- package/dist/task-strategies/constants.js.map +1 -0
- package/dist/task-strategies/index.d.ts +22 -0
- package/dist/task-strategies/index.d.ts.map +1 -0
- package/dist/task-strategies/index.js +13 -0
- package/dist/task-strategies/index.js.map +1 -0
- package/dist/task-strategies/listAiTaskStrategies.d.ts +43 -0
- package/dist/task-strategies/listAiTaskStrategies.d.ts.map +1 -0
- package/dist/task-strategies/listAiTaskStrategies.js +74 -0
- package/dist/task-strategies/listAiTaskStrategies.js.map +1 -0
- package/dist/task-strategies/normalize.d.ts +7 -0
- package/dist/task-strategies/normalize.d.ts.map +1 -0
- package/dist/task-strategies/normalize.js +44 -0
- package/dist/task-strategies/normalize.js.map +1 -0
- package/dist/task-strategies/types.d.ts +37 -0
- package/dist/task-strategies/types.d.ts.map +1 -0
- package/dist/task-strategies/types.js +2 -0
- package/dist/task-strategies/types.js.map +1 -0
- package/dist/types/decision-contracts.d.ts +31 -0
- package/dist/types/decision-contracts.d.ts.map +1 -0
- package/dist/types/decision-contracts.js +23 -0
- package/dist/types/decision-contracts.js.map +1 -0
- package/dist/types/evidence-types.d.ts +108 -0
- package/dist/types/evidence-types.d.ts.map +1 -0
- package/dist/types/evidence-types.js +9 -0
- package/dist/types/evidence-types.js.map +1 -0
- package/dist/types/executionType.d.ts +9 -0
- package/dist/types/executionType.d.ts.map +1 -0
- package/dist/types/executionType.js +8 -0
- package/dist/types/executionType.js.map +1 -0
- package/dist/types/index.d.ts +28 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +12 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/llmCall.d.ts +121 -0
- package/dist/types/llmCall.d.ts.map +1 -0
- package/dist/types/llmCall.js +39 -0
- package/dist/types/llmCall.js.map +1 -0
- package/dist/types/task-configuration.d.ts +60 -0
- package/dist/types/task-configuration.d.ts.map +1 -0
- package/dist/types/task-configuration.js +3 -0
- package/dist/types/task-configuration.js.map +1 -0
- package/dist/types/task-types.d.ts +887 -0
- package/dist/types/task-types.d.ts.map +1 -0
- package/dist/types/task-types.js +21 -0
- package/dist/types/task-types.js.map +1 -0
- package/dist/utilities/runUtility.d.ts +3 -0
- package/dist/utilities/runUtility.d.ts.map +1 -0
- package/dist/utilities/runUtility.js +204 -0
- package/dist/utilities/runUtility.js.map +1 -0
- package/dist/utils/assertRequiredRunSkillCorrelation.d.ts +7 -0
- package/dist/utils/assertRequiredRunSkillCorrelation.d.ts.map +1 -0
- package/dist/utils/assertRequiredRunSkillCorrelation.js +17 -0
- package/dist/utils/assertRequiredRunSkillCorrelation.js.map +1 -0
- package/dist/utils/assertValidSmartInputConfig.d.ts +5 -0
- package/dist/utils/assertValidSmartInputConfig.d.ts.map +1 -0
- package/dist/utils/assertValidSmartInputConfig.js +71 -0
- package/dist/utils/assertValidSmartInputConfig.js.map +1 -0
- package/dist/utils/bridgeRunSkillGatewayMemory.d.ts +13 -0
- package/dist/utils/bridgeRunSkillGatewayMemory.d.ts.map +1 -0
- package/dist/utils/bridgeRunSkillGatewayMemory.js +65 -0
- package/dist/utils/bridgeRunSkillGatewayMemory.js.map +1 -0
- package/dist/utils/extractSmartInputRenderResult.d.ts +7 -0
- package/dist/utils/extractSmartInputRenderResult.d.ts.map +1 -0
- package/dist/utils/extractSmartInputRenderResult.js +30 -0
- package/dist/utils/extractSmartInputRenderResult.js.map +1 -0
- package/dist/utils/jsonPaths.d.ts +6 -0
- package/dist/utils/jsonPaths.d.ts.map +1 -0
- package/dist/utils/jsonPaths.js +32 -0
- package/dist/utils/jsonPaths.js.map +1 -0
- package/dist/utils/normalizeSmartInputConfig.d.ts +5 -0
- package/dist/utils/normalizeSmartInputConfig.d.ts.map +1 -0
- package/dist/utils/normalizeSmartInputConfig.js +30 -0
- package/dist/utils/normalizeSmartInputConfig.js.map +1 -0
- package/dist/utils/outputValidation.d.ts +19 -0
- package/dist/utils/outputValidation.d.ts.map +1 -0
- package/dist/utils/outputValidation.js +75 -0
- package/dist/utils/outputValidation.js.map +1 -0
- package/dist/utils/runTaskRequestShape.d.ts +16 -0
- package/dist/utils/runTaskRequestShape.d.ts.map +1 -0
- package/dist/utils/runTaskRequestShape.js +80 -0
- package/dist/utils/runTaskRequestShape.js.map +1 -0
- package/dist/utils/skillTemplateVariables.d.ts +20 -0
- package/dist/utils/skillTemplateVariables.d.ts.map +1 -0
- package/dist/utils/skillTemplateVariables.js +63 -0
- package/dist/utils/skillTemplateVariables.js.map +1 -0
- package/dist/utils/xynthesizedSmartInputPaths.d.ts +16 -0
- package/dist/utils/xynthesizedSmartInputPaths.d.ts.map +1 -0
- package/dist/utils/xynthesizedSmartInputPaths.js +56 -0
- package/dist/utils/xynthesizedSmartInputPaths.js.map +1 -0
- package/dist/utils/xynthesizedWrite.d.ts +10 -0
- package/dist/utils/xynthesizedWrite.d.ts.map +1 -0
- package/dist/utils/xynthesizedWrite.js +61 -0
- package/dist/utils/xynthesizedWrite.js.map +1 -0
- package/dist/validation/analyzeExpectedRunTaskInput.d.ts +41 -0
- package/dist/validation/analyzeExpectedRunTaskInput.d.ts.map +1 -0
- package/dist/validation/analyzeExpectedRunTaskInput.js +133 -0
- package/dist/validation/analyzeExpectedRunTaskInput.js.map +1 -0
- package/dist/validation/collectSmartInputValidationIssues.d.ts +6 -0
- package/dist/validation/collectSmartInputValidationIssues.d.ts.map +1 -0
- package/dist/validation/collectSmartInputValidationIssues.js +38 -0
- package/dist/validation/collectSmartInputValidationIssues.js.map +1 -0
- package/dist/validation/helpers.d.ts +15 -0
- package/dist/validation/helpers.d.ts.map +1 -0
- package/dist/validation/helpers.js +184 -0
- package/dist/validation/helpers.js.map +1 -0
- package/dist/validation/index.d.ts +9 -0
- package/dist/validation/index.d.ts.map +1 -0
- package/dist/validation/index.js +6 -0
- package/dist/validation/index.js.map +1 -0
- package/dist/validation/types.d.ts +51 -0
- package/dist/validation/types.d.ts.map +1 -0
- package/dist/validation/types.js +5 -0
- package/dist/validation/types.js.map +1 -0
- package/dist/validation/validateRunTaskConfig.d.ts +8 -0
- package/dist/validation/validateRunTaskConfig.d.ts.map +1 -0
- package/dist/validation/validateRunTaskConfig.js +158 -0
- package/dist/validation/validateRunTaskConfig.js.map +1 -0
- package/dist/validation/validateRunTaskInvoke.d.ts +30 -0
- package/dist/validation/validateRunTaskInvoke.d.ts.map +1 -0
- package/dist/validation/validateRunTaskInvoke.js +108 -0
- package/dist/validation/validateRunTaskInvoke.js.map +1 -0
- package/documenations/activix-feature-request-identity.md +123 -0
- package/documenations/activix.md +175 -0
- package/documenations/bug-report-xynthesis-and-synthesis-call.md +217 -0
- package/documenations/core-runtime-tokens-and-strategies.md +123 -0
- package/documenations/downstream-environment.md +48 -0
- package/documenations/downstream-test-runtime-teardown-cleanup.md +73 -0
- package/documenations/examples/xynthesis-run-task-request.example.json +170 -0
- package/documenations/feature-request-ai-skills-raw-template-access.md +82 -0
- package/documenations/feature-request-athenix-core-directive.md +145 -0
- package/documenations/feature-request-athenix-token-extraction.md +124 -0
- package/documenations/funcx-catalog-hosting-checklist.md +107 -0
- package/documenations/funcx-scoping-integration-gaps.md +120 -0
- package/documenations/funcx-upstream-github-issues-draft.md +153 -0
- package/documenations/identity-metadata-contract.md +165 -0
- package/documenations/intermediate-steps.md +33 -0
- package/documenations/record-and-template-variables.md +32 -0
- package/documenations/run-task-execution-flow.md +153 -0
- package/documenations/run-task-single-run-checklist.md +109 -0
- package/documenations/schemas/README.md +40 -0
- package/documenations/schemas/openapi-3.1-components.yaml +24 -0
- package/documenations/schemas/v1/output-schema.json +55 -0
- package/documenations/schemas/v1/output-validation-result.json +41 -0
- package/documenations/schemas/v1/run-task-request.json +219 -0
- package/documenations/schemas/v1/synthesized-artifacts.json +133 -0
- package/documenations/synthesis-invocation-notes.md +26 -0
- package/documenations/synthesized-context-guide.md +84 -0
- package/documenations/task-core-and-core-aware-synthesis.md +58 -0
- package/documenations/upstream-feature-requests/ai-skills-llm-observability.md +129 -0
- package/documenations/upstream-feature-requests/xynthesis-llm-observability.md +125 -0
- package/documenations/upstream-feedback-request-shape-clarification.md +101 -0
- package/documenations/web-context-precedence.md +33 -0
- package/documenations/web-scoping-in-ai-tasks.md +503 -0
- package/documenations/xynthesis-activix-telemetry.md +28 -0
- package/documenations/xynthesis-upstream-fixes-checklist.md +71 -0
- package/package.json +92 -0
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# Template Core and Core-Aware Synthesis
|
|
2
|
+
|
|
3
|
+
This guide documents template-declared core semantics in `@exellix/ai-tasks` and how they work with PRE `synthesized-context`.
|
|
4
|
+
|
|
5
|
+
## Template core tokens
|
|
6
|
+
|
|
7
|
+
Templates declare one or more core directives (Athenix `{{core:...}}` format) describing task shape:
|
|
8
|
+
|
|
9
|
+
- `question`
|
|
10
|
+
- `action`
|
|
11
|
+
- `plan`
|
|
12
|
+
- `objective`
|
|
13
|
+
- `decision`
|
|
14
|
+
- `comparison`
|
|
15
|
+
- `classification`
|
|
16
|
+
- `evaluation`
|
|
17
|
+
- `analysis`
|
|
18
|
+
- `summary`
|
|
19
|
+
- `generation`
|
|
20
|
+
- `extraction`
|
|
21
|
+
|
|
22
|
+
Rules:
|
|
23
|
+
|
|
24
|
+
- one or more cores per template are valid
|
|
25
|
+
- closed list by default
|
|
26
|
+
- domain-agnostic (not tied to security/ecommerce/etc.)
|
|
27
|
+
- required when structured synthesis mode is selected (no cores => synthesis-blocking template error)
|
|
28
|
+
- request-level `taskCore` is not used; template declarations are the only synthesis source of truth
|
|
29
|
+
- discovery is pre-render from raw template content (resolved via `ai-skills.resolveRawTemplate(...)`)
|
|
30
|
+
|
|
31
|
+
## Synthesis modes
|
|
32
|
+
|
|
33
|
+
`synthesized-context` supports two additive modes:
|
|
34
|
+
|
|
35
|
+
- `markdown`: existing markdown synthesis behavior
|
|
36
|
+
- `structured`: core-aware synthesis returning validated structured payload, then converted to deterministic markdown for MAIN context
|
|
37
|
+
|
|
38
|
+
Mode fields:
|
|
39
|
+
|
|
40
|
+
- preferred: `SynthesisConfig.synthesisMode`
|
|
41
|
+
- legacy-compatible: `SynthesisConfig.synthesisOutputFormat`
|
|
42
|
+
|
|
43
|
+
When both are set, `synthesisMode` is used first.
|
|
44
|
+
|
|
45
|
+
## Runtime layering
|
|
46
|
+
|
|
47
|
+
- raw and enriched artifacts remain available in memory (`_narrix`, scoped memory, `webContext`)
|
|
48
|
+
- structured synthesis artifact is persisted in `executionMemory.synthesizedContext`
|
|
49
|
+
- final MAIN prompt context uses synthesized output when PRE synthesis override is active
|
|
50
|
+
|
|
51
|
+
This keeps debugging traceability while keeping final model prompts concise.
|
|
52
|
+
|
|
53
|
+
## ai-gateway boundary
|
|
54
|
+
|
|
55
|
+
- `ai-tasks`: orchestration, runtime flow, contracts, compatibility
|
|
56
|
+
- `ai-gateway`: model invocation for synthesis
|
|
57
|
+
|
|
58
|
+
This keeps package roles aligned with existing architecture.
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
# `@exellix/ai-skills` — LLM observability + dynamic budgeting feature requests
|
|
2
|
+
|
|
3
|
+
Status: open
|
|
4
|
+
Owner: `@exellix/ai-skills`
|
|
5
|
+
Filed by: `@exellix/ai-tasks` (5.6+)
|
|
6
|
+
Tracked here: [`documenations/upstream-feature-requests/ai-skills-llm-observability.md`](.)
|
|
7
|
+
|
|
8
|
+
This document captures the gaps that remain in `@exellix/ai-skills` ≥ 5.0 after `@exellix/ai-tasks` adopted the upstream LLM observability primitives (`SkillExecutionTraceError`, `RunSkillDiagnostics`, `SkillDiagnosticsTrace`, `mapGatewayInvokeToTrace`, `traceToDiagnostics`, `usageFromGatewayMetadata`, `metadataFromInvokeError`).
|
|
9
|
+
|
|
10
|
+
The big-ticket items are mostly already shipped — what remains is small but high-value for parity with `@exellix/xynthesis` 3.1+.
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## 1. Typed error in **default mode** (non-trace) — required for parity with xynthesis
|
|
15
|
+
|
|
16
|
+
### Today
|
|
17
|
+
|
|
18
|
+
- `executionMode: "trace"` causes `runSkill` to throw `SkillExecutionTraceError` carrying `RunSkillDiagnostics` (`trace.ok === false`, `trace.invokeRequest`, error envelope, gateway/error metadata).
|
|
19
|
+
- **Outside** trace mode, raw underlying errors are thrown — typically a generic `Error` with the provider/gateway message and no structured payload.
|
|
20
|
+
|
|
21
|
+
### Why it hurts
|
|
22
|
+
|
|
23
|
+
`@exellix/ai-tasks` is forced to wrap every non-trace MAIN skill failure in its own `LlmCallContextError` to preserve a snapshot of the request (`modelConfig`, `timeoutMs`, `outputExpectation`). That snapshot is necessarily incomplete — we don't see the gateway-level usage / routing / cost / attempts that the upstream had right there in scope.
|
|
24
|
+
|
|
25
|
+
### Asked behavior
|
|
26
|
+
|
|
27
|
+
Throw a `SkillExecutionError` (typed class, **always** thrown — not gated on `executionMode`) that carries:
|
|
28
|
+
|
|
29
|
+
- `request: { modelConfig, timeoutMs }` — verbatim echo of what we sent.
|
|
30
|
+
- `errorEnvelope: { name, message, code?, providerStatus?, providerCode? }`.
|
|
31
|
+
- `partialDiagnostics?: Partial<RunSkillDiagnostics>` — whatever the call site managed to assemble before throwing (usage, routing, attempts so far). Empty / undefined is acceptable when we have nothing.
|
|
32
|
+
- `cause: unknown` — the original error.
|
|
33
|
+
|
|
34
|
+
`SkillExecutionTraceError` would still be the trace-only variant carrying the FULL `RunSkillDiagnostics`, and would extend `SkillExecutionError`.
|
|
35
|
+
|
|
36
|
+
### Acceptance
|
|
37
|
+
|
|
38
|
+
- `instanceof SkillExecutionError` is true for any failure thrown by `runSkill` (trace and non-trace).
|
|
39
|
+
- `instanceof SkillExecutionTraceError` is true only in trace mode and is also a `SkillExecutionError` (via `extends`).
|
|
40
|
+
- Existing trace-mode callers keep working unchanged.
|
|
41
|
+
- Default-mode callers gain the structured payload without flipping the global trace flag.
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## 2. `outputExpectation` passthrough on `RunSkillRequest` (when ai-skills adopts xynthesis-style automation)
|
|
46
|
+
|
|
47
|
+
### Today
|
|
48
|
+
|
|
49
|
+
`runSkill` accepts a `modelConfig.maxTokens` value and forwards it directly to the AI gateway. There is **no auto-sizer** — callers must pick a number themselves or accept the gateway / provider default.
|
|
50
|
+
|
|
51
|
+
`@exellix/xynthesis` 3.1+ ships `resolveMaxTokens(input)` (`{ inputText, outputExpectation, modelId, callerMaxTokens?, structuredOutput? }`) plus `MODEL_CAPABILITIES` and `ACTION_OUTPUT_DEFAULTS` registries. `@exellix/ai-tasks` already calls this helper for every xynthesis-backed call (PRE / POST / scoping / utility).
|
|
52
|
+
|
|
53
|
+
### Why it hurts
|
|
54
|
+
|
|
55
|
+
The MAIN skill is the only LLM call in the task pipeline that bypasses the auto-sizer. Callers either set `modelConfig.maxTokens` to a hard number (loses dynamic adjustment per-input-size) or omit it (gets whatever the gateway / provider does by default — typically very generous).
|
|
56
|
+
|
|
57
|
+
### Asked behavior
|
|
58
|
+
|
|
59
|
+
1. Accept a top-level **optional** `outputExpectation: OutputExpectation` on `RunSkillRequest` (re-exporting the type from `@exellix/xynthesis` is fine — it's already a transitive dep via `xynthesis`).
|
|
60
|
+
2. When `outputExpectation` is provided AND `modelConfig.maxTokens` is omitted, internally call `xynthesis.resolveMaxTokens` to compute the cap before invoking the gateway.
|
|
61
|
+
3. When `modelConfig.maxTokens` is provided, treat it as a HARD CEILING (`callerMaxTokens` in xynthesis terms) and STILL run the auto-sizer to pick something smaller when appropriate.
|
|
62
|
+
4. Echo the resolved cap on `RunSkillResponse.diagnostics.trace.invokeRequest` (alongside `modelConfig` / `timeoutMs`).
|
|
63
|
+
5. Lift the resolution result onto `RunSkillResponse.diagnostics.trace.tokenResolution: MaxTokensResolution` for trace consumers.
|
|
64
|
+
|
|
65
|
+
### Acceptance
|
|
66
|
+
|
|
67
|
+
- Pre-existing callers that set `modelConfig.maxTokens` continue working unchanged (the auto-sizer never picks larger).
|
|
68
|
+
- New callers that set only `outputExpectation` get sensible auto-sized caps without picking a number.
|
|
69
|
+
- `result.diagnostics.trace.tokenResolution.reason` is one of `"computed" | "caller-override" | "model-ceiling" | "fallback"` and explains the choice.
|
|
70
|
+
|
|
71
|
+
---
|
|
72
|
+
|
|
73
|
+
## 3. Surface `invokeRequest` echo in non-trace `result.diagnostics`
|
|
74
|
+
|
|
75
|
+
### Today
|
|
76
|
+
|
|
77
|
+
`RunSkillResponse.diagnostics?: RunSkillDiagnostics` is opt-in via `executionMode: "trace"` (or `diagnostics: { includeDebugTrace: true }`). The `trace.invokeRequest` field (`{ modelConfig, timeoutMs }`) is therefore trace-only.
|
|
78
|
+
|
|
79
|
+
### Why it hurts
|
|
80
|
+
|
|
81
|
+
For routine cost/usage observability (no debug trace, no raw provider payload), callers want to see what was actually sent (resolved model id, `maxTokens`, `temperature`, `topP`, `stop`, …) without the overhead of full trace mode. Today they have to flip trace mode on for everything just to get the request echo.
|
|
82
|
+
|
|
83
|
+
### Asked behavior
|
|
84
|
+
|
|
85
|
+
Add a lightweight `diagnostics: { includeInvokeRequestEcho?: boolean }` opt-in that returns:
|
|
86
|
+
|
|
87
|
+
```typescript
|
|
88
|
+
result.diagnostics = {
|
|
89
|
+
invokeRequest: { modelConfig, timeoutMs },
|
|
90
|
+
// (no trace, no rawProviderPayload, no attempts[])
|
|
91
|
+
};
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Cheap to populate (we have it in scope) and answers most "what did we actually send?" questions.
|
|
95
|
+
|
|
96
|
+
### Acceptance
|
|
97
|
+
|
|
98
|
+
- `includeInvokeRequestEcho: true` returns `result.diagnostics.invokeRequest` without forcing full trace mode.
|
|
99
|
+
- `executionMode: "trace"` continues to return the FULL `RunSkillDiagnostics` (superset).
|
|
100
|
+
|
|
101
|
+
---
|
|
102
|
+
|
|
103
|
+
## 4. Optional: `onLlmCall(invokeSummary)` hook on `runSkill`
|
|
104
|
+
|
|
105
|
+
Mirror the request being filed against `@exellix/xynthesis` 3.x — a single per-call observation hook callers can subscribe to without parsing `RunSkillResponse.diagnostics`. Useful for cost / usage telemetry sinks.
|
|
106
|
+
|
|
107
|
+
### Asked behavior
|
|
108
|
+
|
|
109
|
+
```typescript
|
|
110
|
+
runSkill({
|
|
111
|
+
...,
|
|
112
|
+
onLlmCall: (summary: InvokeSummary) => void, // fire-and-forget; thrown errors swallowed
|
|
113
|
+
});
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
Where `InvokeSummary` is whatever ai-skills already builds internally (analogous to xynthesis `InvokeAttemptSummary`).
|
|
117
|
+
|
|
118
|
+
### Acceptance
|
|
119
|
+
|
|
120
|
+
- Hook is invoked exactly once per terminal LLM attempt (success or failure) with `{ modelRequested, modelResolved, maxTokensFromCaller, maxTokensEffective, usage, routing, costUsd, errorEnvelope? }`.
|
|
121
|
+
- Hook errors do not affect the call's outcome.
|
|
122
|
+
|
|
123
|
+
---
|
|
124
|
+
|
|
125
|
+
## Cross-references
|
|
126
|
+
|
|
127
|
+
- xynthesis equivalents already shipped — see `documenations/upstream-feature-requests/xynthesis-llm-observability.md` for the residual xynthesis gaps.
|
|
128
|
+
- ai-tasks integration: `src/strategies/direct-execution-strategy.ts` (the only call site that goes through `runSkill`) currently wraps non-trace errors in `LlmCallContextError`. That wrapping becomes redundant once #1 ships.
|
|
129
|
+
- ai-tasks integration: `src/types/llmCall.ts` re-exports `SkillExecutionTraceError` so callers don't depend on `@exellix/ai-skills` directly. A new `SkillExecutionError` (item #1) would be added to that re-export.
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
# `@exellix/xynthesis` — LLM observability + invoker knob feature requests
|
|
2
|
+
|
|
3
|
+
Status: open
|
|
4
|
+
Owner: `@exellix/xynthesis`
|
|
5
|
+
Filed by: `@exellix/ai-tasks` (5.6+)
|
|
6
|
+
Tracked here: [`documenations/upstream-feature-requests/xynthesis-llm-observability.md`](.)
|
|
7
|
+
|
|
8
|
+
This document captures the gaps that remain in `@exellix/xynthesis` ≥ 3.1 after `@exellix/ai-tasks` adopted `resolveMaxTokens`, `MODEL_CAPABILITIES`, `ACTION_OUTPUT_DEFAULTS`, `runSynthesisCall.invokeSummary`, `runSynthesisCall.executionMode: "trace"`, `XynthesisInvokeError`, `XynthesisResponseParseError`, and `runStructuredSynthesisGatewayCall(outputExpectation, executionMode)`.
|
|
9
|
+
|
|
10
|
+
The big-ticket items are mostly already shipped — what remains is a handful of small ergonomics fixes.
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## 1. Accept `temperature` and `topP` on `RunSynthesisCallOpts` and `SynthesisInvokerOptions`
|
|
15
|
+
|
|
16
|
+
### Today
|
|
17
|
+
|
|
18
|
+
`RunSynthesisCallOpts` accepts `model`, `maxTokens`, `timeoutMs`, `maxOutputLength`, `tokenResolutionMetadata`, `executionMode` — but NOT `temperature` or `topP`. The same is true for `SynthesisInvokerOptions` (the lower-level invoker contract).
|
|
19
|
+
|
|
20
|
+
### Why it hurts
|
|
21
|
+
|
|
22
|
+
`@exellix/ai-tasks` exposes a unified `LlmCallConfig` that includes `temperature` and `topP` for every stage (PRE / MAIN / POST / scoping / utility). Today these knobs are honored end-to-end ONLY for the MAIN skill (which goes through `@exellix/ai-skills` `ModelConfig`). For PRE synthesis / POST audit / POST polish / scoping / `runXynthesisFinalize`, the values are accepted on the ai-tasks surface but DROPPED before the invoker sees them — because xynthesis has nowhere to put them.
|
|
23
|
+
|
|
24
|
+
### Asked behavior
|
|
25
|
+
|
|
26
|
+
Add optional `temperature?: number` and `topP?: number` fields to:
|
|
27
|
+
|
|
28
|
+
- `RunSynthesisCallOpts` (in `runSynthesisCall.ts`).
|
|
29
|
+
- `RunStructuredSynthesisParams` (in `contextSynthesizer.ts`) — already accepts `outputExpectation`, just needs these two.
|
|
30
|
+
- `RunXynthesisFinalizeExecConfig` (in `finalize.ts`).
|
|
31
|
+
- `SynthesisInvokerOptions` (in `invoker.ts`).
|
|
32
|
+
|
|
33
|
+
Forward both to the underlying provider invoker (`AIFunctionsInvoker` / `AIGateway`). Out-of-band defaults: leave undefined (let provider pick). Don't enforce ranges (provider already does).
|
|
34
|
+
|
|
35
|
+
### Acceptance
|
|
36
|
+
|
|
37
|
+
- `runSynthesisCall({ ..., temperature: 0.4, topP: 0.9 })` honors both.
|
|
38
|
+
- Existing callers that don't set them continue working unchanged.
|
|
39
|
+
- `result.invokeSummary.executionMetadata` echoes the values that were actually sent (helps debugging).
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## 2. Accept `outputExpectation` on `RunSynthesisCallOpts` (today only on `RunStructuredSynthesisParams`)
|
|
44
|
+
|
|
45
|
+
### Today
|
|
46
|
+
|
|
47
|
+
`runSynthesisCall(opts)` does NOT accept `outputExpectation`. Callers must:
|
|
48
|
+
|
|
49
|
+
1. Manually call `resolveMaxTokens({ inputText, outputExpectation, modelId, callerMaxTokens })` themselves.
|
|
50
|
+
2. Forward the resolved `maxTokens` AND build `tokenResolutionMetadata` for telemetry.
|
|
51
|
+
|
|
52
|
+
`RunStructuredSynthesisParams` (used by `runStructuredSynthesisGatewayCall`) already accepts `outputExpectation` — the gap is on the simpler `runSynthesisCall` path.
|
|
53
|
+
|
|
54
|
+
### Why it hurts
|
|
55
|
+
|
|
56
|
+
Every xynthesis-backed call site in `@exellix/ai-tasks` (5+ today) repeats the same pre-call dance via the `resolveLlmCallForXynthesis` helper. Bug-prone (it's easy to forget the `tokenResolutionMetadata` echo) and a barrier to entry for new call sites.
|
|
57
|
+
|
|
58
|
+
### Asked behavior
|
|
59
|
+
|
|
60
|
+
Accept optional `outputExpectation?: OutputExpectation` on `RunSynthesisCallOpts`. When set AND `maxTokens` is omitted:
|
|
61
|
+
|
|
62
|
+
1. Internally call `resolveMaxTokens({ inputText, outputExpectation, modelId, callerMaxTokens: opts.maxTokens })` — `inputText` is `(systemPrompt + userPrompt)` (xynthesis already concatenates these).
|
|
63
|
+
2. Use the resolved `maxTokens`.
|
|
64
|
+
3. Build the `tokenResolutionMetadata` for the invoker telemetry.
|
|
65
|
+
|
|
66
|
+
When `maxTokens` is explicitly set, treat it as a HARD CEILING (`callerMaxTokens` in `resolveMaxTokens` terms) and STILL run the auto-sizer to pick something smaller when appropriate. (This is consistent with how `resolveMaxTokens` already behaves.)
|
|
67
|
+
|
|
68
|
+
### Acceptance
|
|
69
|
+
|
|
70
|
+
- `runSynthesisCall({ ..., outputExpectation })` works with no extra setup; `maxTokens` is auto-resolved.
|
|
71
|
+
- `runSynthesisCall({ ..., outputExpectation, maxTokens })` keeps the cap as a ceiling.
|
|
72
|
+
- `result.invokeSummary.maxTokensFromCaller` and `result.invokeSummary.maxTokensEffective` reflect the right values.
|
|
73
|
+
- Existing callers that pre-resolve `maxTokens` themselves continue working unchanged.
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## 3. Extend `runXynthesisFinalize` `out.diagnostics` to include `invokeSummary`
|
|
78
|
+
|
|
79
|
+
### Today
|
|
80
|
+
|
|
81
|
+
`runXynthesisFinalize(input, exec)` returns `{ parsed, debugTrace?, diagnostics? }`. The `diagnostics` object today carries gateway-level metadata (`renderedTemplateContext`, `outputContractVersion`, etc.) but does NOT include the equivalent of `RunSynthesisResult.invokeSummary` (the always-present per-call `InvokeAttemptSummary` with usage / routing / cost / model echo).
|
|
82
|
+
|
|
83
|
+
### Why it hurts
|
|
84
|
+
|
|
85
|
+
`@exellix/ai-tasks` `runUtility` (xynthesis-finalize utility) records per-attempt observations and tries to lift `invokeSummary` from the result on success — but there's nothing there. Today we record a partial observation built from the request snapshot only. On failure we DO get it (via `XynthesisInvokeError.invokeSummary`); the asymmetry is awkward.
|
|
86
|
+
|
|
87
|
+
### Asked behavior
|
|
88
|
+
|
|
89
|
+
Add `out.diagnostics.invokeSummary?: InvokeAttemptSummary` (always populated on success; mirroring `runSynthesisCall.invokeSummary`). For multi-attempt internal repair flows, an array `out.diagnostics.invokeSummaries?: InvokeAttemptSummary[]` would be even better; otherwise just the terminal one suffices.
|
|
90
|
+
|
|
91
|
+
### Acceptance
|
|
92
|
+
|
|
93
|
+
- `runXynthesisFinalize` returns `out.diagnostics.invokeSummary` on every successful call.
|
|
94
|
+
- Schema unchanged for failure paths (still throw `XynthesisInvokeError` / `XynthesisResponseParseError` with `invokeSummary`).
|
|
95
|
+
|
|
96
|
+
---
|
|
97
|
+
|
|
98
|
+
## 4. Optional: `onLlmCall(summary)` hook on `runSynthesisCall` / `runXynthesisFinalize`
|
|
99
|
+
|
|
100
|
+
A single per-call observation hook callers can subscribe to without parsing `result.invokeSummary` / `result.debugTrace`. Useful for cost / usage telemetry sinks that don't want to wrap every call site.
|
|
101
|
+
|
|
102
|
+
### Asked behavior
|
|
103
|
+
|
|
104
|
+
```typescript
|
|
105
|
+
runSynthesisCall({
|
|
106
|
+
...,
|
|
107
|
+
onLlmCall: (summary: InvokeAttemptSummary) => void, // fire-and-forget; thrown errors swallowed
|
|
108
|
+
});
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
Same shape as the corresponding `@exellix/ai-skills` hook request (see `documenations/upstream-feature-requests/ai-skills-llm-observability.md`).
|
|
112
|
+
|
|
113
|
+
### Acceptance
|
|
114
|
+
|
|
115
|
+
- Hook fires exactly once per terminal LLM attempt (success or failure).
|
|
116
|
+
- Hook errors do not affect the call's outcome.
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## Cross-references
|
|
121
|
+
|
|
122
|
+
- ai-skills equivalents — see `documenations/upstream-feature-requests/ai-skills-llm-observability.md`.
|
|
123
|
+
- ai-tasks integration: `src/internal/runPostStepLlmCall.ts` (the central wrapper) currently runs the auto-sizer manually via `src/internal/resolveLlmCallForXynthesis.ts`. Items #1 and #2 would let that helper shrink to a thin pass-through.
|
|
124
|
+
- ai-tasks integration: `src/utilities/runUtility.ts` records a placeholder `invokeSummary` on success today. Item #3 would let it record the real one.
|
|
125
|
+
- ai-tasks integration: `src/types/llmCall.ts` re-exports `XynthesisInvokeError`, `XynthesisResponseParseError`, `InvokeAttemptSummary`, `MaxTokensResolution`, `OutputExpectation` so callers don't depend on `@exellix/xynthesis` directly.
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
# Upstream Feedback Response: `runTask` Request Shape and Runtime Model
|
|
2
|
+
|
|
3
|
+
## Context
|
|
4
|
+
|
|
5
|
+
Feedback received:
|
|
6
|
+
|
|
7
|
+
> The `runTask` request still looks old-shaped.
|
|
8
|
+
> In all 3 request files, top-level shape is still basically:
|
|
9
|
+
> `question`, `record`, `inputs`, `narrix`, `executionMemory`, `variables`.
|
|
10
|
+
> I do not see new explicit runtime concepts reflected in request shape:
|
|
11
|
+
> - no `taskCore`
|
|
12
|
+
> - no detected template core set
|
|
13
|
+
> - no `synthesizedContext` being carried into MAIN
|
|
14
|
+
> - no sign that template analysis is driving execution
|
|
15
|
+
>
|
|
16
|
+
> So request contract still looks like old model.
|
|
17
|
+
|
|
18
|
+
This document is the formal response and clarification.
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## Short Answer
|
|
23
|
+
|
|
24
|
+
The request contract is **intentionally minimal and mostly unchanged at top-level**.
|
|
25
|
+
The new model is a **runtime-orchestration contract**, not a request-field expansion.
|
|
26
|
+
|
|
27
|
+
So the absence of new top-level fields is expected and correct.
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## What Changed (and Why It May Not Appear in Request Shape)
|
|
32
|
+
|
|
33
|
+
### 1) `taskCore` removed from request (intentional)
|
|
34
|
+
|
|
35
|
+
- The old request-level `taskCore` is removed as source of truth.
|
|
36
|
+
- Runtime now derives task semantics from template declarations.
|
|
37
|
+
- This is a deliberate shift away from user-supplied task core metadata.
|
|
38
|
+
|
|
39
|
+
### 2) Core detection is runtime-derived, not caller-supplied
|
|
40
|
+
|
|
41
|
+
- `templateCores` are discovered pre-render from raw instructions/prompt templates.
|
|
42
|
+
- Discovery is done by runtime internals (not by request payload).
|
|
43
|
+
- Therefore `templateCores` does not need to be added as request input.
|
|
44
|
+
|
|
45
|
+
### 3) `synthesizedContext` is execution memory artifact, not request input
|
|
46
|
+
|
|
47
|
+
- In structured synthesis mode, runtime writes synthesized artifact to:
|
|
48
|
+
- `executionMemory.synthesizedContext`
|
|
49
|
+
- This is generated during PRE step and then consumed by MAIN flow.
|
|
50
|
+
- It is intentionally a runtime-produced artifact, not a required top-level request field.
|
|
51
|
+
|
|
52
|
+
### 4) Template analysis drives execution internally
|
|
53
|
+
|
|
54
|
+
- The execution decision path (for structured synthesis) is:
|
|
55
|
+
1. resolve raw templates,
|
|
56
|
+
2. detect `{{core:...}}` directives,
|
|
57
|
+
3. validate non-empty detected core set,
|
|
58
|
+
4. run structured synthesis with detected cores + resolved question,
|
|
59
|
+
5. materialize main context markdown and continue MAIN execution.
|
|
60
|
+
- This orchestration is runtime behavior and does not require top-level request shape changes.
|
|
61
|
+
|
|
62
|
+
---
|
|
63
|
+
|
|
64
|
+
## Why Keeping Request Shape Stable Is Correct
|
|
65
|
+
|
|
66
|
+
- Backward compatibility for callers that already send existing fields.
|
|
67
|
+
- Avoids duplicating runtime-derived data in user input.
|
|
68
|
+
- Prevents conflicting sources of truth (caller-provided core vs template-declared core).
|
|
69
|
+
- Keeps request API focused on inputs/config, while runtime computes orchestration artifacts.
|
|
70
|
+
|
|
71
|
+
---
|
|
72
|
+
|
|
73
|
+
## Explicit Clarification to Upstream
|
|
74
|
+
|
|
75
|
+
Please do **not** interpret the unchanged top-level request shape as "old model still active".
|
|
76
|
+
|
|
77
|
+
The new model is active through runtime semantics:
|
|
78
|
+
|
|
79
|
+
- no request-level `taskCore`,
|
|
80
|
+
- template-driven core declaration (`{{core:...}}`),
|
|
81
|
+
- pre-render core discovery from raw template content,
|
|
82
|
+
- structured synthesis validation using detected `templateCores`,
|
|
83
|
+
- synthesized artifact persisted to execution memory and used in MAIN flow.
|
|
84
|
+
|
|
85
|
+
This is a contract change in **runtime behavior**, not a requirement to add more top-level request fields.
|
|
86
|
+
|
|
87
|
+
---
|
|
88
|
+
|
|
89
|
+
## What Upstream Still Needs To Ensure
|
|
90
|
+
|
|
91
|
+
1. `ai-skills.resolveRawTemplate(...)` remains stable/public for pre-render analysis.
|
|
92
|
+
2. `athenix-parser` keeps `core:` directives as first-class non-path tokens.
|
|
93
|
+
3. Lifecycle cleanup/shutdown exists for test/runtime handle hygiene (non-functional hardening).
|
|
94
|
+
|
|
95
|
+
---
|
|
96
|
+
|
|
97
|
+
## Final Position
|
|
98
|
+
|
|
99
|
+
The current request shape is acceptable and intentional.
|
|
100
|
+
No additional top-level request fields are required to represent the new core-aware runtime model.
|
|
101
|
+
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Web context precedence: structured scoping vs caller markdown
|
|
2
|
+
|
|
3
|
+
This document describes how **web evidence** reaches MAIN context and the **synthesized-context** PRE step, and how to avoid **duplicate** web retrieval.
|
|
4
|
+
|
|
5
|
+
## Sources
|
|
6
|
+
|
|
7
|
+
1. **Internal structured web context** — When NARRIX pre-processor runs with **`narrix.enableWebScope: true`**, ai-tasks calls the Narrix web scoper and stores the result on **`executionMemory.webContext`**. Markdown for prompts is derived via **`buildWebContextEvidenceMarkdown`** (`src/narrix/webContextMarkdown.ts`).
|
|
8
|
+
|
|
9
|
+
2. **Caller-provided markdown** — Orchestrators may attach a pre-rendered string on **`executionMemory.webContextMarkdown`**. When MAIN context is built (`_executeDirect`), if that string is non-empty and context assembly is active (see below), it is appended **after** Narrix narrative and internal web markdown as a section:
|
|
10
|
+
|
|
11
|
+
**`## Supplementary web context (caller-provided)`**
|
|
12
|
+
|
|
13
|
+
## Precedence (MAIN `context` markdown)
|
|
14
|
+
|
|
15
|
+
When **`includeContextInPrompt`** is true, or NARRIX narrative is in play, or MAIN runs with a **synthesized** override from the pipeline:
|
|
16
|
+
|
|
17
|
+
1. Narrix attachment markdown (when present).
|
|
18
|
+
2. Markdown built from **`executionMemory.webContext`** (when available).
|
|
19
|
+
3. **`executionMemory.webContextMarkdown`** (caller supplementary), if non-empty.
|
|
20
|
+
|
|
21
|
+
Synthesis PRE source material uses **`resolveSourceMaterial`** / **`resolveSourceMaterialParts`**, which serialize web as dedicated markdown and may **omit** raw `webContext` from JSON memory slices for specific policies (see [web-scoping-in-ai-tasks.md](./web-scoping-in-ai-tasks.md)).
|
|
22
|
+
|
|
23
|
+
## Avoiding duplicate search
|
|
24
|
+
|
|
25
|
+
- **Do not** set **`narrix.enableWebScope: true`** if the gateway already ran web search and you only persist results into **`executionMemory.webContext`** or **`webContextMarkdown`**.
|
|
26
|
+
- Use **`narrix.skipWebScopeWhenExternalWebMarkdownPresent: true`** when **`executionMemory.webContextMarkdown`** is already set before the NARRIX pre-processor runs: internal Tavily/web-scoper **will not** run for that invocation (Narrix narrative still runs as usual).
|
|
27
|
+
|
|
28
|
+
Optional environment knobs (existing) include caps on generated web markdown (e.g. **`WEB_CONTEXT_MARKDOWN_MAX_CHARS`** in web-scoping docs).
|
|
29
|
+
|
|
30
|
+
## Related
|
|
31
|
+
|
|
32
|
+
- [web-scoping-in-ai-tasks.md](./web-scoping-in-ai-tasks.md)
|
|
33
|
+
- [synthesized-context-guide.md](./synthesized-context-guide.md)
|