@outputai/cli 0.10.1-next.2cbd0a2.0 → 0.10.1-next.3d1f9bd.0
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.
- package/dist/api/http_client.js +2 -2
- package/dist/assets/docker/docker-compose-dev.yml +1 -1
- package/dist/generated/framework_version.json +1 -1
- package/dist/templates/agent_instructions/CLAUDE.md.template +1 -1
- package/dist/templates/project/src/clients/jina.ts.template +4 -4
- package/oclif.manifest.json +1 -1
- package/package.json +5 -5
package/dist/api/http_client.js
CHANGED
|
@@ -18,7 +18,7 @@ const apiState = {};
|
|
|
18
18
|
function getApi() {
|
|
19
19
|
if (!apiState.api) {
|
|
20
20
|
apiState.api = ky.create({
|
|
21
|
-
|
|
21
|
+
prefix: config.apiUrl,
|
|
22
22
|
timeout: config.requestTimeout,
|
|
23
23
|
retry: {
|
|
24
24
|
limit: 2,
|
|
@@ -28,7 +28,7 @@ function getApi() {
|
|
|
28
28
|
throwHttpErrors: false,
|
|
29
29
|
hooks: {
|
|
30
30
|
beforeRequest: [
|
|
31
|
-
request => {
|
|
31
|
+
({ request }) => {
|
|
32
32
|
if (config.apiToken) {
|
|
33
33
|
request.headers.set('Authorization', `Basic ${config.apiToken}`);
|
|
34
34
|
}
|
|
@@ -44,7 +44,7 @@ config/
|
|
|
44
44
|
## Key Conventions
|
|
45
45
|
|
|
46
46
|
- **Workflows are deterministic**: No I/O, no `Date.now()`, no `Math.random()` in `workflow.ts`. All side effects go in steps or evaluators.
|
|
47
|
-
- **HTTP clients**:
|
|
47
|
+
- **HTTP clients**: Use `outputFetch` or `createKyClient` from `@outputai/http` instead of raw `fetch` or `axios`. Requests are automatically traced; use `addRequestCost` when cost tracking is needed.
|
|
48
48
|
- **LLM calls**: Use `generateText` from `@outputai/llm` with `.prompt` files. Never call LLM APIs directly.
|
|
49
49
|
|
|
50
50
|
---
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { createKyClient } from '@outputai/http';
|
|
2
2
|
|
|
3
3
|
export interface JinaReaderResponse {
|
|
4
4
|
code: number;
|
|
@@ -12,13 +12,13 @@ export interface JinaReaderResponse {
|
|
|
12
12
|
};
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
const
|
|
16
|
-
|
|
15
|
+
const client = createKyClient( {
|
|
16
|
+
prefix: 'https://r.jina.ai',
|
|
17
17
|
timeout: 30000
|
|
18
18
|
} );
|
|
19
19
|
|
|
20
20
|
export async function fetchBlogContent( url: string ): Promise<JinaReaderResponse> {
|
|
21
|
-
const response = await
|
|
21
|
+
const response = await client.post( '', {
|
|
22
22
|
json: { url },
|
|
23
23
|
headers: {
|
|
24
24
|
'Accept': 'application/json',
|
package/oclif.manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@outputai/cli",
|
|
3
|
-
"version": "0.10.1-next.
|
|
3
|
+
"version": "0.10.1-next.3d1f9bd.0",
|
|
4
4
|
"description": "CLI for Output.ai workflow generation",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -33,14 +33,14 @@
|
|
|
33
33
|
"ink-spinner": "5.0.0",
|
|
34
34
|
"js-yaml": "4.1.1",
|
|
35
35
|
"json-schema-library": "11.4.0",
|
|
36
|
-
"ky": "
|
|
36
|
+
"ky": "2.0.2",
|
|
37
37
|
"react": "19.2.5",
|
|
38
38
|
"semver": "7.7.4",
|
|
39
39
|
"undici": "8.5.0",
|
|
40
40
|
"yaml": "^2.8.3",
|
|
41
|
-
"@outputai/
|
|
42
|
-
"@outputai/
|
|
43
|
-
"@outputai/
|
|
41
|
+
"@outputai/credentials": "0.10.1-next.3d1f9bd.0",
|
|
42
|
+
"@outputai/evals": "0.10.1-next.3d1f9bd.0",
|
|
43
|
+
"@outputai/llm": "0.10.1-next.3d1f9bd.0"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"@types/cli-progress": "3.11.6",
|