@langchain/langgraph 0.1.6 → 0.1.7-rc.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.
- package/dist/channels/dynamic_barrier_value.cjs +8 -7
- package/dist/channels/dynamic_barrier_value.d.ts +8 -7
- package/dist/channels/dynamic_barrier_value.js +8 -7
- package/dist/channels/ephemeral_value.cjs +1 -0
- package/dist/channels/ephemeral_value.d.ts +1 -0
- package/dist/channels/ephemeral_value.js +1 -0
- package/dist/channels/last_value.cjs +1 -0
- package/dist/channels/last_value.d.ts +1 -0
- package/dist/channels/last_value.js +1 -0
- package/dist/channels/named_barrier_value.cjs +1 -0
- package/dist/channels/named_barrier_value.d.ts +1 -0
- package/dist/channels/named_barrier_value.js +1 -0
- package/dist/channels/topic.cjs +3 -0
- package/dist/channels/topic.d.ts +3 -0
- package/dist/channels/topic.js +3 -0
- package/dist/graph/index.d.ts +1 -1
- package/dist/web.d.ts +1 -1
- package/package.json +1 -1
|
@@ -8,13 +8,14 @@ function isWaitForNames(v) {
|
|
|
8
8
|
return v.__names !== undefined;
|
|
9
9
|
}
|
|
10
10
|
/**
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
11
|
+
* A channel that switches between two states
|
|
12
|
+
*
|
|
13
|
+
* - in the "priming" state it can't be read from.
|
|
14
|
+
* - if it receives a WaitForNames update, it switches to the "waiting" state.
|
|
15
|
+
* - in the "waiting" state it collects named values until all are received.
|
|
16
|
+
* - once all named values are received, it can be read once, and it switches
|
|
17
|
+
* back to the "priming" state.
|
|
18
|
+
* @internal
|
|
18
19
|
*/
|
|
19
20
|
class DynamicBarrierValue extends base_js_1.BaseChannel {
|
|
20
21
|
constructor() {
|
|
@@ -3,13 +3,14 @@ export interface WaitForNames<Value> {
|
|
|
3
3
|
__names: Value[];
|
|
4
4
|
}
|
|
5
5
|
/**
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
6
|
+
* A channel that switches between two states
|
|
7
|
+
*
|
|
8
|
+
* - in the "priming" state it can't be read from.
|
|
9
|
+
* - if it receives a WaitForNames update, it switches to the "waiting" state.
|
|
10
|
+
* - in the "waiting" state it collects named values until all are received.
|
|
11
|
+
* - once all named values are received, it can be read once, and it switches
|
|
12
|
+
* back to the "priming" state.
|
|
13
|
+
* @internal
|
|
13
14
|
*/
|
|
14
15
|
export declare class DynamicBarrierValue<Value> extends BaseChannel<void, Value | WaitForNames<Value>, [
|
|
15
16
|
Value[] | undefined,
|
|
@@ -5,13 +5,14 @@ function isWaitForNames(v) {
|
|
|
5
5
|
return v.__names !== undefined;
|
|
6
6
|
}
|
|
7
7
|
/**
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
* A channel that switches between two states
|
|
9
|
+
*
|
|
10
|
+
* - in the "priming" state it can't be read from.
|
|
11
|
+
* - if it receives a WaitForNames update, it switches to the "waiting" state.
|
|
12
|
+
* - in the "waiting" state it collects named values until all are received.
|
|
13
|
+
* - once all named values are received, it can be read once, and it switches
|
|
14
|
+
* back to the "priming" state.
|
|
15
|
+
* @internal
|
|
15
16
|
*/
|
|
16
17
|
export class DynamicBarrierValue extends BaseChannel {
|
|
17
18
|
constructor() {
|
|
@@ -5,6 +5,7 @@ const errors_js_1 = require("../errors.cjs");
|
|
|
5
5
|
const index_js_1 = require("./index.cjs");
|
|
6
6
|
/**
|
|
7
7
|
* Stores the value received in the step immediately preceding, clears after.
|
|
8
|
+
* @internal
|
|
8
9
|
*/
|
|
9
10
|
class EphemeralValue extends index_js_1.BaseChannel {
|
|
10
11
|
constructor(guard = true) {
|
|
@@ -2,6 +2,7 @@ import { EmptyChannelError, InvalidUpdateError } from "../errors.js";
|
|
|
2
2
|
import { BaseChannel } from "./index.js";
|
|
3
3
|
/**
|
|
4
4
|
* Stores the value received in the step immediately preceding, clears after.
|
|
5
|
+
* @internal
|
|
5
6
|
*/
|
|
6
7
|
export class EphemeralValue extends BaseChannel {
|
|
7
8
|
constructor(guard = true) {
|
|
@@ -9,6 +9,7 @@ const base_js_1 = require("./base.cjs");
|
|
|
9
9
|
* Since `update` is only called once per step and value can only be of length 1,
|
|
10
10
|
* LastValue always stores the last value of a single node. If multiple nodes attempt to
|
|
11
11
|
* write to this channel in a single step, an error will be thrown.
|
|
12
|
+
* @internal
|
|
12
13
|
*/
|
|
13
14
|
class LastValue extends base_js_1.BaseChannel {
|
|
14
15
|
constructor() {
|
|
@@ -5,6 +5,7 @@ import { BaseChannel } from "./base.js";
|
|
|
5
5
|
* Since `update` is only called once per step and value can only be of length 1,
|
|
6
6
|
* LastValue always stores the last value of a single node. If multiple nodes attempt to
|
|
7
7
|
* write to this channel in a single step, an error will be thrown.
|
|
8
|
+
* @internal
|
|
8
9
|
*/
|
|
9
10
|
export declare class LastValue<Value> extends BaseChannel<Value, Value, Value> {
|
|
10
11
|
lc_graph_name: string;
|
|
@@ -6,6 +6,7 @@ import { BaseChannel } from "./base.js";
|
|
|
6
6
|
* Since `update` is only called once per step and value can only be of length 1,
|
|
7
7
|
* LastValue always stores the last value of a single node. If multiple nodes attempt to
|
|
8
8
|
* write to this channel in a single step, an error will be thrown.
|
|
9
|
+
* @internal
|
|
9
10
|
*/
|
|
10
11
|
export class LastValue extends BaseChannel {
|
|
11
12
|
constructor() {
|
|
@@ -10,6 +10,7 @@ exports.areSetsEqual = areSetsEqual;
|
|
|
10
10
|
*
|
|
11
11
|
* This ensures that if node N and node M both write to channel C, the value of C will not be updated
|
|
12
12
|
* until N and M have completed updating.
|
|
13
|
+
* @internal
|
|
13
14
|
*/
|
|
14
15
|
class NamedBarrierValue extends base_js_1.BaseChannel {
|
|
15
16
|
constructor(names) {
|
|
@@ -5,6 +5,7 @@ export declare const areSetsEqual: <T>(a: Set<T>, b: Set<T>) => boolean;
|
|
|
5
5
|
*
|
|
6
6
|
* This ensures that if node N and node M both write to channel C, the value of C will not be updated
|
|
7
7
|
* until N and M have completed updating.
|
|
8
|
+
* @internal
|
|
8
9
|
*/
|
|
9
10
|
export declare class NamedBarrierValue<Value> extends BaseChannel<void, Value, Value[]> {
|
|
10
11
|
lc_graph_name: string;
|
|
@@ -6,6 +6,7 @@ export const areSetsEqual = (a, b) => a.size === b.size && [...a].every((value)
|
|
|
6
6
|
*
|
|
7
7
|
* This ensures that if node N and node M both write to channel C, the value of C will not be updated
|
|
8
8
|
* until N and M have completed updating.
|
|
9
|
+
* @internal
|
|
9
10
|
*/
|
|
10
11
|
export class NamedBarrierValue extends BaseChannel {
|
|
11
12
|
constructor(names) {
|
package/dist/channels/topic.cjs
CHANGED
package/dist/channels/topic.d.ts
CHANGED
package/dist/channels/topic.js
CHANGED
package/dist/graph/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { Annotation, type StateType, type UpdateType, AnnotationRoot, } from "./annotation.js";
|
|
1
|
+
export { Annotation, type StateType, type UpdateType, type NodeType, AnnotationRoot, StateDefinition, type SingleReducer, } from "./annotation.js";
|
|
2
2
|
export { END, START, Graph, type CompiledGraph } from "./graph.js";
|
|
3
3
|
export { type StateGraphArgs, StateGraph, type CompiledStateGraph, } from "./state.js";
|
|
4
4
|
export { MessageGraph, messagesStateReducer } from "./message.js";
|
package/dist/web.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { END, Graph, type StateGraphArgs, START, StateGraph, type CompiledStateGraph, MessageGraph, messagesStateReducer, Annotation, AnnotationRoot, type StateType, type UpdateType, type CompiledGraph, } from "./graph/index.js";
|
|
1
|
+
export { END, Graph, type StateGraphArgs, START, StateGraph, type CompiledStateGraph, MessageGraph, messagesStateReducer, Annotation, AnnotationRoot, type StateDefinition, type SingleReducer, type StateType, type UpdateType, type NodeType, type CompiledGraph, } from "./graph/index.js";
|
|
2
2
|
export { GraphRecursionError, GraphValueError, InvalidUpdateError, EmptyChannelError, } from "./errors.js";
|
|
3
3
|
export { BaseChannel, type BinaryOperator, BinaryOperatorAggregate, type AnyValue, type WaitForNames, type DynamicBarrierValue, type LastValue, type NamedBarrierValue, type Topic, } from "./channels/index.js";
|
|
4
4
|
export { type RetryPolicy } from "./pregel/utils.js";
|