OSS-first docs

These docs teach the open system first: contracts, generated surfaces, runtimes, governance, and incremental adoption. Studio shows up as the operating layer on top, not as the source of truth.

docs.generate

Generate documentation artifacts from ContractSpecs.

  • Type: operation (command)
  • Version: 1.0.0
  • Tags: generation
  • File: packages/libs/contracts-spec/src/docs/commands/docsGenerate.command.ts
  • field.key.label
    docs.generate
    field.version.label
    1.0.0
    field.type.label
    operation (command)
    field.title.label
    docs.generate
    field.description.label

    Generate documentation artifacts from ContractSpecs.

  • Type: operation (command)
  • Version: 1.0.0
  • Tags: generation
  • File: packages/libs/contracts-spec/src/docs/commands/docsGenerate.command.ts
  • field.tags.label
    generation
    field.owners.label
    field.stability.label

    Generate documentation artifacts from ContractSpecs.

    Goal

    Produce up-to-date reference docs and guides from specs and DocBlocks.

    Context

    Used by CLI and CI to keep docs in sync with contract definitions.

    Source Definition

    import { ScalarTypeEnum, SchemaModel } from '@lssm-tech/lib.schema';
    import { defineCommand } from '../../operations';
    import {
    	DOCS_DOMAIN,
    	DOCS_OWNERS,
    	DOCS_STABILITY,
    	DOCS_TAGS,
    } from '../constants';
    import { DocsGeneratedEvent } from '../events/docsGenerated.event';
    import { docId } from '../registry';
    import type { DocBlock } from '../types';
    
    export const DocsGenerateCommand = defineCommand({
    	meta: {
    		key: 'docs.generate',
    		title: 'Generate Documentation',
    		version: '1.0.0',
    		description: 'Generate documentation artifacts from ContractSpecs.',
    		goal: 'Produce up-to-date reference docs and guides from specs and DocBlocks.',
    		context:
    			'Used by CLI and CI to keep docs in sync with contract definitions.',
    		domain: DOCS_DOMAIN,
    		owners: DOCS_OWNERS,
    		tags: [...DOCS_TAGS, 'generation'],
    		stability: DOCS_STABILITY,
    		docId: [docId('docs.tech.docs-generator')],
    	},
    	capability: {
    		key: 'docs.system',
    		version: '1.0.0',
    	},
    	io: {
    		input: DocsGenerateInput,
    		output: DocsGenerateOutput,
    		errors: {
    			OUTPUT_WRITE_FAILED: {
    				description: 'Failed to write generated docs output.',
    				http: 500,
    				when: 'The generator cannot persist artifacts to the output path.',
    			},
    		},
    	},
    	policy: {
    		auth: 'admin',
    		pii: [],
    	},
    	sideEffects: {
    		emits: [
    			{
    				ref: DocsGeneratedEvent.meta,
    				when: 'Docs generation completes successfully.',
    			},
    		],
    	},
    });