deepline 0.1.145 → 0.1.147
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/bundling-sources/apps/play-runner-workers/src/entry.ts +205 -75
- package/dist/bundling-sources/apps/play-runner-workers/src/runtime/dataset-handles.ts +8 -0
- package/dist/bundling-sources/apps/play-runner-workers/src/runtime/output-datasets.ts +363 -0
- package/dist/bundling-sources/apps/play-runner-workers/src/runtime/result-dataset-persistence.ts +50 -0
- package/dist/bundling-sources/sdk/src/release.ts +54 -21
- package/dist/bundling-sources/sdk/src/tool-output.ts +18 -7
- package/dist/bundling-sources/shared_libs/play-runtime/tool-result-types.ts +2 -1
- package/dist/bundling-sources/shared_libs/play-runtime/tool-result.ts +81 -5
- package/dist/cli/index.js +371 -41
- package/dist/cli/index.mjs +383 -53
- package/dist/index.d.mts +91 -89
- package/dist/index.d.ts +91 -89
- package/dist/index.js +545 -31
- package/dist/index.mjs +546 -32
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -2557,94 +2557,6 @@ type DeeplineGetterValueMap = {
|
|
|
2557
2557
|
type DeeplineGetterValue<TTarget extends DeeplineExtractorTarget = DeeplineExtractorTarget> = DeeplineGetterValueMap[TTarget];
|
|
2558
2558
|
declare function isDeeplineExtractorTarget(value: string): value is DeeplineExtractorTarget;
|
|
2559
2559
|
|
|
2560
|
-
type ToolResultExecutionMetadata = {
|
|
2561
|
-
idempotent: true;
|
|
2562
|
-
cached: boolean;
|
|
2563
|
-
source: 'live' | 'checkpoint' | 'cache';
|
|
2564
|
-
cacheKey?: string;
|
|
2565
|
-
};
|
|
2566
|
-
type ToolResultTargetMetadata = {
|
|
2567
|
-
value: unknown;
|
|
2568
|
-
path: string;
|
|
2569
|
-
};
|
|
2570
|
-
type ToolResultListMetadata = {
|
|
2571
|
-
path: string;
|
|
2572
|
-
count: number | null;
|
|
2573
|
-
keys: Record<string, string>;
|
|
2574
|
-
};
|
|
2575
|
-
type ToolResultExtractorDescriptor = {
|
|
2576
|
-
paths: readonly string[];
|
|
2577
|
-
transforms?: readonly string[];
|
|
2578
|
-
enum?: readonly string[];
|
|
2579
|
-
overrides?: readonly ToolResultExtractorOverride[];
|
|
2580
|
-
emailStatus?: EmailStatusExtractorConfig;
|
|
2581
|
-
};
|
|
2582
|
-
type ToolResultExtractorOverride = {
|
|
2583
|
-
paths: readonly string[];
|
|
2584
|
-
equals?: string | number | boolean | null;
|
|
2585
|
-
value: string | number | boolean | null;
|
|
2586
|
-
};
|
|
2587
|
-
type ToolResultTargetAccessor<T = unknown> = ToolResultTargetMetadata & {
|
|
2588
|
-
get(): T | null;
|
|
2589
|
-
};
|
|
2590
|
-
type ToolResultListAccessor<T = Record<string, unknown>, TKey extends string = string> = Omit<ToolResultListMetadata, 'keys'> & {
|
|
2591
|
-
keys: Partial<Record<TKey, string>> & Record<string, string>;
|
|
2592
|
-
get(): T[];
|
|
2593
|
-
};
|
|
2594
|
-
type ToolResponseEnvelope<TData = unknown, TMeta = Record<string, unknown>> = {
|
|
2595
|
-
raw: TData;
|
|
2596
|
-
meta?: TMeta;
|
|
2597
|
-
};
|
|
2598
|
-
type ToolExecuteResultBase<TResult = unknown, TMeta = Record<string, unknown>> = {
|
|
2599
|
-
status: string;
|
|
2600
|
-
job_id?: string;
|
|
2601
|
-
/** Deepline-owned execution/result metadata. */
|
|
2602
|
-
meta?: Record<string, unknown>;
|
|
2603
|
-
toolResponse: ToolResponseEnvelope<TResult, TMeta>;
|
|
2604
|
-
extractedValues: Record<string, ToolResultTargetAccessor>;
|
|
2605
|
-
extractedLists: Record<string, ToolResultListAccessor>;
|
|
2606
|
-
/** Convenience alias for play code. Serialized output uses toolResponse. */
|
|
2607
|
-
toolOutput: ToolResponseEnvelope<TResult, TMeta>;
|
|
2608
|
-
_metadata: {
|
|
2609
|
-
toolId: string;
|
|
2610
|
-
execution: ToolResultExecutionMetadata;
|
|
2611
|
-
targets: Record<string, {
|
|
2612
|
-
value: unknown;
|
|
2613
|
-
path: string;
|
|
2614
|
-
}>;
|
|
2615
|
-
extractors?: Record<string, ToolResultExtractorDescriptor>;
|
|
2616
|
-
lists: Record<string, {
|
|
2617
|
-
path: string;
|
|
2618
|
-
count: number | null;
|
|
2619
|
-
keys: Record<string, string>;
|
|
2620
|
-
}>;
|
|
2621
|
-
};
|
|
2622
|
-
};
|
|
2623
|
-
type ToolExecuteResultAccessors<TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = {
|
|
2624
|
-
extractedValues: {
|
|
2625
|
-
[K in keyof TExtracted]: ToolResultTargetAccessor<TExtracted[K]>;
|
|
2626
|
-
};
|
|
2627
|
-
extractedLists: {
|
|
2628
|
-
[K in keyof TLists]: ToolResultListAccessor<TLists[K]>;
|
|
2629
|
-
};
|
|
2630
|
-
};
|
|
2631
|
-
/**
|
|
2632
|
-
* Canonical result returned by Deepline tool execution.
|
|
2633
|
-
*
|
|
2634
|
-
* The top-level object is Deepline-owned execution metadata and semantic
|
|
2635
|
-
* extraction state. Raw tool/provider data lives under `toolResponse.raw`;
|
|
2636
|
-
* response metadata lives under `toolResponse.meta`. Semantic single-value
|
|
2637
|
-
* getters live under `extractedValues.<name>.get()`, and list getters live
|
|
2638
|
-
* under `extractedLists.<name>.get()`.
|
|
2639
|
-
*
|
|
2640
|
-
* Use extractors first when a tool contract exposes them. Drop to
|
|
2641
|
-
* `toolResponse.raw` when you need provider-specific fields or when debugging
|
|
2642
|
-
* from persisted run rows.
|
|
2643
|
-
*
|
|
2644
|
-
* @sdkReference runtime 200
|
|
2645
|
-
*/
|
|
2646
|
-
type ToolExecuteResult<TResult = unknown, TMeta = Record<string, unknown>, TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = ToolExecuteResultBase<TResult, TMeta> & ToolExecuteResultAccessors<TExtracted, TLists>;
|
|
2647
|
-
|
|
2648
2560
|
interface PlayR2FileRef {
|
|
2649
2561
|
storageKind: 'r2';
|
|
2650
2562
|
storageKey: string;
|
|
@@ -2747,6 +2659,94 @@ interface PlayDataset<T> extends AsyncIterable<T> {
|
|
|
2747
2659
|
};
|
|
2748
2660
|
}
|
|
2749
2661
|
|
|
2662
|
+
type ToolResultExecutionMetadata = {
|
|
2663
|
+
idempotent: true;
|
|
2664
|
+
cached: boolean;
|
|
2665
|
+
source: 'live' | 'checkpoint' | 'cache';
|
|
2666
|
+
cacheKey?: string;
|
|
2667
|
+
};
|
|
2668
|
+
type ToolResultTargetMetadata = {
|
|
2669
|
+
value: unknown;
|
|
2670
|
+
path: string;
|
|
2671
|
+
};
|
|
2672
|
+
type ToolResultListMetadata = {
|
|
2673
|
+
path: string;
|
|
2674
|
+
count: number | null;
|
|
2675
|
+
keys: Record<string, string>;
|
|
2676
|
+
};
|
|
2677
|
+
type ToolResultExtractorDescriptor = {
|
|
2678
|
+
paths: readonly string[];
|
|
2679
|
+
transforms?: readonly string[];
|
|
2680
|
+
enum?: readonly string[];
|
|
2681
|
+
overrides?: readonly ToolResultExtractorOverride[];
|
|
2682
|
+
emailStatus?: EmailStatusExtractorConfig;
|
|
2683
|
+
};
|
|
2684
|
+
type ToolResultExtractorOverride = {
|
|
2685
|
+
paths: readonly string[];
|
|
2686
|
+
equals?: string | number | boolean | null;
|
|
2687
|
+
value: string | number | boolean | null;
|
|
2688
|
+
};
|
|
2689
|
+
type ToolResultTargetAccessor<T = unknown> = ToolResultTargetMetadata & {
|
|
2690
|
+
get(): T | null;
|
|
2691
|
+
};
|
|
2692
|
+
type ToolResultListAccessor<T = Record<string, unknown>, TKey extends string = string> = Omit<ToolResultListMetadata, 'keys'> & {
|
|
2693
|
+
keys: Partial<Record<TKey, string>> & Record<string, string>;
|
|
2694
|
+
get(): PlayDataset<T>;
|
|
2695
|
+
};
|
|
2696
|
+
type ToolResponseEnvelope<TData = unknown, TMeta = Record<string, unknown>> = {
|
|
2697
|
+
raw: TData;
|
|
2698
|
+
meta?: TMeta;
|
|
2699
|
+
};
|
|
2700
|
+
type ToolExecuteResultBase<TResult = unknown, TMeta = Record<string, unknown>> = {
|
|
2701
|
+
status: string;
|
|
2702
|
+
job_id?: string;
|
|
2703
|
+
/** Deepline-owned execution/result metadata. */
|
|
2704
|
+
meta?: Record<string, unknown>;
|
|
2705
|
+
toolResponse: ToolResponseEnvelope<TResult, TMeta>;
|
|
2706
|
+
extractedValues: Record<string, ToolResultTargetAccessor>;
|
|
2707
|
+
extractedLists: Record<string, ToolResultListAccessor>;
|
|
2708
|
+
/** Convenience alias for play code. Serialized output uses toolResponse. */
|
|
2709
|
+
toolOutput: ToolResponseEnvelope<TResult, TMeta>;
|
|
2710
|
+
_metadata: {
|
|
2711
|
+
toolId: string;
|
|
2712
|
+
execution: ToolResultExecutionMetadata;
|
|
2713
|
+
targets: Record<string, {
|
|
2714
|
+
value: unknown;
|
|
2715
|
+
path: string;
|
|
2716
|
+
}>;
|
|
2717
|
+
extractors?: Record<string, ToolResultExtractorDescriptor>;
|
|
2718
|
+
lists: Record<string, {
|
|
2719
|
+
path: string;
|
|
2720
|
+
count: number | null;
|
|
2721
|
+
keys: Record<string, string>;
|
|
2722
|
+
}>;
|
|
2723
|
+
};
|
|
2724
|
+
};
|
|
2725
|
+
type ToolExecuteResultAccessors<TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = {
|
|
2726
|
+
extractedValues: {
|
|
2727
|
+
[K in keyof TExtracted]: ToolResultTargetAccessor<TExtracted[K]>;
|
|
2728
|
+
};
|
|
2729
|
+
extractedLists: {
|
|
2730
|
+
[K in keyof TLists]: ToolResultListAccessor<TLists[K]>;
|
|
2731
|
+
};
|
|
2732
|
+
};
|
|
2733
|
+
/**
|
|
2734
|
+
* Canonical result returned by Deepline tool execution.
|
|
2735
|
+
*
|
|
2736
|
+
* The top-level object is Deepline-owned execution metadata and semantic
|
|
2737
|
+
* extraction state. Raw tool/provider data lives under `toolResponse.raw`;
|
|
2738
|
+
* response metadata lives under `toolResponse.meta`. Semantic single-value
|
|
2739
|
+
* getters live under `extractedValues.<name>.get()`, and list getters live
|
|
2740
|
+
* under `extractedLists.<name>.get()`.
|
|
2741
|
+
*
|
|
2742
|
+
* Use extractors first when a tool contract exposes them. Drop to
|
|
2743
|
+
* `toolResponse.raw` when you need provider-specific fields or when debugging
|
|
2744
|
+
* from persisted run rows.
|
|
2745
|
+
*
|
|
2746
|
+
* @sdkReference runtime 200
|
|
2747
|
+
*/
|
|
2748
|
+
type ToolExecuteResult<TResult = unknown, TMeta = Record<string, unknown>, TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = ToolExecuteResultBase<TResult, TMeta> & ToolExecuteResultAccessors<TExtracted, TLists>;
|
|
2749
|
+
|
|
2750
2750
|
/**
|
|
2751
2751
|
* Previous durable cell value passed to object-column resolvers.
|
|
2752
2752
|
*
|
|
@@ -4040,7 +4040,9 @@ declare function writeJsonOutputFile(payload: unknown, stem: string): string;
|
|
|
4040
4040
|
* }
|
|
4041
4041
|
* ```
|
|
4042
4042
|
*/
|
|
4043
|
-
declare function writeCsvOutputFile(rows: Array<Record<string, unknown>>, stem: string
|
|
4043
|
+
declare function writeCsvOutputFile(rows: Array<Record<string, unknown>>, stem: string, options?: {
|
|
4044
|
+
outPath?: string;
|
|
4045
|
+
}): {
|
|
4044
4046
|
path: string;
|
|
4045
4047
|
rowCount: number;
|
|
4046
4048
|
columns: string[];
|
package/dist/index.d.ts
CHANGED
|
@@ -2557,94 +2557,6 @@ type DeeplineGetterValueMap = {
|
|
|
2557
2557
|
type DeeplineGetterValue<TTarget extends DeeplineExtractorTarget = DeeplineExtractorTarget> = DeeplineGetterValueMap[TTarget];
|
|
2558
2558
|
declare function isDeeplineExtractorTarget(value: string): value is DeeplineExtractorTarget;
|
|
2559
2559
|
|
|
2560
|
-
type ToolResultExecutionMetadata = {
|
|
2561
|
-
idempotent: true;
|
|
2562
|
-
cached: boolean;
|
|
2563
|
-
source: 'live' | 'checkpoint' | 'cache';
|
|
2564
|
-
cacheKey?: string;
|
|
2565
|
-
};
|
|
2566
|
-
type ToolResultTargetMetadata = {
|
|
2567
|
-
value: unknown;
|
|
2568
|
-
path: string;
|
|
2569
|
-
};
|
|
2570
|
-
type ToolResultListMetadata = {
|
|
2571
|
-
path: string;
|
|
2572
|
-
count: number | null;
|
|
2573
|
-
keys: Record<string, string>;
|
|
2574
|
-
};
|
|
2575
|
-
type ToolResultExtractorDescriptor = {
|
|
2576
|
-
paths: readonly string[];
|
|
2577
|
-
transforms?: readonly string[];
|
|
2578
|
-
enum?: readonly string[];
|
|
2579
|
-
overrides?: readonly ToolResultExtractorOverride[];
|
|
2580
|
-
emailStatus?: EmailStatusExtractorConfig;
|
|
2581
|
-
};
|
|
2582
|
-
type ToolResultExtractorOverride = {
|
|
2583
|
-
paths: readonly string[];
|
|
2584
|
-
equals?: string | number | boolean | null;
|
|
2585
|
-
value: string | number | boolean | null;
|
|
2586
|
-
};
|
|
2587
|
-
type ToolResultTargetAccessor<T = unknown> = ToolResultTargetMetadata & {
|
|
2588
|
-
get(): T | null;
|
|
2589
|
-
};
|
|
2590
|
-
type ToolResultListAccessor<T = Record<string, unknown>, TKey extends string = string> = Omit<ToolResultListMetadata, 'keys'> & {
|
|
2591
|
-
keys: Partial<Record<TKey, string>> & Record<string, string>;
|
|
2592
|
-
get(): T[];
|
|
2593
|
-
};
|
|
2594
|
-
type ToolResponseEnvelope<TData = unknown, TMeta = Record<string, unknown>> = {
|
|
2595
|
-
raw: TData;
|
|
2596
|
-
meta?: TMeta;
|
|
2597
|
-
};
|
|
2598
|
-
type ToolExecuteResultBase<TResult = unknown, TMeta = Record<string, unknown>> = {
|
|
2599
|
-
status: string;
|
|
2600
|
-
job_id?: string;
|
|
2601
|
-
/** Deepline-owned execution/result metadata. */
|
|
2602
|
-
meta?: Record<string, unknown>;
|
|
2603
|
-
toolResponse: ToolResponseEnvelope<TResult, TMeta>;
|
|
2604
|
-
extractedValues: Record<string, ToolResultTargetAccessor>;
|
|
2605
|
-
extractedLists: Record<string, ToolResultListAccessor>;
|
|
2606
|
-
/** Convenience alias for play code. Serialized output uses toolResponse. */
|
|
2607
|
-
toolOutput: ToolResponseEnvelope<TResult, TMeta>;
|
|
2608
|
-
_metadata: {
|
|
2609
|
-
toolId: string;
|
|
2610
|
-
execution: ToolResultExecutionMetadata;
|
|
2611
|
-
targets: Record<string, {
|
|
2612
|
-
value: unknown;
|
|
2613
|
-
path: string;
|
|
2614
|
-
}>;
|
|
2615
|
-
extractors?: Record<string, ToolResultExtractorDescriptor>;
|
|
2616
|
-
lists: Record<string, {
|
|
2617
|
-
path: string;
|
|
2618
|
-
count: number | null;
|
|
2619
|
-
keys: Record<string, string>;
|
|
2620
|
-
}>;
|
|
2621
|
-
};
|
|
2622
|
-
};
|
|
2623
|
-
type ToolExecuteResultAccessors<TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = {
|
|
2624
|
-
extractedValues: {
|
|
2625
|
-
[K in keyof TExtracted]: ToolResultTargetAccessor<TExtracted[K]>;
|
|
2626
|
-
};
|
|
2627
|
-
extractedLists: {
|
|
2628
|
-
[K in keyof TLists]: ToolResultListAccessor<TLists[K]>;
|
|
2629
|
-
};
|
|
2630
|
-
};
|
|
2631
|
-
/**
|
|
2632
|
-
* Canonical result returned by Deepline tool execution.
|
|
2633
|
-
*
|
|
2634
|
-
* The top-level object is Deepline-owned execution metadata and semantic
|
|
2635
|
-
* extraction state. Raw tool/provider data lives under `toolResponse.raw`;
|
|
2636
|
-
* response metadata lives under `toolResponse.meta`. Semantic single-value
|
|
2637
|
-
* getters live under `extractedValues.<name>.get()`, and list getters live
|
|
2638
|
-
* under `extractedLists.<name>.get()`.
|
|
2639
|
-
*
|
|
2640
|
-
* Use extractors first when a tool contract exposes them. Drop to
|
|
2641
|
-
* `toolResponse.raw` when you need provider-specific fields or when debugging
|
|
2642
|
-
* from persisted run rows.
|
|
2643
|
-
*
|
|
2644
|
-
* @sdkReference runtime 200
|
|
2645
|
-
*/
|
|
2646
|
-
type ToolExecuteResult<TResult = unknown, TMeta = Record<string, unknown>, TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = ToolExecuteResultBase<TResult, TMeta> & ToolExecuteResultAccessors<TExtracted, TLists>;
|
|
2647
|
-
|
|
2648
2560
|
interface PlayR2FileRef {
|
|
2649
2561
|
storageKind: 'r2';
|
|
2650
2562
|
storageKey: string;
|
|
@@ -2747,6 +2659,94 @@ interface PlayDataset<T> extends AsyncIterable<T> {
|
|
|
2747
2659
|
};
|
|
2748
2660
|
}
|
|
2749
2661
|
|
|
2662
|
+
type ToolResultExecutionMetadata = {
|
|
2663
|
+
idempotent: true;
|
|
2664
|
+
cached: boolean;
|
|
2665
|
+
source: 'live' | 'checkpoint' | 'cache';
|
|
2666
|
+
cacheKey?: string;
|
|
2667
|
+
};
|
|
2668
|
+
type ToolResultTargetMetadata = {
|
|
2669
|
+
value: unknown;
|
|
2670
|
+
path: string;
|
|
2671
|
+
};
|
|
2672
|
+
type ToolResultListMetadata = {
|
|
2673
|
+
path: string;
|
|
2674
|
+
count: number | null;
|
|
2675
|
+
keys: Record<string, string>;
|
|
2676
|
+
};
|
|
2677
|
+
type ToolResultExtractorDescriptor = {
|
|
2678
|
+
paths: readonly string[];
|
|
2679
|
+
transforms?: readonly string[];
|
|
2680
|
+
enum?: readonly string[];
|
|
2681
|
+
overrides?: readonly ToolResultExtractorOverride[];
|
|
2682
|
+
emailStatus?: EmailStatusExtractorConfig;
|
|
2683
|
+
};
|
|
2684
|
+
type ToolResultExtractorOverride = {
|
|
2685
|
+
paths: readonly string[];
|
|
2686
|
+
equals?: string | number | boolean | null;
|
|
2687
|
+
value: string | number | boolean | null;
|
|
2688
|
+
};
|
|
2689
|
+
type ToolResultTargetAccessor<T = unknown> = ToolResultTargetMetadata & {
|
|
2690
|
+
get(): T | null;
|
|
2691
|
+
};
|
|
2692
|
+
type ToolResultListAccessor<T = Record<string, unknown>, TKey extends string = string> = Omit<ToolResultListMetadata, 'keys'> & {
|
|
2693
|
+
keys: Partial<Record<TKey, string>> & Record<string, string>;
|
|
2694
|
+
get(): PlayDataset<T>;
|
|
2695
|
+
};
|
|
2696
|
+
type ToolResponseEnvelope<TData = unknown, TMeta = Record<string, unknown>> = {
|
|
2697
|
+
raw: TData;
|
|
2698
|
+
meta?: TMeta;
|
|
2699
|
+
};
|
|
2700
|
+
type ToolExecuteResultBase<TResult = unknown, TMeta = Record<string, unknown>> = {
|
|
2701
|
+
status: string;
|
|
2702
|
+
job_id?: string;
|
|
2703
|
+
/** Deepline-owned execution/result metadata. */
|
|
2704
|
+
meta?: Record<string, unknown>;
|
|
2705
|
+
toolResponse: ToolResponseEnvelope<TResult, TMeta>;
|
|
2706
|
+
extractedValues: Record<string, ToolResultTargetAccessor>;
|
|
2707
|
+
extractedLists: Record<string, ToolResultListAccessor>;
|
|
2708
|
+
/** Convenience alias for play code. Serialized output uses toolResponse. */
|
|
2709
|
+
toolOutput: ToolResponseEnvelope<TResult, TMeta>;
|
|
2710
|
+
_metadata: {
|
|
2711
|
+
toolId: string;
|
|
2712
|
+
execution: ToolResultExecutionMetadata;
|
|
2713
|
+
targets: Record<string, {
|
|
2714
|
+
value: unknown;
|
|
2715
|
+
path: string;
|
|
2716
|
+
}>;
|
|
2717
|
+
extractors?: Record<string, ToolResultExtractorDescriptor>;
|
|
2718
|
+
lists: Record<string, {
|
|
2719
|
+
path: string;
|
|
2720
|
+
count: number | null;
|
|
2721
|
+
keys: Record<string, string>;
|
|
2722
|
+
}>;
|
|
2723
|
+
};
|
|
2724
|
+
};
|
|
2725
|
+
type ToolExecuteResultAccessors<TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = {
|
|
2726
|
+
extractedValues: {
|
|
2727
|
+
[K in keyof TExtracted]: ToolResultTargetAccessor<TExtracted[K]>;
|
|
2728
|
+
};
|
|
2729
|
+
extractedLists: {
|
|
2730
|
+
[K in keyof TLists]: ToolResultListAccessor<TLists[K]>;
|
|
2731
|
+
};
|
|
2732
|
+
};
|
|
2733
|
+
/**
|
|
2734
|
+
* Canonical result returned by Deepline tool execution.
|
|
2735
|
+
*
|
|
2736
|
+
* The top-level object is Deepline-owned execution metadata and semantic
|
|
2737
|
+
* extraction state. Raw tool/provider data lives under `toolResponse.raw`;
|
|
2738
|
+
* response metadata lives under `toolResponse.meta`. Semantic single-value
|
|
2739
|
+
* getters live under `extractedValues.<name>.get()`, and list getters live
|
|
2740
|
+
* under `extractedLists.<name>.get()`.
|
|
2741
|
+
*
|
|
2742
|
+
* Use extractors first when a tool contract exposes them. Drop to
|
|
2743
|
+
* `toolResponse.raw` when you need provider-specific fields or when debugging
|
|
2744
|
+
* from persisted run rows.
|
|
2745
|
+
*
|
|
2746
|
+
* @sdkReference runtime 200
|
|
2747
|
+
*/
|
|
2748
|
+
type ToolExecuteResult<TResult = unknown, TMeta = Record<string, unknown>, TExtracted extends Record<string, unknown> = Partial<DeeplineGetterValueMap>, TLists extends Record<string, Record<string, unknown>> = Record<string, Record<string, unknown>>> = ToolExecuteResultBase<TResult, TMeta> & ToolExecuteResultAccessors<TExtracted, TLists>;
|
|
2749
|
+
|
|
2750
2750
|
/**
|
|
2751
2751
|
* Previous durable cell value passed to object-column resolvers.
|
|
2752
2752
|
*
|
|
@@ -4040,7 +4040,9 @@ declare function writeJsonOutputFile(payload: unknown, stem: string): string;
|
|
|
4040
4040
|
* }
|
|
4041
4041
|
* ```
|
|
4042
4042
|
*/
|
|
4043
|
-
declare function writeCsvOutputFile(rows: Array<Record<string, unknown>>, stem: string
|
|
4043
|
+
declare function writeCsvOutputFile(rows: Array<Record<string, unknown>>, stem: string, options?: {
|
|
4044
|
+
outPath?: string;
|
|
4045
|
+
}): {
|
|
4044
4046
|
path: string;
|
|
4045
4047
|
rowCount: number;
|
|
4046
4048
|
columns: string[];
|