Contract framework with markdown-native contracts utilizing fenced YAML blocks

This commit is contained in:
2026-05-03 22:51:13 +02:00
parent 3cfda33bc9
commit e3e13ee45a
36 changed files with 2877 additions and 13 deletions

View File

@@ -0,0 +1,43 @@
---
title: Business Letter Contract
version: "0.1"
---
# Business Letter Contract
```yaml contract
id: business-letter-contract-v1
document:
type: business-letter
fields:
recipient_name:
type: string
required: true
source: context.recipient.name
sender_name:
type: string
required: true
source: context.sender.name
sections:
- id: greeting
title: Greeting
presence: required
level: 2
- id: body
title: Body
presence: required
level: 2
metrics:
words:
min: 40
max: 350
severity: warning
- id: closing
title: Closing
presence: required
level: 2
rubrics:
- id: tone-fit
scope: section.body
criteria: The body should match the relationship and communication purpose.
```