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.

kbPipeline.submitDecision

Submit approve/reject decision for a review task.

  • Type: operation (command)
  • Version: 1.0.0
  • Stability: experimental
  • Owners: @examples
  • Tags: knowledge, pipeline, hitl, rbac
  • File: packages/examples/kb-update-pipeline/src/operations/pipeline.ts
  • field.key.label
    kbPipeline.submitDecision
    field.version.label
    1.0.0
    field.type.label
    operation (command)
    field.title.label
    kbPipeline.submitDecision
    field.description.label

    Submit approve/reject decision for a review task.

  • Type: operation (command)
  • Version: 1.0.0
  • Stability: experimental
  • Owners: @examples
  • Tags: knowledge, pipeline, hitl, rbac
  • File: packages/examples/kb-update-pipeline/src/operations/pipeline.ts
  • field.tags.label
    knowledge,pipeline,hitl,rbac
    field.owners.label
    @examples
    field.stability.label
    experimental

    Submit approve/reject decision for a review task.

    Goal

    Ensure humans verify before publishing.

    Context

    Curator/expert reviews and decides.

    Source Definition

    import { defineCommand } from '@lssm-tech/lib.contracts-spec';
    import { defineSchemaModel, ScalarTypeEnum } from '@lssm-tech/lib.schema';
    import {
    	ChangeCandidateModel,
    	ReviewDecisionEnum,
    	ReviewTaskModel,
    } from '../entities/models';
    
    export const KbPipelineSubmitDecisionContract = defineCommand({
    	meta: {
    		key: 'kbPipeline.submitDecision',
    		version: '1.0.0',
    		stability: 'experimental',
    		owners: ['@examples'],
    		tags: ['knowledge', 'pipeline', 'hitl', 'rbac'],
    		description: 'Submit approve/reject decision for a review task.',
    		goal: 'Ensure humans verify before publishing.',
    		context: 'Curator/expert reviews and decides.',
    	},
    	io: {
    		input: SubmitDecisionInput,
    		output: ReviewTaskModel,
    		errors: {
    			FORBIDDEN_ROLE: {
    				description: 'Role not allowed to approve the given risk level',
    				http: 403,
    				gqlCode: 'FORBIDDEN_ROLE',
    				when: 'curator attempts to approve a high-risk change',
    			},
    			REVIEW_TASK_NOT_FOUND: {
    				description: 'Review task not found',
    				http: 404,
    				gqlCode: 'REVIEW_TASK_NOT_FOUND',
    				when: 'reviewTaskId is invalid',
    			},
    		},
    	},
    	policy: { auth: 'user' },
    });