@browserbasehq/orca 3.0.2-zod359 → 3.0.2-zod360
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/index.d.ts +13 -12
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ZodTypeAny, z, ZodObject, ZodRawShape, ZodError } from 'zod';
|
|
2
1
|
import * as z3 from 'zod/v3';
|
|
2
|
+
import { ZodTypeAny, z, ZodObject, ZodRawShape, ZodError } from 'zod';
|
|
3
3
|
import { ClientOptions as ClientOptions$2 } from '@anthropic-ai/sdk';
|
|
4
4
|
import { LanguageModelV2 } from '@ai-sdk/provider';
|
|
5
5
|
import { ClientOptions as ClientOptions$1 } from 'openai';
|
|
@@ -18,16 +18,6 @@ import { ChatCompletion } from 'openai/resources';
|
|
|
18
18
|
import { ToolSet as ToolSet$1 } from 'ai/dist';
|
|
19
19
|
import { Schema } from '@google/genai';
|
|
20
20
|
|
|
21
|
-
type StagehandZodSchema = ZodTypeAny | z3.ZodTypeAny;
|
|
22
|
-
type StagehandZodObject = ZodObject<ZodRawShape> | z3.ZodObject<z3.ZodRawShape>;
|
|
23
|
-
type InferStagehandSchema<T extends StagehandZodSchema> = T extends z3.ZodTypeAny ? z3.infer<T> : T extends ZodTypeAny ? z.infer<T> : never;
|
|
24
|
-
declare const isZod4Schema: (schema: StagehandZodSchema) => schema is ZodTypeAny & {
|
|
25
|
-
_zod: unknown;
|
|
26
|
-
};
|
|
27
|
-
declare const isZod3Schema: (schema: StagehandZodSchema) => schema is z3.ZodTypeAny;
|
|
28
|
-
type JsonSchemaDocument = Record<string, unknown>;
|
|
29
|
-
declare function toJsonSchema(schema: StagehandZodSchema): JsonSchemaDocument;
|
|
30
|
-
|
|
31
21
|
type AnthropicJsonSchemaObject = {
|
|
32
22
|
definitions?: {
|
|
33
23
|
MySchema?: {
|
|
@@ -79,6 +69,16 @@ type LogLine = {
|
|
|
79
69
|
};
|
|
80
70
|
type Logger = (logLine: LogLine) => void;
|
|
81
71
|
|
|
72
|
+
type StagehandZodSchema = ZodTypeAny | z3.ZodTypeAny;
|
|
73
|
+
type StagehandZodObject = ZodObject<ZodRawShape> | z3.ZodObject<z3.ZodRawShape>;
|
|
74
|
+
type InferStagehandSchema<T extends StagehandZodSchema> = T extends z3.ZodTypeAny ? z3.infer<T> : T extends ZodTypeAny ? z.infer<T> : never;
|
|
75
|
+
declare const isZod4Schema: (schema: StagehandZodSchema) => schema is ZodTypeAny & {
|
|
76
|
+
_zod: unknown;
|
|
77
|
+
};
|
|
78
|
+
declare const isZod3Schema: (schema: StagehandZodSchema) => schema is z3.ZodTypeAny;
|
|
79
|
+
type JsonSchemaDocument = Record<string, unknown>;
|
|
80
|
+
declare function toJsonSchema(schema: StagehandZodSchema): JsonSchemaDocument;
|
|
81
|
+
|
|
82
82
|
interface ChatMessage {
|
|
83
83
|
role: "system" | "user" | "assistant";
|
|
84
84
|
content: ChatMessageContent;
|
|
@@ -1981,7 +1981,8 @@ declare class V3 {
|
|
|
1981
1981
|
extract(): Promise<z.infer<typeof pageTextSchema>>;
|
|
1982
1982
|
extract(options: ExtractOptions): Promise<z.infer<typeof pageTextSchema>>;
|
|
1983
1983
|
extract(instruction: string, options?: ExtractOptions): Promise<z.infer<typeof defaultExtractSchema>>;
|
|
1984
|
-
extract<T extends
|
|
1984
|
+
extract<T extends z.ZodTypeAny>(instruction: string, schema: T, options?: ExtractOptions): Promise<z.infer<T>>;
|
|
1985
|
+
extract<T extends z3.ZodTypeAny>(instruction: string, schema: T, options?: ExtractOptions): Promise<z3.infer<T>>;
|
|
1985
1986
|
extract(instruction: string, schema: unknown, options?: ExtractOptions): Promise<unknown>;
|
|
1986
1987
|
/**
|
|
1987
1988
|
* Run an "observe" instruction through the ObserveHandler.
|
package/dist/index.js
CHANGED
package/package.json
CHANGED