@contractspec/example.product-intent
v3.7.17
Published
Product intent example: evidence ingestion and prompt-ready outputs.
Maintainers
Readme
@contractspec/example.product-intent
Website: https://contractspec.io
Product intent example: evidence ingestion and prompt-ready outputs.
What This Demonstrates
- Canonical
product-intentexport viaProductIntentDiscoverySpec. - Evidence loading and ingestion pipeline.
- PostHog signal extraction for product analytics.
- Action synchronization across tools.
- Script-based execution pattern.
src/docs/contains docblocks and documentation-facing exports.
Running Locally
From packages/examples/product-intent:
bun run devbun run buildbun run testbun run typecheck
Usage
Use @contractspec/example.product-intent as a reference implementation, or import its exported surfaces into a workspace that composes ContractSpec examples and bundles.
Architecture
src/docs/contains docblocks and documentation-facing exports.src/example.tsis the runnable example entrypoint.src/index.tsis the root public barrel and package entrypoint.src/load-evidence.test.tsis part of the package's public or composition surface.src/load-evidence.tsis part of the package's public or composition surface.src/posthog-signals.tsis part of the package's public or composition surface.src/product-intent.discovery.tsdefines the exported product-intent spec.src/product-intent.feature.tsdefines a feature entrypoint.
Public Entry Points
- Export
.resolves through./src/index.ts. - Export
./docsresolves through./src/docs/index.ts. - Export
./docs/product-intent.docblockresolves through./src/docs/product-intent.docblock.ts. - Export
./exampleresolves through./src/example.ts. - Export
./load-evidenceresolves through./src/load-evidence.ts. - Export
./posthog-signalsresolves through./src/posthog-signals.ts. - Export
./product-intent.discoveryresolves through./src/product-intent.discovery.ts. - Export
./product-intent.featureresolves through./src/product-intent.feature.ts. - Export
./scriptresolves through./src/script.ts. - Export
./sync-actionsresolves through./src/sync-actions.ts. - The package publishes 9 total export subpaths; keep docs aligned with
package.json.
Local Commands
bun run dev— contractspec-bun-build devbun run build— bun run prebuild && bun run build:bundle && bun run build:typesbun run test— bun testbun run lint— bun lint:fixbun run lint:check— biome check .bun run lint:fix— biome check --write --unsafe --only=nursery/useSortedClasses . && biome check --write .bun run typecheck— tsc --noEmitbun run publish:pkg— bun publish --tolerate-republish --ignore-scripts --verbosebun run publish:pkg:canary— bun publish:pkg --tag canarybun run clean— rimraf dist .turbobun run build:bundle— contractspec-bun-build transpilebun run build:types— contractspec-bun-build typesbun run prebuild— contractspec-bun-build prebuild
Recent Updates
- Replace eslint+prettier by biomejs to optimize speed.
- Stability.
- Missing contract layers.
Notes
- Works alongside
@contractspec/integration.providers-impls,@contractspec/lib.ai-agent,@contractspec/lib.analytics,@contractspec/lib.contracts-integrations,@contractspec/lib.contracts-spec, ...
