@foresthubai/workflow-cli 0.3.0 → 0.4.1

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.
@@ -0,0 +1,300 @@
1
+ openapi: 3.0.3
2
+ info:
3
+ title: ForestHub -Proxy Contract
4
+ version: 0.1.0
5
+ description: OpenAPI schema definition for the ForestHub -Proxy API.
6
+
7
+ components:
8
+ schemas:
9
+ ContentType:
10
+ type: string
11
+ description: MIME type of a file.
12
+ enum: [text/plain, text/csv, image/png, image/jpeg, application/pdf, application/json, application/zip]
13
+
14
+ ModelCapability:
15
+ type: string
16
+ enum: [chat, embedding, function_call, vision, fine_tuning, reasoning, classification, code]
17
+
18
+ ModelInfo:
19
+ type: object
20
+ description: Information about an available LLM model.
21
+ required: [id, provider, label, capabilities, tokenModifier]
22
+ properties:
23
+ id:
24
+ type: string
25
+ description: Unique identifier of the model.
26
+ provider:
27
+ type: string
28
+ description: Provider that hosts the model.
29
+ label:
30
+ type: string
31
+ description: Human-readable model name.
32
+ capabilities:
33
+ type: array
34
+ description: Capabilities supported by the model.
35
+ items:
36
+ $ref: "#/components/schemas/ModelCapability"
37
+ tokenModifier:
38
+ type: number
39
+ format: float
40
+ description: Multiplier to apply to input token count when estimating usage for billing purposes (e.g. 1.2 means "20% more tokens than actual input count")
41
+ maxTokens:
42
+ type: integer
43
+ description: Maximum number of tokens supported by the model.
44
+ embeddingDimension:
45
+ type: integer
46
+ description: Dimension of the model's embedding output (only applicable for embedding-capable models)
47
+
48
+ ProviderInfo:
49
+ type: object
50
+ required: [id, models]
51
+ properties:
52
+ id:
53
+ type: string
54
+ description: Provider identifier (e.g. OpenAI, Anthropic, Local).
55
+ models:
56
+ type: array
57
+ description: Concrete models (only populated for Local provider).
58
+ items:
59
+ $ref: "#/components/schemas/ModelInfo"
60
+
61
+ Options:
62
+ type: object
63
+ description: Model generation options.
64
+ properties:
65
+ maxTokens:
66
+ type: integer
67
+ temperature:
68
+ type: number
69
+ format: float
70
+ topK:
71
+ type: integer
72
+ topP:
73
+ type: number
74
+ format: float
75
+ frequencyPenalty:
76
+ type: number
77
+ format: float
78
+ presencePenalty:
79
+ type: number
80
+ format: float
81
+ seed:
82
+ type: integer
83
+
84
+ ResponseFormat:
85
+ type: object
86
+ description: Structured response format for LLM outputs.
87
+ required: [name, schema]
88
+ properties:
89
+ name:
90
+ type: string
91
+ schema:
92
+ type: object
93
+ additionalProperties: true
94
+ description:
95
+ type: string
96
+
97
+ Tool:
98
+ oneOf:
99
+ - $ref: "#/components/schemas/ExternalTool"
100
+ - $ref: "#/components/schemas/WebSearchTool"
101
+ discriminator:
102
+ propertyName: type
103
+ mapping:
104
+ external: "#/components/schemas/ExternalTool"
105
+ web_search: "#/components/schemas/WebSearchTool"
106
+
107
+ ExternalTool:
108
+ type: object
109
+ description: An external tool that can be called by the model.
110
+ required: [type, name, parameters]
111
+ properties:
112
+ type:
113
+ type: string
114
+ enum: ["external"]
115
+ name:
116
+ type: string
117
+ description: Name of the tool.
118
+ description:
119
+ x-go-type-skip-optional-pointer: true
120
+ type: string
121
+ description: Description of the tool and its purpose.
122
+ parameters:
123
+ type: object
124
+ description: JSON schema describing the tool's parameters.
125
+ additionalProperties: true
126
+
127
+ WebSearchTool:
128
+ type: object
129
+ description: A built-in web search tool that allows the model to search the web.
130
+ required: [type]
131
+ properties:
132
+ type:
133
+ type: string
134
+ enum: ["web_search"]
135
+
136
+ Citation:
137
+ type: object
138
+ description: A source reference attached to a span of assistant-generated text.
139
+ required: [url]
140
+ properties:
141
+ url:
142
+ type: string
143
+ description: The cited source URL.
144
+ title:
145
+ type: string
146
+ description: The source's title.
147
+ snippet:
148
+ type: string
149
+ description: The cited text excerpt from the source.
150
+ startIdx:
151
+ type: integer
152
+ description: Start offset into the assistant message text.
153
+ endIdx:
154
+ type: integer
155
+ description: End offset into the assistant message text.
156
+
157
+ ToolCallRequest:
158
+ type: object
159
+ description: Request made by the model to call an external tool.
160
+ required: [callId, name, arguments]
161
+ properties:
162
+ callId:
163
+ type: string
164
+ description: Unique ID of the function tool call request.
165
+ name:
166
+ type: string
167
+ description: Name of the function tool called.
168
+ arguments:
169
+ x-go-type: json.RawMessage
170
+ type: object
171
+ description: Arguments passed to the function tool.
172
+ additionalProperties: true
173
+
174
+ ToolResult:
175
+ type: object
176
+ description: Result of an external tool execution.
177
+ required: [callId, name, output]
178
+ properties:
179
+ callId:
180
+ type: string
181
+ description: Unique ID of the external tool call request.
182
+ name:
183
+ type: string
184
+ description: Name of the external tool called.
185
+ output:
186
+ description: Output returned by the external tool.
187
+ additionalProperties: true
188
+
189
+ Input:
190
+ oneOf:
191
+ - $ref: "#/components/schemas/InputString"
192
+ - type: array
193
+ items:
194
+ oneOf:
195
+ - $ref: "#/components/schemas/InputString"
196
+ - $ref: "#/components/schemas/ToolCallRequest"
197
+ - $ref: "#/components/schemas/ToolResult"
198
+
199
+ InputString:
200
+ type: object
201
+ description: Input string to the model.
202
+ required: [value]
203
+ properties:
204
+ value:
205
+ type: string
206
+ description: The input text.
207
+
208
+ ChatRequest:
209
+ type: object
210
+ description: LLM response generation request.
211
+ required: [model, input]
212
+ properties:
213
+ model:
214
+ type: string
215
+ description: Model name.
216
+ input:
217
+ description: Runtime input to the model.
218
+ $ref: "#/components/schemas/Input"
219
+ systemPrompt:
220
+ x-go-type-skip-optional-pointer: true
221
+ type: string
222
+ maxLength: 100000
223
+ description: Overrides the model's default system prompt.
224
+ previousResponseID:
225
+ x-go-type-skip-optional-pointer: true
226
+ type: string
227
+ responseFormat:
228
+ $ref: "#/components/schemas/ResponseFormat"
229
+ tools:
230
+ x-go-type-skip-optional-pointer: true
231
+ type: array
232
+ items:
233
+ $ref: "#/components/schemas/Tool"
234
+ fileIDs:
235
+ x-go-type-skip-optional-pointer: true
236
+ type: array
237
+ items:
238
+ type: string
239
+ imageIDs:
240
+ x-go-type-skip-optional-pointer: true
241
+ type: array
242
+ items:
243
+ type: string
244
+ imageURLs:
245
+ x-go-type-skip-optional-pointer: true
246
+ type: array
247
+ items:
248
+ type: string
249
+ options:
250
+ $ref: "#/components/schemas/Options"
251
+
252
+ ChatResponse:
253
+ type: object
254
+ description: LLM response.
255
+ required: [responseID, tokensUsed]
256
+ properties:
257
+ text:
258
+ type: string
259
+ x-go-type-skip-optional-pointer: true
260
+ citations:
261
+ x-go-type-skip-optional-pointer: true
262
+ type: array
263
+ items:
264
+ $ref: "#/components/schemas/Citation"
265
+ toolCallRequests:
266
+ x-go-type-skip-optional-pointer: true
267
+ type: array
268
+ items:
269
+ $ref: "#/components/schemas/ToolCallRequest"
270
+ responseID:
271
+ type: string
272
+ tokensUsed:
273
+ type: integer
274
+
275
+ FileUploadRequest:
276
+ type: object
277
+ description: File upload request.
278
+ required: [file, fileName, fileType, providerID]
279
+ properties:
280
+ file:
281
+ type: string
282
+ format: binary
283
+ fileName:
284
+ type: string
285
+ fileType:
286
+ $ref: "#/components/schemas/ContentType"
287
+ purpose:
288
+ type: string
289
+ providerID:
290
+ type: string
291
+
292
+ FileUpload:
293
+ type: object
294
+ description: Uploaded file result.
295
+ required: [fileID, fileName]
296
+ properties:
297
+ fileID:
298
+ type: string
299
+ fileName:
300
+ type: string