@bluefly/openstandardagents 0.2.5-RC → 0.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (238) hide show
  1. package/.github/ISSUE_TEMPLATE/bug_report.yml +63 -0
  2. package/.github/ISSUE_TEMPLATE/feature_request.yml +40 -0
  3. package/.github/workflows/dependabot-comment.yml +34 -0
  4. package/.github/workflows/pr-comment.yml +33 -0
  5. package/.husky/pre-commit +5 -0
  6. package/.kiro/config.json +21 -0
  7. package/.kiro/settings/mcp.json +61 -0
  8. package/.kiro/specs/scripts-migration-api-first/design.md +883 -0
  9. package/.kiro/specs/scripts-migration-api-first/requirements.md +165 -0
  10. package/.kiro/specs/scripts-migration-api-first/tasks.md +539 -0
  11. package/.kiro/specs/{website-design-audit → website-brand-identity}/design.md +381 -0
  12. package/.kiro/specs/{website-design-audit → website-brand-identity}/requirements.md +88 -0
  13. package/.kiro/specs/website-brand-identity/tasks.md +981 -0
  14. package/CHANGELOG.md +23 -0
  15. package/README.md +12 -3
  16. package/bin/ossa-dev +42 -0
  17. package/bin/ossa-export +32 -0
  18. package/bin/ossa-generate +60 -0
  19. package/bin/ossa-health +40 -0
  20. package/bin/ossa-init +26 -0
  21. package/dist/repositories/schema.repository.d.ts.map +1 -1
  22. package/dist/repositories/schema.repository.js +15 -10
  23. package/dist/repositories/schema.repository.js.map +1 -1
  24. package/dist/services/github-sync/github-client.d.ts +14 -0
  25. package/dist/services/github-sync/github-client.d.ts.map +1 -0
  26. package/dist/services/github-sync/github-client.js +41 -0
  27. package/dist/services/github-sync/github-client.js.map +1 -0
  28. package/dist/services/github-sync/gitlab-client.d.ts +17 -0
  29. package/dist/services/github-sync/gitlab-client.d.ts.map +1 -0
  30. package/dist/services/github-sync/gitlab-client.js +42 -0
  31. package/dist/services/github-sync/gitlab-client.js.map +1 -0
  32. package/dist/services/github-sync/schemas.d.ts +46 -0
  33. package/dist/services/github-sync/schemas.d.ts.map +1 -0
  34. package/dist/services/github-sync/schemas.js +36 -0
  35. package/dist/services/github-sync/schemas.js.map +1 -0
  36. package/dist/services/github-sync/sync.service.d.ts +27 -0
  37. package/dist/services/github-sync/sync.service.d.ts.map +1 -0
  38. package/dist/services/github-sync/sync.service.js +99 -0
  39. package/dist/services/github-sync/sync.service.js.map +1 -0
  40. package/dist/services/runtime/claude/capability-mapper.d.ts +84 -0
  41. package/dist/services/runtime/claude/capability-mapper.d.ts.map +1 -0
  42. package/dist/services/runtime/claude/capability-mapper.js +245 -0
  43. package/dist/services/runtime/claude/capability-mapper.js.map +1 -0
  44. package/dist/services/runtime/claude/claude-adapter.d.ts +80 -0
  45. package/dist/services/runtime/claude/claude-adapter.d.ts.map +1 -0
  46. package/dist/services/runtime/claude/claude-adapter.js +287 -0
  47. package/dist/services/runtime/claude/claude-adapter.js.map +1 -0
  48. package/dist/services/runtime/claude/manifest-parser.d.ts +77 -0
  49. package/dist/services/runtime/claude/manifest-parser.d.ts.map +1 -0
  50. package/dist/services/runtime/claude/manifest-parser.js +169 -0
  51. package/dist/services/runtime/claude/manifest-parser.js.map +1 -0
  52. package/dist/services/runtime/claude/types.d.ts +115 -0
  53. package/dist/services/runtime/claude/types.d.ts.map +1 -0
  54. package/dist/services/runtime/claude/types.js +6 -0
  55. package/dist/services/runtime/claude/types.js.map +1 -0
  56. package/dist/services/validation.service.d.ts.map +1 -1
  57. package/dist/services/validation.service.js +12 -1
  58. package/dist/services/validation.service.js.map +1 -1
  59. package/dist/spec/v0.2.4/ossa-0.2.4.schema.json +85 -208
  60. package/dist/spec/v0.2.6/CHANGELOG.md +401 -0
  61. package/dist/spec/v0.2.6/README.md +72 -0
  62. package/dist/spec/v0.2.6/migrations/v0.2.3-to-v0.2.4.md +599 -0
  63. package/dist/spec/v0.2.6/migrations/v0.2.5-RC-to-v0.2.6.md +65 -0
  64. package/dist/spec/v0.2.6/ossa-0.2.6.schema.json +1786 -0
  65. package/dist/spec/v0.2.6/ossa-0.2.6.yaml +581 -0
  66. package/dist/spec/v0.2.6-dev/CHANGELOG.md +164 -0
  67. package/dist/spec/v0.2.6-dev/README.md +75 -0
  68. package/dist/spec/v0.2.6-dev/migrations/v0.2.2-to-v0.2.3.md +343 -0
  69. package/dist/spec/v0.2.6-dev/migrations/v0.2.3-to-v0.2.4.md +599 -0
  70. package/dist/spec/{v0.2.4/ossa-0.2.4-dev.schema.json → v0.2.6-dev/ossa-0.2.5.schema.json} +9 -9
  71. package/dist/spec/v0.2.6-dev/ossa-0.2.5.yaml +581 -0
  72. package/{spec/v0.2.4/ossa-0.2.4-dev.schema.json → dist/spec/v0.2.6-dev/ossa-0.2.6-dev.schema.json} +9 -9
  73. package/dist/spec/v0.2.6-dev/ossa-0.2.6-dev.yaml +448 -0
  74. package/dist/spec/v0.2.7/core/agentgraph.md +324 -0
  75. package/dist/spec/v0.2.7/resources/agentgraph.yaml +135 -0
  76. package/docs/brand-guide/01-brand-overview.md +37 -0
  77. package/docs/brand-guide/02-logo-usage.md +43 -0
  78. package/docs/brand-guide/03-color-palette.md +70 -0
  79. package/docs/brand-guide/04-typography.md +82 -0
  80. package/docs/brand-guide/05-voice-and-tone.md +108 -0
  81. package/docs/brand-guide/06-visual-elements.md +137 -0
  82. package/docs/brand-guide/07-application-examples.md +153 -0
  83. package/docs/brand-guide/OssaLogo/OssA_Logo.svg +21 -0
  84. package/docs/brand-guide/OssaLogo/brand.af +0 -0
  85. package/docs/brand-guide/README.md +107 -0
  86. package/docs/comparison.md +315 -0
  87. package/docs/operations/automation-roadmap.md +245 -0
  88. package/docs/operations/github-sync-strategy.md +357 -0
  89. package/examples/anthropic/claude-assistant.ossa.json +5 -4
  90. package/examples/autogen/multi-agent.ossa.json +6 -4
  91. package/examples/crewai/research-team.ossa.json +14 -5
  92. package/examples/cursor/code-review-agent.ossa.json +21 -6
  93. package/examples/langchain/chain-agent.ossa.json +21 -5
  94. package/examples/langflow/workflow-agent.ossa.json +2 -3
  95. package/examples/langgraph/state-machine-agent.ossa.json +2 -3
  96. package/examples/llamaindex/rag-agent.ossa.json +2 -3
  97. package/examples/openai/multi-tool-agent.ossa.json +32 -9
  98. package/examples/openai/swarm-agent.ossa.json +18 -5
  99. package/examples/vercel/edge-agent.ossa.json +5 -4
  100. package/openapi/github-sync.yaml +115 -0
  101. package/package.json +25 -4
  102. package/scripts/README.md +103 -0
  103. package/scripts/auto-rebase-mrs.ts +106 -0
  104. package/scripts/batch-dependabot.sh +57 -0
  105. package/scripts/configure-gitlab-branch-protection.ts +95 -0
  106. package/scripts/create-issue-helper.ts +238 -0
  107. package/scripts/create-milestone-issue.ts +73 -0
  108. package/scripts/fix-schema-formats.js +82 -0
  109. package/scripts/generate-agents-catalog.ts +77 -0
  110. package/scripts/generate-api-docs.ts +218 -0
  111. package/scripts/generate-cli-docs.ts +410 -0
  112. package/scripts/generate-config-docs.ts +109 -0
  113. package/scripts/generate-errors-docs.ts +76 -0
  114. package/scripts/generate-examples-docs.ts +99 -0
  115. package/scripts/generate-schema-docs.ts +296 -0
  116. package/scripts/generate-types-docs.ts +48 -0
  117. package/scripts/lowercase-docs.ts +43 -0
  118. package/scripts/manage-milestone-mrs.ts +279 -0
  119. package/scripts/rebase-all-mrs.sh +75 -0
  120. package/scripts/sync-github-pr.sh +48 -0
  121. package/scripts/sync-version.js +40 -0
  122. package/scripts/sync-wiki.sh +50 -0
  123. package/scripts/validate-all.js +127 -0
  124. package/spec/v0.2.4/ossa-0.2.4.schema.json +85 -208
  125. package/spec/v0.2.6/CHANGELOG.md +401 -0
  126. package/spec/v0.2.6/README.md +72 -0
  127. package/spec/v0.2.6/migrations/v0.2.3-to-v0.2.4.md +599 -0
  128. package/spec/v0.2.6/migrations/v0.2.5-RC-to-v0.2.6.md +65 -0
  129. package/spec/v0.2.6/ossa-0.2.6.schema.json +1786 -0
  130. package/spec/v0.2.6/ossa-0.2.6.yaml +581 -0
  131. package/spec/v0.2.6-dev/CHANGELOG.md +164 -0
  132. package/spec/v0.2.6-dev/README.md +75 -0
  133. package/spec/v0.2.6-dev/migrations/v0.2.2-to-v0.2.3.md +343 -0
  134. package/spec/v0.2.6-dev/migrations/v0.2.3-to-v0.2.4.md +599 -0
  135. package/spec/v0.2.6-dev/ossa-0.2.5.schema.json +1696 -0
  136. package/spec/v0.2.6-dev/ossa-0.2.5.yaml +581 -0
  137. package/spec/v0.2.6-dev/ossa-0.2.6-dev.schema.json +1696 -0
  138. package/spec/v0.2.6-dev/ossa-0.2.6-dev.yaml +448 -0
  139. package/spec/v0.2.7/core/agentgraph.md +324 -0
  140. package/spec/v0.2.7/resources/agentgraph.yaml +135 -0
  141. package/website/DESIGN_SYSTEM_IMPLEMENTATION.md +445 -0
  142. package/website/app/about/page.tsx +53 -44
  143. package/website/app/ecosystem/page.tsx +146 -111
  144. package/website/app/globals.scss +256 -21
  145. package/website/app/page.tsx +394 -182
  146. package/website/app/page.tsx.bak +679 -0
  147. package/website/app/page.tsx.bak2 +649 -0
  148. package/website/app/schema/page.tsx +3 -3
  149. package/website/app/specification/page.tsx +1 -1
  150. package/website/components/layout/Header.tsx +27 -23
  151. package/website/components/ui/Badge.tsx +82 -0
  152. package/website/components/ui/Button.tsx +116 -0
  153. package/website/components/ui/Card.tsx +167 -0
  154. package/website/components/ui/Checkbox.tsx +141 -0
  155. package/website/components/ui/Input.tsx +169 -0
  156. package/website/components/ui/Radio.tsx +141 -0
  157. package/website/components/ui/Select.tsx +182 -0
  158. package/website/components/ui/Tag.tsx +158 -0
  159. package/website/components/ui/Textarea.tsx +195 -0
  160. package/website/components/ui/index.ts +11 -0
  161. package/website/content/docs/{00-HOME.md → 00-home.md} +1 -1
  162. package/website/content/docs/agents/catalog.md +28 -0
  163. package/website/content/docs/{AIFlow-Framework-Integration-with-OSSA.md → aiflow-framework-integration-with-ossa.md} +2 -2
  164. package/website/content/docs/api-reference/index.md +38 -0
  165. package/website/content/docs/api-reference/ossa-core-api.md +634 -0
  166. package/website/content/docs/api-reference/ossa-registry-api.md +515 -0
  167. package/website/content/docs/api-reference/unified-agent-gateway.md +599 -0
  168. package/website/content/docs/cli-reference/index.md +111 -0
  169. package/website/content/docs/cli-reference/ossa-agents.md +70 -0
  170. package/website/content/docs/cli-reference/ossa-export.md +56 -0
  171. package/website/content/docs/cli-reference/ossa-generate.md +66 -0
  172. package/website/content/docs/cli-reference/ossa-gitlab-agent.md +57 -0
  173. package/website/content/docs/cli-reference/ossa-import.md +56 -0
  174. package/website/content/docs/cli-reference/ossa-init.md +57 -0
  175. package/website/content/docs/cli-reference/ossa-migrate.md +62 -0
  176. package/website/content/docs/cli-reference/ossa-run.md +66 -0
  177. package/website/content/docs/cli-reference/ossa-schema.md +57 -0
  178. package/website/content/docs/cli-reference/ossa-setup.md +57 -0
  179. package/website/content/docs/cli-reference/ossa-validate.md +66 -0
  180. package/website/content/docs/configuration/index.md +97 -0
  181. package/website/content/docs/deployment/github-mirroring.md +924 -0
  182. package/website/content/docs/documentation.md +100 -0
  183. package/website/content/docs/ecosystem/framework-support.md +551 -9
  184. package/website/content/docs/errors/index.md +10 -0
  185. package/website/content/docs/examples/{AIFlow-Framework-Integration-with-OSSA.md → aiflow-framework-integration-with-ossa.md} +2 -2
  186. package/website/content/docs/examples/catalog.md +300 -0
  187. package/website/content/docs/for-audiences/{Students-Researchers.md → students-researchers.md} +1 -1
  188. package/website/content/docs/getting-started/{Installation.md → installation.md} +1 -1
  189. package/website/content/docs/getting-started.md +1 -1
  190. package/website/content/docs/integrations/aiflow.md +2 -2
  191. package/website/content/docs/migration-guides/anthropic-mcp-to-ossa.md +5 -5
  192. package/website/content/docs/migration-guides/crewai-to-ossa.md +3 -3
  193. package/website/content/docs/migration-guides/drupal-eca-to-ossa.md +7 -7
  194. package/website/content/docs/migration-guides/langchain-to-ossa.md +4 -4
  195. package/website/content/docs/openapi-extensions/index.md +1 -1
  196. package/website/content/docs/ossa-compliant-badge.md +1 -1
  197. package/website/content/docs/pre-release/index.md +5 -5
  198. package/website/content/docs/releases/v0.2.6.md +99 -0
  199. package/website/content/docs/schema-reference/agent-capabilities.md +50 -0
  200. package/website/content/docs/schema-reference/agent-id.md +52 -0
  201. package/website/content/docs/schema-reference/agent-name.md +50 -0
  202. package/website/content/docs/schema-reference/agent-role.md +54 -0
  203. package/website/content/docs/schema-reference/agent-version.md +50 -0
  204. package/website/content/docs/schema-reference/index.md +26 -157
  205. package/website/content/docs/types-reference/index.md +105 -0
  206. package/website/content/docs/versioning.md +3 -3
  207. package/website/dev.sh +53 -0
  208. package/website/docker-compose.dev.yml +36 -0
  209. package/website/lib/version.ts +1 -1
  210. package/website/lib/versions.json +45 -20
  211. package/website/package.json +1 -1
  212. package/website/styles/_spacing.scss +453 -0
  213. package/website/styles/_tokens.scss +245 -0
  214. package/website/styles/_typography.scss +361 -0
  215. package/website/styles/_variables.scss +270 -19
  216. package/website/tailwind.config.ts +113 -79
  217. package/.kiro/specs/agent-buildkit-templates/design.md +0 -495
  218. package/.kiro/specs/agent-buildkit-templates/requirements.md +0 -165
  219. package/.kiro/specs/kiro-ide-supercharger/README.md +0 -202
  220. package/.kiro/specs/kiro-ide-supercharger/design.md +0 -1005
  221. package/.kiro/specs/kiro-ide-supercharger/requirements.md +0 -141
  222. package/.kiro/specs/kiro-ide-supercharger/tasks.md +0 -507
  223. package/docs/issue-19-completion-summary.md +0 -648
  224. package/docs/issue-19-validation.md +0 -351
  225. package/website/content/docs/Examples.md +0 -71
  226. package/website/content/docs/OpenAPI-Extensions.md +0 -934
  227. package/website/content/docs/core-concepts/Project-Structure.md +0 -348
  228. package/website/content/docs/examples/Migration-Guides.md +0 -214
  229. package/website/content/docs/for-audiences/Architects.md +0 -224
  230. package/website/content/docs/for-audiences/Developers.md +0 -220
  231. package/website/content/docs/for-audiences/Enterprises.md +0 -256
  232. package/website/content/docs/getting-started/5-Minute-Overview.md +0 -85
  233. package/website/content/docs/getting-started/First-Agent.md +0 -196
  234. package/website/content/docs/getting-started/Hello-World.md +0 -184
  235. package/website/content/docs/migration-guides/00-INDEX.md +0 -76
  236. package/website/content/docs/migration-guides/README.md +0 -133
  237. /package/dist/spec/v0.2.4/{ossa-0.2.4-dev.yaml → ossa-0.2.4.yaml} +0 -0
  238. /package/spec/v0.2.4/{ossa-0.2.4-dev.yaml → ossa-0.2.4.yaml} +0 -0
@@ -0,0 +1,410 @@
1
+ #!/usr/bin/env tsx
2
+ /**
3
+ * Generate CLI documentation from command source files
4
+ *
5
+ * Usage: npm run docs:cli:generate
6
+ */
7
+
8
+ import { readFileSync, writeFileSync, mkdirSync, readdirSync } from 'fs';
9
+ import { join, basename } from 'path';
10
+
11
+ interface CommandInfo {
12
+ name: string;
13
+ description: string;
14
+ arguments: Array<{ name: string; description: string; required: boolean }>;
15
+ options: Array<{ flag: string; description: string; default?: string }>;
16
+ examples: string[];
17
+ apiEndpoint?: string;
18
+ }
19
+
20
+ const CLI_DIR = join(process.cwd(), 'src/cli/commands');
21
+ const OUTPUT_DIR = join(process.cwd(), 'website/content/docs/cli-reference');
22
+
23
+ // Command metadata (extracted from source or defined here)
24
+ const COMMANDS: Record<string, CommandInfo> = {
25
+ validate: {
26
+ name: 'validate',
27
+ description: 'Validate OSSA agent manifests against the schema',
28
+ arguments: [
29
+ { name: 'path', description: 'Path to agent manifest file or directory', required: true }
30
+ ],
31
+ options: [
32
+ { flag: '--version <version>', description: 'Specify OSSA version', default: 'latest' },
33
+ { flag: '--strict', description: 'Enable strict validation mode' },
34
+ { flag: '--format <format>', description: 'Output format: json, yaml, table', default: 'table' },
35
+ { flag: '--verbose', description: 'Show detailed validation errors' }
36
+ ],
37
+ examples: [
38
+ 'ossa validate agent.ossa.yaml',
39
+ 'ossa validate ./agents/',
40
+ 'ossa validate agent.ossa.yaml --strict',
41
+ 'ossa validate agent.ossa.yaml --format json'
42
+ ],
43
+ apiEndpoint: 'POST /api/v1/validate'
44
+ },
45
+ generate: {
46
+ name: 'generate',
47
+ description: 'Generate OSSA agent manifests from templates',
48
+ arguments: [
49
+ { name: 'type', description: 'Agent type: worker, orchestrator, compliance, chat', required: true }
50
+ ],
51
+ options: [
52
+ { flag: '--name <name>', description: 'Agent name', default: 'My Agent' },
53
+ { flag: '--id <id>', description: 'Agent ID (DNS-1123 format)' },
54
+ { flag: '--output <path>', description: 'Output file path', default: 'agent.ossa.yaml' },
55
+ { flag: '--interactive', description: 'Interactive mode with prompts' }
56
+ ],
57
+ examples: [
58
+ 'ossa generate worker --name "Data Processor"',
59
+ 'ossa generate orchestrator --id my-orchestrator',
60
+ 'ossa generate compliance --interactive',
61
+ 'ossa generate chat --output chat-agent.yaml'
62
+ ],
63
+ apiEndpoint: 'POST /api/v1/agents/generate'
64
+ },
65
+ migrate: {
66
+ name: 'migrate',
67
+ description: 'Migrate agent manifests between OSSA versions',
68
+ arguments: [
69
+ { name: 'source', description: 'Source manifest file', required: true }
70
+ ],
71
+ options: [
72
+ { flag: '--from <version>', description: 'Source OSSA version' },
73
+ { flag: '--to <version>', description: 'Target OSSA version', default: 'latest' },
74
+ { flag: '--output <path>', description: 'Output file path' },
75
+ { flag: '--dry-run', description: 'Show changes without writing' }
76
+ ],
77
+ examples: [
78
+ 'ossa migrate agent.yaml --from 0.2.4 --to 0.2.5',
79
+ 'ossa migrate agent.yaml --dry-run',
80
+ 'ossa migrate agent.yaml --output migrated-agent.yaml'
81
+ ],
82
+ apiEndpoint: 'POST /api/v1/migrate'
83
+ },
84
+ run: {
85
+ name: 'run',
86
+ description: 'Run an OSSA agent locally',
87
+ arguments: [
88
+ { name: 'manifest', description: 'Path to agent manifest', required: true }
89
+ ],
90
+ options: [
91
+ { flag: '--env <file>', description: 'Environment variables file' },
92
+ { flag: '--port <port>', description: 'Port to run on', default: '3000' },
93
+ { flag: '--watch', description: 'Watch for changes and reload' },
94
+ { flag: '--debug', description: 'Enable debug logging' }
95
+ ],
96
+ examples: [
97
+ 'ossa run agent.ossa.yaml',
98
+ 'ossa run agent.ossa.yaml --port 8080',
99
+ 'ossa run agent.ossa.yaml --watch --debug',
100
+ 'ossa run agent.ossa.yaml --env .env.local'
101
+ ],
102
+ apiEndpoint: 'POST /api/v1/agents/{id}/execute'
103
+ },
104
+ init: {
105
+ name: 'init',
106
+ description: 'Initialize a new OSSA project',
107
+ arguments: [],
108
+ options: [
109
+ { flag: '--name <name>', description: 'Project name' },
110
+ { flag: '--template <template>', description: 'Project template: minimal, full, enterprise' },
111
+ { flag: '--typescript', description: 'Use TypeScript' },
112
+ { flag: '--git', description: 'Initialize git repository' }
113
+ ],
114
+ examples: [
115
+ 'ossa init',
116
+ 'ossa init --name my-agent-project',
117
+ 'ossa init --template enterprise --typescript',
118
+ 'ossa init --git'
119
+ ]
120
+ },
121
+ setup: {
122
+ name: 'setup',
123
+ description: 'Set up OSSA development environment',
124
+ arguments: [],
125
+ options: [
126
+ { flag: '--gitlab', description: 'Configure GitLab integration' },
127
+ { flag: '--kubernetes', description: 'Configure Kubernetes deployment' },
128
+ { flag: '--registry <url>', description: 'Configure agent registry' },
129
+ { flag: '--interactive', description: 'Interactive setup wizard' }
130
+ ],
131
+ examples: [
132
+ 'ossa setup --interactive',
133
+ 'ossa setup --gitlab',
134
+ 'ossa setup --kubernetes',
135
+ 'ossa setup --registry https://registry.ossa.dev'
136
+ ]
137
+ },
138
+ export: {
139
+ name: 'export',
140
+ description: 'Export agent manifest to different formats',
141
+ arguments: [
142
+ { name: 'manifest', description: 'Path to agent manifest', required: true }
143
+ ],
144
+ options: [
145
+ { flag: '--format <format>', description: 'Export format: json, yaml, openapi, k8s', default: 'json' },
146
+ { flag: '--output <path>', description: 'Output file path' },
147
+ { flag: '--pretty', description: 'Pretty print output' }
148
+ ],
149
+ examples: [
150
+ 'ossa export agent.ossa.yaml --format json',
151
+ 'ossa export agent.ossa.yaml --format k8s --output deployment.yaml',
152
+ 'ossa export agent.ossa.yaml --format openapi --pretty'
153
+ ]
154
+ },
155
+ import: {
156
+ name: 'import',
157
+ description: 'Import agents from other frameworks',
158
+ arguments: [
159
+ { name: 'source', description: 'Source file or URL', required: true }
160
+ ],
161
+ options: [
162
+ { flag: '--from <framework>', description: 'Source framework: langchain, crewai, openai, mcp' },
163
+ { flag: '--output <path>', description: 'Output file path', default: 'agent.ossa.yaml' },
164
+ { flag: '--validate', description: 'Validate after import' }
165
+ ],
166
+ examples: [
167
+ 'ossa import langchain-agent.py --from langchain',
168
+ 'ossa import crew.yaml --from crewai --validate',
169
+ 'ossa import https://example.com/agent.json --from openai'
170
+ ]
171
+ },
172
+ schema: {
173
+ name: 'schema',
174
+ description: 'View and manage OSSA schemas',
175
+ arguments: [],
176
+ options: [
177
+ { flag: '--version <version>', description: 'Schema version', default: 'latest' },
178
+ { flag: '--format <format>', description: 'Output format: json, yaml', default: 'yaml' },
179
+ { flag: '--field <field>', description: 'Show specific field documentation' },
180
+ { flag: '--list', description: 'List available schema versions' }
181
+ ],
182
+ examples: [
183
+ 'ossa schema',
184
+ 'ossa schema --version 0.2.5',
185
+ 'ossa schema --field agent.id',
186
+ 'ossa schema --list'
187
+ ]
188
+ },
189
+ 'gitlab-agent': {
190
+ name: 'gitlab-agent',
191
+ description: 'Manage GitLab agent integration',
192
+ arguments: [],
193
+ options: [
194
+ { flag: '--configure', description: 'Configure GitLab agent' },
195
+ { flag: '--deploy', description: 'Deploy agent to GitLab' },
196
+ { flag: '--status', description: 'Check agent status' },
197
+ { flag: '--logs', description: 'View agent logs' }
198
+ ],
199
+ examples: [
200
+ 'ossa gitlab-agent --configure',
201
+ 'ossa gitlab-agent --deploy',
202
+ 'ossa gitlab-agent --status',
203
+ 'ossa gitlab-agent --logs'
204
+ ]
205
+ },
206
+ agents: {
207
+ name: 'agents',
208
+ description: 'Manage OSSA agents',
209
+ arguments: [
210
+ { name: 'action', description: 'Action: list, get, create, update, delete', required: true }
211
+ ],
212
+ options: [
213
+ { flag: '--id <id>', description: 'Agent ID' },
214
+ { flag: '--role <role>', description: 'Filter by role' },
215
+ { flag: '--status <status>', description: 'Filter by status' },
216
+ { flag: '--format <format>', description: 'Output format: json, yaml, table', default: 'table' }
217
+ ],
218
+ examples: [
219
+ 'ossa agents list',
220
+ 'ossa agents list --role worker',
221
+ 'ossa agents get --id my-agent',
222
+ 'ossa agents create agent.ossa.yaml',
223
+ 'ossa agents delete --id my-agent'
224
+ ],
225
+ apiEndpoint: 'GET /api/v1/agents'
226
+ }
227
+ };
228
+
229
+ function generateCommandDoc(cmd: CommandInfo): string {
230
+ let doc = `# ossa ${cmd.name}\n\n`;
231
+ doc += `**Purpose**: ${cmd.description}\n\n`;
232
+
233
+ // Synopsis
234
+ doc += '## Synopsis\n\n';
235
+ doc += '```bash\n';
236
+ doc += `ossa ${cmd.name}`;
237
+ if (cmd.arguments.length > 0) {
238
+ for (const arg of cmd.arguments) {
239
+ doc += arg.required ? ` <${arg.name}>` : ` [${arg.name}]`;
240
+ }
241
+ }
242
+ doc += ' [options]\n';
243
+ doc += '```\n\n';
244
+
245
+ // Description
246
+ doc += '## Description\n\n';
247
+ doc += `${cmd.description}\n\n`;
248
+
249
+ // Arguments
250
+ if (cmd.arguments.length > 0) {
251
+ doc += '## Arguments\n\n';
252
+ for (const arg of cmd.arguments) {
253
+ const required = arg.required ? ' (required)' : ' (optional)';
254
+ doc += `- \`<${arg.name}>\`${required} - ${arg.description}\n`;
255
+ }
256
+ doc += '\n';
257
+ }
258
+
259
+ // Options
260
+ if (cmd.options.length > 0) {
261
+ doc += '## Options\n\n';
262
+ for (const opt of cmd.options) {
263
+ doc += `- \`${opt.flag}\` - ${opt.description}`;
264
+ if (opt.default) {
265
+ doc += ` (default: ${opt.default})`;
266
+ }
267
+ doc += '\n';
268
+ }
269
+ doc += '\n';
270
+ }
271
+
272
+ // Examples
273
+ if (cmd.examples.length > 0) {
274
+ doc += '## Examples\n\n';
275
+ for (const example of cmd.examples) {
276
+ doc += '```bash\n';
277
+ doc += example + '\n';
278
+ doc += '```\n\n';
279
+ }
280
+ }
281
+
282
+ // API endpoint connection
283
+ if (cmd.apiEndpoint) {
284
+ doc += '## API Endpoint Connection\n\n';
285
+ doc += `This command uses the following API endpoint:\n`;
286
+ doc += `- \`${cmd.apiEndpoint}\` - [API Reference](../api-reference/index.md)\n\n`;
287
+ }
288
+
289
+ // Exit codes
290
+ doc += '## Exit Codes\n\n';
291
+ doc += '- `0` - Success\n';
292
+ doc += '- `1` - General error\n';
293
+ doc += '- `2` - Invalid arguments\n';
294
+ doc += '- `3` - File not found\n\n';
295
+
296
+ // Related commands
297
+ doc += '## Related Commands\n\n';
298
+ const relatedCommands = Object.keys(COMMANDS).filter(c => c !== cmd.name).slice(0, 3);
299
+ for (const related of relatedCommands) {
300
+ doc += `- [ossa ${related}](./ossa-${related}.md)\n`;
301
+ }
302
+ doc += '\n';
303
+
304
+ // Related documentation
305
+ doc += '## Related Documentation\n\n';
306
+ doc += '- [API Reference](../api-reference/index.md)\n';
307
+ doc += '- [Schema Reference](../schema-reference/index.md)\n';
308
+ doc += '- [Getting Started](../getting-started/index.md)\n';
309
+
310
+ return doc;
311
+ }
312
+
313
+ function main() {
314
+ console.log('🚀 Generating CLI documentation...\n');
315
+
316
+ // Create output directory
317
+ mkdirSync(OUTPUT_DIR, { recursive: true });
318
+
319
+ console.log(`📁 Processing ${Object.keys(COMMANDS).length} CLI commands...\n`);
320
+
321
+ // Generate documentation for each command
322
+ for (const [name, cmd] of Object.entries(COMMANDS)) {
323
+ const docContent = generateCommandDoc(cmd);
324
+ const outputFile = join(OUTPUT_DIR, `ossa-${name}.md`);
325
+
326
+ writeFileSync(outputFile, docContent);
327
+ console.log(`✅ Generated: ossa-${name}.md`);
328
+ }
329
+
330
+ // Generate index
331
+ const indexContent = `# CLI Reference
332
+
333
+ The OSSA CLI provides commands for managing AI agents throughout their lifecycle.
334
+
335
+ ## Installation
336
+
337
+ \`\`\`bash
338
+ npm install -g @bluefly/openstandardagents
339
+ \`\`\`
340
+
341
+ ## Quick Start
342
+
343
+ \`\`\`bash
344
+ # Validate an agent manifest
345
+ ossa validate agent.ossa.yaml
346
+
347
+ # Generate a new agent
348
+ ossa generate worker --name "My Agent"
349
+
350
+ # Run an agent locally
351
+ ossa run agent.ossa.yaml
352
+ \`\`\`
353
+
354
+ ## Commands
355
+
356
+ ${Object.entries(COMMANDS).map(([name, cmd]) => {
357
+ return `### [ossa ${name}](./ossa-${name}.md)\n\n${cmd.description}\n`;
358
+ }).join('\n')}
359
+
360
+ ## Global Options
361
+
362
+ - \`--help\` - Show help for any command
363
+ - \`--version\` - Show OSSA CLI version
364
+ - \`--config <path>\` - Path to config file
365
+ - \`--verbose\` - Enable verbose logging
366
+ - \`--quiet\` - Suppress output
367
+
368
+ ## Configuration
369
+
370
+ The OSSA CLI can be configured via:
371
+
372
+ 1. **Config file**: \`.ossarc.json\` or \`.ossarc.yaml\`
373
+ 2. **Environment variables**: \`OSSA_*\`
374
+ 3. **Command-line flags**
375
+
376
+ Example \`.ossarc.json\`:
377
+
378
+ \`\`\`json
379
+ {
380
+ "registry": "https://registry.ossa.dev",
381
+ "defaultVersion": "0.2.5-RC",
382
+ "validation": {
383
+ "strict": true
384
+ }
385
+ }
386
+ \`\`\`
387
+
388
+ ## Environment Variables
389
+
390
+ - \`OSSA_REGISTRY\` - Agent registry URL
391
+ - \`OSSA_API_KEY\` - API authentication key
392
+ - \`OSSA_VERSION\` - Default OSSA version
393
+ - \`OSSA_DEBUG\` - Enable debug mode
394
+
395
+ ## Related Documentation
396
+
397
+ - [API Reference](../api-reference/index.md)
398
+ - [Schema Reference](../schema-reference/index.md)
399
+ - [Getting Started](../getting-started/index.md)
400
+ - [Guides](../guides/index.md)
401
+ `;
402
+
403
+ writeFileSync(join(OUTPUT_DIR, 'index.md'), indexContent);
404
+ console.log(`✅ Generated: index.md`);
405
+
406
+ console.log(`\n✨ CLI documentation generated successfully!`);
407
+ console.log(`📂 Output: ${OUTPUT_DIR}`);
408
+ }
409
+
410
+ main();
@@ -0,0 +1,109 @@
1
+ #!/usr/bin/env tsx
2
+ import { writeFileSync, mkdirSync } from 'fs';
3
+ import { join } from 'path';
4
+
5
+ const OUTPUT_FILE = join(process.cwd(), 'website/content/docs/configuration/index.md');
6
+
7
+ const doc = `# Configuration Reference
8
+
9
+ Configure OSSA CLI and runtime behavior.
10
+
11
+ ## Configuration File
12
+
13
+ Create \`.ossarc.json\` or \`.ossarc.yaml\` in your project root:
14
+
15
+ \`\`\`json
16
+ {
17
+ "registry": "https://registry.ossa.dev",
18
+ "defaultVersion": "0.2.5-RC",
19
+ "validation": {
20
+ "strict": true,
21
+ "allowUnknownFields": false
22
+ },
23
+ "runtime": {
24
+ "timeout": 30000,
25
+ "retries": 3
26
+ }
27
+ }
28
+ \`\`\`
29
+
30
+ ## Configuration Options
31
+
32
+ ### registry
33
+ - **Type**: \`string\`
34
+ - **Default**: \`"https://registry.ossa.dev"\`
35
+ - **Description**: Agent registry URL
36
+
37
+ ### defaultVersion
38
+ - **Type**: \`string\`
39
+ - **Default**: \`"latest"\`
40
+ - **Description**: Default OSSA schema version
41
+
42
+ ### validation.strict
43
+ - **Type**: \`boolean\`
44
+ - **Default**: \`false\`
45
+ - **Description**: Enable strict validation mode
46
+
47
+ ### validation.allowUnknownFields
48
+ - **Type**: \`boolean\`
49
+ - **Default**: \`true\`
50
+ - **Description**: Allow unknown fields in manifests
51
+
52
+ ### runtime.timeout
53
+ - **Type**: \`number\`
54
+ - **Default**: \`30000\`
55
+ - **Description**: Execution timeout in milliseconds
56
+
57
+ ### runtime.retries
58
+ - **Type**: \`number\`
59
+ - **Default**: \`3\`
60
+ - **Description**: Number of retry attempts
61
+
62
+ ## Environment Variables
63
+
64
+ Override configuration with environment variables:
65
+
66
+ - \`OSSA_REGISTRY\` - Registry URL
67
+ - \`OSSA_VERSION\` - Default version
68
+ - \`OSSA_API_KEY\` - API authentication key
69
+ - \`OSSA_DEBUG\` - Enable debug logging
70
+
71
+ ## Examples
72
+
73
+ ### Development Configuration
74
+
75
+ \`\`\`json
76
+ {
77
+ "registry": "http://localhost:3000",
78
+ "validation": {
79
+ "strict": false
80
+ }
81
+ }
82
+ \`\`\`
83
+
84
+ ### Production Configuration
85
+
86
+ \`\`\`json
87
+ {
88
+ "registry": "https://registry.ossa.dev",
89
+ "validation": {
90
+ "strict": true,
91
+ "allowUnknownFields": false
92
+ },
93
+ "runtime": {
94
+ "timeout": 60000,
95
+ "retries": 5
96
+ }
97
+ }
98
+ \`\`\`
99
+
100
+ ## Related
101
+
102
+ - [CLI Reference](../cli-reference/)
103
+ - [Environment Setup](../getting-started/installation)
104
+ `;
105
+
106
+ mkdirSync(join(process.cwd(), 'website/content/docs/configuration'), { recursive: true });
107
+ writeFileSync(OUTPUT_FILE, doc);
108
+
109
+ console.log(`✅ Generated configuration reference`);
@@ -0,0 +1,76 @@
1
+ #!/usr/bin/env tsx
2
+ import { readdirSync, readFileSync, writeFileSync, mkdirSync } from 'fs';
3
+ import { join } from 'path';
4
+
5
+ const SRC_DIR = join(process.cwd(), 'src');
6
+ const OUTPUT_FILE = join(process.cwd(), 'website/content/docs/errors/index.md');
7
+
8
+ interface ErrorInfo {
9
+ code: string;
10
+ message: string;
11
+ file: string;
12
+ }
13
+
14
+ function findErrors(dir: string, errors: ErrorInfo[] = []): ErrorInfo[] {
15
+ const entries = readdirSync(dir, { withFileTypes: true });
16
+
17
+ for (const entry of entries) {
18
+ const fullPath = join(dir, entry.name);
19
+
20
+ if (entry.isDirectory()) {
21
+ findErrors(fullPath, errors);
22
+ } else if (entry.name.endsWith('.ts')) {
23
+ const content = readFileSync(fullPath, 'utf-8');
24
+
25
+ // Find throw new Error patterns
26
+ const matches = content.matchAll(/throw new (\w+Error)\(['"`]([^'"`]+)['"`]\)/g);
27
+ for (const match of matches) {
28
+ errors.push({
29
+ code: match[1],
30
+ message: match[2],
31
+ file: fullPath.replace(process.cwd(), '')
32
+ });
33
+ }
34
+ }
35
+ }
36
+
37
+ return errors;
38
+ }
39
+
40
+ const errors = findErrors(SRC_DIR);
41
+ const byCode = errors.reduce((acc, err) => {
42
+ if (!acc[err.code]) acc[err.code] = [];
43
+ acc[err.code].push(err);
44
+ return acc;
45
+ }, {} as Record<string, ErrorInfo[]>);
46
+
47
+ let doc = `# Error Reference
48
+
49
+ Common errors and solutions.
50
+
51
+ **Total Error Types**: ${Object.keys(byCode).length}
52
+
53
+ `;
54
+
55
+ for (const [code, instances] of Object.entries(byCode).sort()) {
56
+ doc += `## ${code}\n\n`;
57
+
58
+ const uniqueMessages = [...new Set(instances.map(e => e.message))];
59
+ for (const msg of uniqueMessages) {
60
+ doc += `### "${msg}"\n\n`;
61
+ doc += `**Cause**: Check the error context for details\n\n`;
62
+ doc += `**Solution**: \n`;
63
+ doc += `\`\`\`bash\n# Enable debug mode\nDEBUG=* ossa <command>\n\`\`\`\n\n`;
64
+ }
65
+ }
66
+
67
+ doc += `## Getting Help
68
+
69
+ - Check [Troubleshooting Guide](../troubleshooting/)
70
+ - Open an issue on [GitLab](https://gitlab.com/blueflyio/openstandardagents/-/issues)
71
+ `;
72
+
73
+ mkdirSync(join(process.cwd(), 'website/content/docs/errors'), { recursive: true });
74
+ writeFileSync(OUTPUT_FILE, doc);
75
+
76
+ console.log(`✅ Generated error reference: ${Object.keys(byCode).length} error types`);
@@ -0,0 +1,99 @@
1
+ #!/usr/bin/env tsx
2
+ /**
3
+ * Generate examples documentation from YAML files
4
+ */
5
+
6
+ import { readdirSync, readFileSync, writeFileSync, statSync, mkdirSync } from 'fs';
7
+ import { join, relative, basename } from 'path';
8
+ import yaml from 'js-yaml';
9
+
10
+ const EXAMPLES_DIR = join(process.cwd(), 'examples');
11
+ const OUTPUT_FILE = join(process.cwd(), 'website/content/docs/examples/catalog.md');
12
+
13
+ interface Example {
14
+ path: string;
15
+ name: string;
16
+ role?: string;
17
+ description?: string;
18
+ category: string;
19
+ }
20
+
21
+ function findYamlFiles(dir: string, category: string = ''): Example[] {
22
+ const examples: Example[] = [];
23
+ const entries = readdirSync(dir);
24
+
25
+ for (const entry of entries) {
26
+ const fullPath = join(dir, entry);
27
+ const stat = statSync(fullPath);
28
+
29
+ if (stat.isDirectory()) {
30
+ examples.push(...findYamlFiles(fullPath, category || entry));
31
+ } else if (entry.match(/\.(yaml|yml)$/)) {
32
+ try {
33
+ const content = readFileSync(fullPath, 'utf-8');
34
+ const data = yaml.load(content) as any;
35
+
36
+ if (data?.agent) {
37
+ examples.push({
38
+ path: relative(EXAMPLES_DIR, fullPath),
39
+ name: data.agent.name || basename(entry, '.yaml'),
40
+ role: data.agent.role,
41
+ description: data.agent.description,
42
+ category: category || 'general'
43
+ });
44
+ }
45
+ } catch (error) {
46
+ // Skip invalid YAML
47
+ }
48
+ }
49
+ }
50
+
51
+ return examples;
52
+ }
53
+
54
+ function generateDocs(examples: Example[]): string {
55
+ const byCategory = examples.reduce((acc, ex) => {
56
+ if (!acc[ex.category]) acc[ex.category] = [];
57
+ acc[ex.category].push(ex);
58
+ return acc;
59
+ }, {} as Record<string, Example[]>);
60
+
61
+ let doc = `# Examples Catalog
62
+
63
+ Auto-generated catalog of all OSSA agent examples.
64
+
65
+ **Total Examples**: ${examples.length}
66
+
67
+ `;
68
+
69
+ for (const [category, items] of Object.entries(byCategory).sort()) {
70
+ doc += `## ${category.charAt(0).toUpperCase() + category.slice(1)}\n\n`;
71
+
72
+ for (const item of items.sort((a, b) => a.name.localeCompare(b.name))) {
73
+ doc += `### ${item.name}\n\n`;
74
+ if (item.role) doc += `**Role**: \`${item.role}\`\n\n`;
75
+ if (item.description) doc += `${item.description}\n\n`;
76
+ doc += `**File**: [\`${item.path}\`](https://github.com/blueflyio/openstandardagents/blob/main/examples/${item.path})\n\n`;
77
+ doc += `\`\`\`bash\nossa validate examples/${item.path}\n\`\`\`\n\n`;
78
+ }
79
+ }
80
+
81
+ doc += `## Usage\n\n`;
82
+ doc += `\`\`\`bash\n# Validate any example\nossa validate examples/<path>\n\n`;
83
+ doc += `# Run an example\nossa run examples/<path>\n\`\`\`\n`;
84
+
85
+ return doc;
86
+ }
87
+
88
+ console.log('🚀 Generating examples documentation...\n');
89
+
90
+ const examples = findYamlFiles(EXAMPLES_DIR);
91
+ console.log(`📁 Found ${examples.length} examples\n`);
92
+
93
+ const doc = generateDocs(examples);
94
+
95
+ mkdirSync(join(process.cwd(), 'website/content/docs/examples'), { recursive: true });
96
+ writeFileSync(OUTPUT_FILE, doc);
97
+
98
+ console.log(`✅ Generated: ${relative(process.cwd(), OUTPUT_FILE)}`);
99
+ console.log(`\n✨ Examples documentation generated successfully!`);