Package ai.narrativetrace.gradle
Class NarrativeTraceExtension
java.lang.Object
ai.narrativetrace.gradle.NarrativeTraceExtension
Top-level Gradle DSL extension for the NarrativeTrace plugin.
INTENT: This is the configuration surface build scripts use to choose mode, scope, output, clarity gates, and optional integration modules.
-
Constructor Summary
ConstructorsConstructorDescriptionNarrativeTraceExtension(org.gradle.api.model.ObjectFactory objects) Sets up defaults and creates nested extension objects. -
Method Summary
Modifier and TypeMethodDescriptionvoidagent(org.gradle.api.Action<? super AgentExtension> action) Configures Java-agent-specific settings.voidclarity(org.gradle.api.Action<? super ClarityExtension> action) Configures clarity score thresholds and failure behavior.getAgent()Returns the nested Java-agent block.abstract org.gradle.api.provider.Property<Boolean>Approval mode for structural narratives: whentrue, a test whose traced structure differs from its committed*.approved.ntbaseline fails with a readable diff, and a*.received.ntfile is left beside the baseline for review.abstract org.gradle.api.file.DirectoryPropertyDirectory of committed narrative baselines,<dir>/<TestClass>/<scenario>.approved.nt.Returns the nested clarity-check block.abstract org.gradle.api.provider.Property<Boolean>abstract org.gradle.api.provider.Property<String>abstract org.gradle.api.provider.Property<Boolean>Whether the test suite harvests the domain glossary (ADR-012).abstract org.gradle.api.provider.Property<String>Overrides the version used for every managed NarrativeTrace dependency.abstract org.gradle.api.provider.Property<String>getMode()Returns the nested module-toggle block.abstract org.gradle.api.file.DirectoryPropertyabstract org.gradle.api.provider.Property<String>getScope()abstract org.gradle.api.provider.Property<String>abstract org.gradle.api.provider.Property<String>voidmodules(org.gradle.api.Action<? super ModulesExtension> action) Configures optional integration-module toggles.
-
Constructor Details
-
NarrativeTraceExtension
@Inject public NarrativeTraceExtension(org.gradle.api.model.ObjectFactory objects) Sets up defaults and creates nested extension objects.
-
-
Method Details
-
getEnabled
-
getMode
-
getTestFramework
-
getScope
-
getFormat
-
getTracingLevel
-
getLibraryVersion
Overrides the version used for every managed NarrativeTrace dependency. Unset by default, in which case the plugin uses the version embedded in its own JAR. Set it to consume a different release or a local-SNAPSHOT(e.g.libraryVersion.set("0.2.0-SNAPSHOT")) without hand-pinning each dependency — the paved path for snapshot dogfooding, where the plugin's embedded version otherwise lags the libraries under development. -
getGlossary
Whether the test suite harvests the domain glossary (ADR-012). Off by default: harvesting rewritesglossary.json/glossary.mdat the repository root, outside the build directory, which no build may do unasked. -
getApproval
Approval mode for structural narratives: whentrue, a test whose traced structure differs from its committed*.approved.ntbaseline fails with a readable diff, and a*.received.ntfile is left beside the baseline for review. Off by default; accept changes with theapproveNarrativestask. -
getApprovedDir
public abstract org.gradle.api.file.DirectoryProperty getApprovedDir()Directory of committed narrative baselines,<dir>/<TestClass>/<scenario>.approved.nt. Default:src/test/narratives. -
getOutputDir
public abstract org.gradle.api.file.DirectoryProperty getOutputDir() -
getModules
Returns the nested module-toggle block. -
modules
Configures optional integration-module toggles. -
getAgent
Returns the nested Java-agent block. -
agent
Configures Java-agent-specific settings. -
getClarity
Returns the nested clarity-check block. -
clarity
Configures clarity score thresholds and failure behavior.
-