@loopman/langchain-sdk 1.15.0 → 1.16.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/langgraph/index.js +1 -1
- package/dist/langgraph/loopman-validation-node.d.ts +3 -3
- package/dist/langgraph/loopman-validation-node.d.ts.map +1 -1
- package/dist/langgraph/loopman-validation-node.js +6 -15
- package/dist/langgraph/loopman-validation-node.js.map +1 -1
- package/dist/langgraph/types.d.ts +1 -5
- package/dist/langgraph/types.d.ts.map +1 -1
- package/dist/langgraph/types.js +1 -8
- package/dist/langgraph/types.js.map +1 -1
- package/dist/templates.json +4 -4
- package/examples/templates/langchain-full-review/package.json +1 -1
- package/examples/templates/langchain-tool-validation/package.json +1 -1
- package/examples/templates/langgraph-hello-world/index.ts +0 -1
- package/examples/templates/langgraph-hello-world/package.json +1 -1
- package/package.json +1 -1
package/dist/langgraph/index.js
CHANGED
|
@@ -13,5 +13,5 @@ export { createLoopmanConditionalEdge } from "./loopman-conditional-edge.js";
|
|
|
13
13
|
// Export context node
|
|
14
14
|
export { createLoopmanContextNode } from "./loopman-context-node.js";
|
|
15
15
|
// Export helper functions
|
|
16
|
-
export { enrichSystemPrompt, formatGuidelines, formatDecisionContext, hasLoopmanContext, getCriticalGuidelines, getLatestDecision, } from "./helpers
|
|
16
|
+
export { enrichSystemPrompt, formatGuidelines, formatDecisionContext, hasLoopmanContext, getCriticalGuidelines, getLatestDecision, } from "./helpers.js";
|
|
17
17
|
//# sourceMappingURL=index.js.map
|
|
@@ -56,9 +56,9 @@ export interface LoopmanValidationNodeConfig {
|
|
|
56
56
|
* 3. Polls until human decision is received
|
|
57
57
|
* 4. Automatically enriches state with guidelines and decisionContext
|
|
58
58
|
*
|
|
59
|
-
* **Works with any state**: This node reads `messages`
|
|
60
|
-
*
|
|
61
|
-
*
|
|
59
|
+
* **Works with any state**: This node reads `messages` from the state,
|
|
60
|
+
* and updates it with `loopmanTaskId`, `loopmanTaskStatus`, `guidelines`,
|
|
61
|
+
* and `decisionContext`. You can use your own custom state schema!
|
|
62
62
|
*
|
|
63
63
|
* **Context Enrichment**: After validation, this node automatically fetches
|
|
64
64
|
* and adds `guidelines` and `decisionContext` to the state, making them
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loopman-validation-node.d.ts","sourceRoot":"","sources":["../../src/langgraph/loopman-validation-node.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAG3C;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C,yCAAyC;IACzC,MAAM,EAAE,MAAM,CAAC;IACf,0BAA0B;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,4DAA4D;IAC5D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2DAA2D;IAC3D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,4DAA4D;IAC5D,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,2BAA2B;IAC3B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,6DAA6D;IAC7D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,+DAA+D;IAC/D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wDAAwD;IACxD,eAAe,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE,KAAK;QACrC,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,GAAG,CAAC;QACV,EAAE,EAAE,MAAM,CAAC;KACZ,GAAG,IAAI,CAAC;IACT,kFAAkF;IAClF,eAAe,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE,GAAG,KAAK,MAAM,CAAC,CAAC;IACpD,mFAAmF;IACnF,gBAAgB,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE,GAAG,KAAK,MAAM,CAAC,CAAC;IACrD,oFAAoF;IACpF,iBAAiB,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE,GAAG,KAAK,MAAM,CAAC,CAAC;IACtD,yEAAyE;IACzE,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,kGAAkG;IAClG,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,eAAe,EAAE,CAAC;CACjD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AACH,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,2BAA2B,IAerB,OAAO,GAAG,
|
|
1
|
+
{"version":3,"file":"loopman-validation-node.d.ts","sourceRoot":"","sources":["../../src/langgraph/loopman-validation-node.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAG3C;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C,yCAAyC;IACzC,MAAM,EAAE,MAAM,CAAC;IACf,0BAA0B;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,4DAA4D;IAC5D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2DAA2D;IAC3D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,4DAA4D;IAC5D,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,2BAA2B;IAC3B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,6DAA6D;IAC7D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,+DAA+D;IAC/D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wDAAwD;IACxD,eAAe,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE,KAAK;QACrC,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,GAAG,CAAC;QACV,EAAE,EAAE,MAAM,CAAC;KACZ,GAAG,IAAI,CAAC;IACT,kFAAkF;IAClF,eAAe,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE,GAAG,KAAK,MAAM,CAAC,CAAC;IACpD,mFAAmF;IACnF,gBAAgB,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE,GAAG,KAAK,MAAM,CAAC,CAAC;IACrD,oFAAoF;IACpF,iBAAiB,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE,GAAG,KAAK,MAAM,CAAC,CAAC;IACtD,yEAAyE;IACzE,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,kGAAkG;IAClG,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,eAAe,EAAE,CAAC;CACjD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AACH,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,2BAA2B,IAerB,OAAO,GAAG,kBAyMzB"}
|
|
@@ -19,9 +19,9 @@ import { createLoopmanContextNode } from "./loopman-context-node.js";
|
|
|
19
19
|
* 3. Polls until human decision is received
|
|
20
20
|
* 4. Automatically enriches state with guidelines and decisionContext
|
|
21
21
|
*
|
|
22
|
-
* **Works with any state**: This node reads `messages`
|
|
23
|
-
*
|
|
24
|
-
*
|
|
22
|
+
* **Works with any state**: This node reads `messages` from the state,
|
|
23
|
+
* and updates it with `loopmanTaskId`, `loopmanTaskStatus`, `guidelines`,
|
|
24
|
+
* and `decisionContext`. You can use your own custom state schema!
|
|
25
25
|
*
|
|
26
26
|
* **Context Enrichment**: After validation, this node automatically fetches
|
|
27
27
|
* and adds `guidelines` and `decisionContext` to the state, making them
|
|
@@ -91,22 +91,17 @@ export function createLoopmanValidationNode(config) {
|
|
|
91
91
|
debug: config.debug,
|
|
92
92
|
});
|
|
93
93
|
return async (state) => {
|
|
94
|
-
const { messages,
|
|
94
|
+
const { messages, loopmanTaskId } = state;
|
|
95
95
|
const { debug } = config;
|
|
96
96
|
const logger = loopmanService.logger;
|
|
97
|
-
// Skip if validation not required
|
|
98
|
-
if (!requiresValidation) {
|
|
99
|
-
logger.debug("[LoopmanNode] Validation not required, skipping");
|
|
100
|
-
return {};
|
|
101
|
-
}
|
|
102
97
|
// Extract tool call from last message
|
|
103
98
|
const lastMessage = messages[messages.length - 1];
|
|
104
99
|
const toolCall = config.extractToolCall
|
|
105
100
|
? config.extractToolCall(messages)
|
|
106
101
|
: extractDefaultToolCall(lastMessage);
|
|
107
102
|
if (!toolCall) {
|
|
108
|
-
logger.warn("[LoopmanNode] No tool call found, skipping");
|
|
109
|
-
return {
|
|
103
|
+
logger.warn("[LoopmanNode] No tool call found, skipping validation");
|
|
104
|
+
return {};
|
|
110
105
|
}
|
|
111
106
|
// Step 1: Check if we're retrying an existing task (NEEDS_CHANGES scenario)
|
|
112
107
|
const isRetry = !!loopmanTaskId;
|
|
@@ -168,7 +163,6 @@ export function createLoopmanValidationNode(config) {
|
|
|
168
163
|
return {
|
|
169
164
|
loopmanTaskId: task.id,
|
|
170
165
|
loopmanTaskStatus: "TIMEOUT",
|
|
171
|
-
requiresValidation: false,
|
|
172
166
|
messages: [
|
|
173
167
|
new ToolMessage({
|
|
174
168
|
content: "Human validation timeout - task was not reviewed in time",
|
|
@@ -181,7 +175,6 @@ export function createLoopmanValidationNode(config) {
|
|
|
181
175
|
return {
|
|
182
176
|
loopmanTaskId: task.id,
|
|
183
177
|
loopmanTaskStatus: "ABORTED",
|
|
184
|
-
requiresValidation: false,
|
|
185
178
|
};
|
|
186
179
|
}
|
|
187
180
|
// Step 4: Get final task with decision
|
|
@@ -236,7 +229,6 @@ export function createLoopmanValidationNode(config) {
|
|
|
236
229
|
return {
|
|
237
230
|
loopmanTaskId: task.id,
|
|
238
231
|
loopmanTaskStatus: finalTask.status,
|
|
239
|
-
requiresValidation: false, // Reset flag
|
|
240
232
|
...contextUpdates, // Add guidelines and decisionContext if loaded
|
|
241
233
|
messages: buildDecisionMessages(finalTask.status, feedback, toolCall.id),
|
|
242
234
|
};
|
|
@@ -247,7 +239,6 @@ export function createLoopmanValidationNode(config) {
|
|
|
247
239
|
}
|
|
248
240
|
return {
|
|
249
241
|
loopmanTaskStatus: "ERROR",
|
|
250
|
-
requiresValidation: false,
|
|
251
242
|
messages: [
|
|
252
243
|
new ToolMessage({
|
|
253
244
|
content: `Error during validation: ${error.message}`,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loopman-validation-node.js","sourceRoot":"","sources":["../../src/langgraph/loopman-validation-node.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAE7D,OAAO,EAAE,wBAAwB,EAAE,MAAM,wBAAwB,CAAC;AA0ClE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AACH,MAAM,UAAU,2BAA2B,CACzC,MAAmC;IAEnC,8DAA8D;IAC9D,MAAM,WAAW,GAAG,MAAM,CAAC,WAAW,IAAI,QAAQ,IAAI,CAAC,GAAG,EAAE,EAAE,CAAC;IAE/D,iEAAiE;IACjE,MAAM,cAAc,GAAG,IAAI,cAAc,CAAC;QACxC,MAAM,EAAE,MAAM,CAAC,MAAM;QACrB,UAAU,EAAE,MAAM,CAAC,UAAU;QAC7B,WAAW,EAAE,WAAW;QACxB,OAAO,EAAE,MAAM,CAAC,OAAO;QACvB,eAAe,EAAE,MAAM,CAAC,eAAe;QACvC,KAAK,EAAE,MAAM,CAAC,KAAK;KACpB,CAAC,CAAC;IAEH,OAAO,KAAK,EAAE,KAAU,EAAE,EAAE;QAC1B,MAAM,EAAE,QAAQ,EAAE,
|
|
1
|
+
{"version":3,"file":"loopman-validation-node.js","sourceRoot":"","sources":["../../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O;gBACL,IAAI,WAAW,CAAC;oBACd,OAAO,EAAE,QAAQ;wBACf,CAAC,CAAC,wCAAwC,QAAQ,GAAG;wBACrD,CAAC,CAAC,wDAAwD;oBAC5D,YAAY,EAAE,UAAU;iBACzB,CAAC;aACH,CAAC;QAEJ,KAAK,eAAe;YAClB,OAAO;gBACL,IAAI,WAAW,CAAC;oBACd,OAAO,EAAE,QAAQ;wBACf,CAAC,CAAC,yCAAyC,QAAQ,GAAG;wBACtD,CAAC,CAAC,mEAAmE;oBACvE,YAAY,EAAE,UAAU;iBACzB,CAAC;aACH,CAAC;QAEJ,KAAK,SAAS;YACZ,OAAO;gBACL,IAAI,WAAW,CAAC;oBACd,OAAO,EAAE,0DAA0D;oBACnE,YAAY,EAAE,UAAU;iBACzB,CAAC;aACH,CAAC;QAEJ,KAAK,SAAS,CAAC;QACf,KAAK,OAAO,CAAC;QACb;YACE,OAAO;gBACL,IAAI,WAAW,CAAC;oBACd,OAAO,EAAE,sBAAsB,MAAM,EAAE;oBACvC,YAAY,EAAE,UAAU;iBACzB,CAAC;aACH,CAAC;IACN,CAAC;AACH,CAAC"}
|
|
@@ -42,7 +42,7 @@ export interface LoopmanDecision {
|
|
|
42
42
|
* myCustomField: Annotation<string>({ ... }),
|
|
43
43
|
* // Add only Loopman fields you need:
|
|
44
44
|
* guidelines: Annotation<LoopmanGuideline[]>({ ... }),
|
|
45
|
-
*
|
|
45
|
+
* loopmanTaskId: Annotation<string | null>({ ... }),
|
|
46
46
|
* });
|
|
47
47
|
* ```
|
|
48
48
|
*/
|
|
@@ -59,10 +59,6 @@ export declare const LoopmanGraphState: import("@langchain/langgraph").Annotatio
|
|
|
59
59
|
* Status of the Loopman task (APPROVED, REJECTED, NEEDS_CHANGES, etc.)
|
|
60
60
|
*/
|
|
61
61
|
loopmanTaskStatus: import("@langchain/langgraph").BinaryOperatorAggregate<string | null, string | null>;
|
|
62
|
-
/**
|
|
63
|
-
* Flag indicating if the current action requires validation
|
|
64
|
-
*/
|
|
65
|
-
requiresValidation: import("@langchain/langgraph").BinaryOperatorAggregate<boolean, boolean>;
|
|
66
62
|
/**
|
|
67
63
|
* Validation guidelines for the workflow
|
|
68
64
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/langgraph/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,QAAQ,EAAE,UAAU,GAAG,OAAO,GAAG,OAAO,CAAC;CAC1C;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,GAAG,QAAQ,CAAC;IAC5B,MAAM,EAAE,SAAS,GAAG,UAAU,GAAG,UAAU,GAAG,eAAe,CAAC;IAC9D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,iBAAiB;IAC5B;;OAEG;;IAMH;;OAEG;;IAMH;;OAEG;;IAMH;;OAEG;;IAMH;;OAEG;;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/langgraph/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,QAAQ,EAAE,UAAU,GAAG,OAAO,GAAG,OAAO,CAAC;CAC1C;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,GAAG,QAAQ,CAAC;IAC5B,MAAM,EAAE,SAAS,GAAG,UAAU,GAAG,UAAU,GAAG,eAAe,CAAC;IAC9D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,iBAAiB;IAC5B;;OAEG;;IAMH;;OAEG;;IAMH;;OAEG;;IAMH;;OAEG;;IAMH;;OAEG;;EAKH,CAAC"}
|
package/dist/langgraph/types.js
CHANGED
|
@@ -23,7 +23,7 @@ import { Annotation } from "@langchain/langgraph";
|
|
|
23
23
|
* myCustomField: Annotation<string>({ ... }),
|
|
24
24
|
* // Add only Loopman fields you need:
|
|
25
25
|
* guidelines: Annotation<LoopmanGuideline[]>({ ... }),
|
|
26
|
-
*
|
|
26
|
+
* loopmanTaskId: Annotation<string | null>({ ... }),
|
|
27
27
|
* });
|
|
28
28
|
* ```
|
|
29
29
|
*/
|
|
@@ -49,13 +49,6 @@ export const LoopmanGraphState = Annotation.Root({
|
|
|
49
49
|
reducer: (x, y) => y ?? x,
|
|
50
50
|
default: () => null,
|
|
51
51
|
}),
|
|
52
|
-
/**
|
|
53
|
-
* Flag indicating if the current action requires validation
|
|
54
|
-
*/
|
|
55
|
-
requiresValidation: Annotation({
|
|
56
|
-
reducer: (x, y) => y ?? x,
|
|
57
|
-
default: () => false,
|
|
58
|
-
}),
|
|
59
52
|
/**
|
|
60
53
|
* Validation guidelines for the workflow
|
|
61
54
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/langgraph/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAwBlD;;;;;;;;;;;;;;;;;;;;;;;;G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E,CAAC,IAAI;KACpB,CAAC;IAEF;;OAEG;IACH,iBAAiB,EAAE,UAAU,CAAgB;QAC3C,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC;QACzB,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI;KACpB,CAAC;IAEF;;OAEG;IACH,UAAU,EAAE,UAAU,CAAqB;QACzC,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC;QACzB,OAAO,EAAE,GAAG,EAAE,CAAC,EAAE;KAClB,CAAC;IAEF;;OAEG;IACH,eAAe,EAAE,UAAU,CAAoB;QAC7C,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC;QACzB,OAAO,EAAE,GAAG,EAAE,CAAC,EAAE;KAClB,CAAC;CACH,CAAC,CAAC"}
|
package/dist/templates.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"langgraph-hello-world": {
|
|
3
|
-
"index.ts": "import { HumanMessage, ToolMessage } from \"@langchain/core/messages\";\nimport { END, MemorySaver, START, StateGraph } from \"@langchain/langgraph\";\nimport { ChatOpenAI } from \"@langchain/openai\";\nimport { config } from \"dotenv\";\nimport { tool } from \"langchain\";\nimport * as z from \"zod\";\n\nimport {\n LoopmanGraphState,\n createLoopmanConditionalEdge,\n createLoopmanContextNode,\n createLoopmanValidationNode,\n enrichSystemPrompt,\n} from \"@loopman/langchain-sdk\";\n\nconfig();\n\n// Define your tools\nconst sayHello = tool(\n ({ name }) => {\n console.log(`Hello, ${name}!`);\n return `Hello, ${name}! Welcome to Loopman.`;\n },\n {\n name: \"say_hello\",\n description: \"Say hello to someone\",\n schema: z.object({\n name: z.string().describe(\"The name of the person to greet\"),\n }),\n }\n);\n\n// Agent node with context enrichment\nasync function agentNode(state: any) {\n const { messages, guidelines, decisionContext } = state;\n\n // Enrich system prompt with guidelines and decision history\n const systemPrompt = enrichSystemPrompt(\n \"You are a helpful assistant that greets people ....\",\n { guidelines, decisionContext },\n { maxDecisions: 3 }\n );\n\n const model = new ChatOpenAI({ model: \"gpt-4o-mini\" });\n const modelWithTools = model.bindTools([sayHello]);\n\n const messagesWithContext =\n (guidelines && guidelines.length > 0) ||\n (decisionContext && decisionContext.length > 0)\n ? [{ role: \"system\", content: systemPrompt }, ...messages]\n : messages;\n\n const response = await modelWithTools.invoke(messagesWithContext);\n\n return {\n messages: [response],\n
|
|
4
|
-
"package.json": "{\n \"name\": \"loopman-langgraph-hello-world\",\n \"version\": \"1.0.0\",\n \"description\": \"Loopman LangGraph Hello World Example\",\n \"main\": \"index.ts\",\n \"type\": \"module\",\n \"scripts\": {\n \"start\": \"tsx index.ts\",\n \"dev\": \"tsx index.ts\",\n \"build\": \"tsc\",\n \"run\": \"node dist/index.js\"\n },\n \"dependencies\": {\n \"@langchain/core\": \"^1.0.2\",\n \"@langchain/langgraph\": \"^1.0.1\",\n \"@langchain/openai\": \"^1.0.0\",\n \"@loopman/langchain-sdk\": \"^1.
|
|
3
|
+
"index.ts": "import { HumanMessage, ToolMessage } from \"@langchain/core/messages\";\nimport { END, MemorySaver, START, StateGraph } from \"@langchain/langgraph\";\nimport { ChatOpenAI } from \"@langchain/openai\";\nimport { config } from \"dotenv\";\nimport { tool } from \"langchain\";\nimport * as z from \"zod\";\n\nimport {\n LoopmanGraphState,\n createLoopmanConditionalEdge,\n createLoopmanContextNode,\n createLoopmanValidationNode,\n enrichSystemPrompt,\n} from \"@loopman/langchain-sdk\";\n\nconfig();\n\n// Define your tools\nconst sayHello = tool(\n ({ name }) => {\n console.log(`Hello, ${name}!`);\n return `Hello, ${name}! Welcome to Loopman.`;\n },\n {\n name: \"say_hello\",\n description: \"Say hello to someone\",\n schema: z.object({\n name: z.string().describe(\"The name of the person to greet\"),\n }),\n }\n);\n\n// Agent node with context enrichment\nasync function agentNode(state: any) {\n const { messages, guidelines, decisionContext } = state;\n\n // Enrich system prompt with guidelines and decision history\n const systemPrompt = enrichSystemPrompt(\n \"You are a helpful assistant that greets people ....\",\n { guidelines, decisionContext },\n { maxDecisions: 3 }\n );\n\n const model = new ChatOpenAI({ model: \"gpt-4o-mini\" });\n const modelWithTools = model.bindTools([sayHello]);\n\n const messagesWithContext =\n (guidelines && guidelines.length > 0) ||\n (decisionContext && decisionContext.length > 0)\n ? [{ role: \"system\", content: systemPrompt }, ...messages]\n : messages;\n\n const response = await modelWithTools.invoke(messagesWithContext);\n\n return {\n messages: [response],\n };\n}\n\n// Tool execution node\nasync function toolNode(state: any) {\n const { messages } = state;\n const lastMessage = messages[messages.length - 1];\n\n if (!lastMessage.tool_calls || lastMessage.tool_calls.length === 0) {\n return {};\n }\n\n const toolCall = lastMessage.tool_calls[0];\n const result = await sayHello.invoke(toolCall.args);\n\n return {\n messages: [\n new ToolMessage({\n content: result,\n tool_call_id: toolCall.id,\n }),\n ],\n };\n}\n\n// Build the graph with context loading\nconst workflow = new StateGraph(LoopmanGraphState)\n .addNode(\n \"load_context\",\n createLoopmanContextNode({\n apiKey: process.env.LOOPMAN_API_KEY!,\n workflowId: process.env.LOOPMAN_WORKFLOW_ID!,\n category: \"hello-world\",\n debug: true,\n })\n )\n .addNode(\"agent\", agentNode)\n .addNode(\n \"loopman_validation\",\n createLoopmanValidationNode({\n apiKey: process.env.LOOPMAN_API_KEY!,\n workflowId: process.env.LOOPMAN_WORKFLOW_ID!,\n debug: true,\n })\n )\n .addNode(\"tools\", toolNode)\n .addEdge(START, \"load_context\")\n .addEdge(\"load_context\", \"agent\")\n .addEdge(\"agent\", \"loopman_validation\")\n .addConditionalEdges(\n \"loopman_validation\",\n createLoopmanConditionalEdge({ debug: true }),\n {\n execute: \"tools\",\n rejected: END,\n retry: \"agent\",\n timeout: END,\n error: END,\n }\n )\n .addEdge(\"tools\", END);\n\n// Compile and run\nconst checkpointer = new MemorySaver();\nconst app = workflow.compile({ checkpointer });\n\nasync function main() {\n const config = { configurable: { thread_id: \"hello-world-thread\" } };\n const inputs = {\n messages: [new HumanMessage(\"Say hello to Alice\")],\n };\n\n console.log(\"Starting LangGraph workflow with context enrichment...\");\n\n for await (const output of await app.stream(inputs, config)) {\n const nodeName = Object.keys(output)[0];\n console.log(`Step: ${nodeName}`);\n }\n\n const finalState = await app.getState(config);\n console.log(\"Final status:\", finalState.values.loopmanTaskStatus);\n console.log(\"Guidelines loaded:\", finalState.values.guidelines?.length || 0);\n console.log(\n \"Decision context loaded:\",\n finalState.values.decisionContext?.length || 0\n );\n console.log(\"Workflow completed!\");\n}\n\nmain().catch(console.error);\n",
|
|
4
|
+
"package.json": "{\n \"name\": \"loopman-langgraph-hello-world\",\n \"version\": \"1.0.0\",\n \"description\": \"Loopman LangGraph Hello World Example\",\n \"main\": \"index.ts\",\n \"type\": \"module\",\n \"scripts\": {\n \"start\": \"tsx index.ts\",\n \"dev\": \"tsx index.ts\",\n \"build\": \"tsc\",\n \"run\": \"node dist/index.js\"\n },\n \"dependencies\": {\n \"@langchain/core\": \"^1.0.2\",\n \"@langchain/langgraph\": \"^1.0.1\",\n \"@langchain/openai\": \"^1.0.0\",\n \"@loopman/langchain-sdk\": \"^1.16.0\",\n \"dotenv\": \"^17.2.3\",\n \"langchain\": \"^1.0.2\",\n \"tsx\": \"^4.20.6\",\n \"typescript\": \"^5.9.3\",\n \"zod\": \"^3.25.76\"\n },\n \"devDependencies\": {\n \"@types/node\": \"^24.9.2\"\n }\n}\n",
|
|
5
5
|
"tsconfig.json": "{\n \"compilerOptions\": {\n \"target\": \"ES2022\",\n \"module\": \"ES2022\",\n \"lib\": [\"ES2022\"],\n \"moduleResolution\": \"bundler\",\n \"resolveJsonModule\": true,\n \"allowJs\": true,\n \"outDir\": \"./dist\",\n \"rootDir\": \"./\",\n \"strict\": true,\n \"esModuleInterop\": true,\n \"skipLibCheck\": true,\n \"forceConsistentCasingInFileNames\": true,\n \"declaration\": true,\n \"declarationMap\": true,\n \"sourceMap\": true\n },\n \"include\": [\"**/*.ts\"],\n \"exclude\": [\"node_modules\", \"dist\"]\n}\n\n",
|
|
6
6
|
"README.md": "# Loopman LangGraph Hello World\n\nThis project demonstrates how to integrate Loopman with LangGraph using Context Enrichment / Feedback Loop mode.\n\n## About LangGraph\n\nLangGraph is LangChain's official framework for building stateful, multi-actor applications with LLMs. It provides:\n\n- **Stateful workflows**: Explicit state management across nodes\n- **Conditional routing**: Dynamic edges based on state\n- **Streaming support**: Real-time updates during execution\n- **Visual debugging**: Graph visualization and inspection\n\n## Setup\n\n1. Install dependencies:\n```bash\nnpm install\n```\n\n2. Copy .env.example to .env and configure your keys:\n```bash\ncp .env.example .env\n```\n\nEdit the .env file and replace the placeholders with your actual values:\n- `OPENAI_API_KEY`: Your OpenAI API key\n- `LOOPMAN_API_KEY`: Your Loopman API key\n- `LOOPMAN_WORKFLOW_ID`: Your workflow ID from Loopman\n\n3. Run the example:\n```bash\nnpm start\n```\n\n## Graph Architecture\n\nThe workflow follows this pattern:\n\n```\nSTART\n ↓\nload_context (load guidelines and decision history)\n ↓\nagent (LLM decides action)\n ↓\nloopman_validation (create task + poll)\n ↓\n[conditional edge based on status]\n ↓\n├─→ tools (APPROVED: execute)\n├─→ agent (NEEDS_CHANGES: retry)\n└─→ END (REJECTED/TIMEOUT/ERROR: end)\n ↓\nEND\n```\n\n## Key Features\n\n- **Context Enrichment**: Loads validation guidelines and historical decisions\n- **Prompt Enhancement**: Automatically enriches system prompts with context\n- **Learning from History**: Agent learns from past human decisions\n- **Category Filtering**: Guidelines filtered by category for relevance\n- **Feedback Loop**: Human feedback is stored and used to improve future decisions\n\n## Learn More\n\n- [LangGraph Documentation](https://js.langchain.com/docs/langgraph/)\n- [Loopman LangGraph Integration Guide](https://github.com/loopman/loopman-langchain-sdk/blob/main/docs/LANGGRAPH_INTEGRATION.md)\n- [Loopman Documentation](https://loopman.dev/docs)\n\n"
|
|
7
7
|
},
|
|
8
8
|
"langchain-tool-validation": {
|
|
9
9
|
"index.ts": "import { MemorySaver } from \"@langchain/langgraph\";\nimport { config } from \"dotenv\";\nimport { createAgent, tool } from \"langchain\";\nimport * as z from \"zod\";\nimport { loopmanMiddleware } from \"@loopman/langchain-sdk\";\n\n// Load environment variables\nconfig();\n\n// Simple hello world tool\nconst sayHello = tool(\n ({ name }) => {\n console.log(`Hello, ${name}!`);\n return `Hello, ${name}! Welcome to Loopman.`;\n },\n {\n name: \"say_hello\",\n description: \"Say hello to someone\",\n schema: z.object({\n name: z.string().describe(\"The name of the person to greet\"),\n }),\n }\n);\n\n// Create agent with Loopman middleware\nconst checkpointer = new MemorySaver();\n\nconst agent = createAgent({\n model: \"openai:gpt-4o-mini\",\n systemPrompt: \"You are a helpful assistant that greets people.\",\n tools: [sayHello],\n middleware: [\n loopmanMiddleware({\n apiKey: process.env.LOOPMAN_API_KEY!,\n workflowId: process.env.LOOPMAN_WORKFLOW_ID!,\n interruptOn: {\n say_hello: true, // Requires human validation\n },\n debug: true,\n }),\n ],\n checkpointer,\n});\n\n// Run the agent\nasync function main() {\n const config = { configurable: { thread_id: \"hello-world-thread\" } };\n\n const result = await agent.invoke(\n {\n messages: [\n {\n role: \"user\",\n content: \"Say hello to Alice\",\n },\n ],\n },\n config\n );\n\n console.log(\"Agent response:\", result.messages[result.messages.length - 1].content);\n}\n\nmain().catch(console.error);\n\n",
|
|
10
|
-
"package.json": "{\n \"name\": \"loopman-langchain-tool-validation\",\n \"version\": \"1.0.0\",\n \"description\": \"Loopman LangChain Tool Validation Example\",\n \"main\": \"index.ts\",\n \"type\": \"module\",\n \"scripts\": {\n \"start\": \"tsx index.ts\",\n \"dev\": \"tsx index.ts\",\n \"build\": \"tsc\",\n \"run\": \"node dist/index.js\"\n },\n \"dependencies\": {\n \"@langchain/core\": \"^1.0.2\",\n \"@langchain/mcp-adapters\": \"^1.0.0\",\n \"@langchain/langgraph\": \"^1.0.1\",\n \"@langchain/openai\": \"^1.0.0\",\n \"@loopman/langchain-sdk\": \"^1.
|
|
10
|
+
"package.json": "{\n \"name\": \"loopman-langchain-tool-validation\",\n \"version\": \"1.0.0\",\n \"description\": \"Loopman LangChain Tool Validation Example\",\n \"main\": \"index.ts\",\n \"type\": \"module\",\n \"scripts\": {\n \"start\": \"tsx index.ts\",\n \"dev\": \"tsx index.ts\",\n \"build\": \"tsc\",\n \"run\": \"node dist/index.js\"\n },\n \"dependencies\": {\n \"@langchain/core\": \"^1.0.2\",\n \"@langchain/mcp-adapters\": \"^1.0.0\",\n \"@langchain/langgraph\": \"^1.0.1\",\n \"@langchain/openai\": \"^1.0.0\",\n \"@loopman/langchain-sdk\": \"^1.16.0\",\n \"dotenv\": \"^17.2.3\",\n \"langchain\": \"^1.0.2\",\n \"tsx\": \"^4.20.6\",\n \"typescript\": \"^5.9.3\",\n \"zod\": \"^3.25.76\"\n },\n \"devDependencies\": {\n \"@types/node\": \"^24.9.2\"\n }\n}\n\n",
|
|
11
11
|
"tsconfig.json": "{\n \"compilerOptions\": {\n \"target\": \"ES2022\",\n \"module\": \"ES2022\",\n \"lib\": [\"ES2022\"],\n \"moduleResolution\": \"bundler\",\n \"resolveJsonModule\": true,\n \"allowJs\": true,\n \"outDir\": \"./dist\",\n \"rootDir\": \"./\",\n \"strict\": true,\n \"esModuleInterop\": true,\n \"skipLibCheck\": true,\n \"forceConsistentCasingInFileNames\": true,\n \"declaration\": true,\n \"declarationMap\": true,\n \"sourceMap\": true\n },\n \"include\": [\"**/*.ts\"],\n \"exclude\": [\"node_modules\", \"dist\"]\n}\n\n",
|
|
12
12
|
"README.md": "# Loopman LangChain - Tool Validation Mode\n\nThis project demonstrates how to integrate Loopman with LangChain using **Tool Validation** mode.\n\n## About Tool Validation Mode\n\nIn this mode, Loopman middleware intercepts specific tool calls and requires human validation before execution. This is useful when:\n- Certain actions need human approval (e.g., sending emails, making payments)\n- You want to validate AI decisions before they affect real systems\n- Compliance requires human oversight for specific operations\n\n## Setup\n\n1. Install dependencies:\n```bash\nnpm install\n```\n\n2. Copy .env.example to .env and configure your keys:\n```bash\ncp .env.example .env\n```\n\nEdit the .env file and replace the placeholders with your actual values:\n- `OPENAI_API_KEY`: Your OpenAI API key\n- `LOOPMAN_API_KEY`: Your Loopman API key\n- `LOOPMAN_WORKFLOW_ID`: Your workflow ID from Loopman\n\n3. Run the example:\n```bash\nnpm start\n```\n\n## How It Works\n\n### 1. Define Tools\n\n```typescript\nconst sayHello = tool(\n ({ name }) => {\n console.log(`Hello, ${name}!`);\n return `Hello, ${name}! Welcome to Loopman.`;\n },\n {\n name: \"say_hello\",\n description: \"Say hello to someone\",\n schema: z.object({\n name: z.string().describe(\"The name of the person to greet\"),\n }),\n }\n);\n```\n\n### 2. Add Loopman Middleware\n\n```typescript\nconst agent = createAgent({\n model: \"openai:gpt-4o-mini\",\n tools: [sayHello],\n middleware: [\n loopmanMiddleware({\n apiKey: process.env.LOOPMAN_API_KEY!,\n workflowId: process.env.LOOPMAN_WORKFLOW_ID!,\n interruptOn: {\n say_hello: true, // Requires human validation\n },\n debug: true,\n }),\n ],\n checkpointer,\n});\n```\n\n### 3. Run the Agent\n\n```typescript\nconst result = await agent.invoke(\n {\n messages: [{ role: \"user\", content: \"Say hello to Alice\" }],\n },\n config\n);\n```\n\n## Key Features\n\n- **Selective Validation**: Only specified tools require approval\n- **Automatic Interception**: Middleware handles validation workflow\n- **Stateful**: Uses checkpointer to maintain conversation state\n- **Debug Mode**: Verbose logging for development\n\n## Workflow\n\n```\n1. User sends message\n ↓\n2. Agent generates tool call (say_hello)\n ↓\n3. Loopman middleware intercepts\n ↓\n4. Creates validation task\n ↓\n5. Waits for human decision\n ↓\n6. If approved → Execute tool\n If rejected → Return to agent with feedback\n```\n\n## Configuration Options\n\n### interruptOn\n\nSpecify which tools require validation:\n\n```typescript\ninterruptOn: {\n say_hello: true, // Always validate\n send_email: true, // Always validate\n get_weather: false, // Never validate (auto-execute)\n}\n```\n\n### debug\n\nEnable/disable verbose logging:\n\n```typescript\ndebug: true // Show detailed logs\ndebug: false // Production mode\n```\n\n## Learn More\n\n- [Loopman Middleware Documentation](https://github.com/loopman/loopman-langchain-sdk/blob/main/docs/TOOL_VALIDATION_MODE.md)\n- [LangChain Agent Documentation](https://js.langchain.com/docs/how_to/agent_executor)\n- [Loopman Documentation](https://loopman.dev/docs)\n\n"
|
|
13
13
|
},
|
|
14
14
|
"langchain-full-review": {
|
|
15
15
|
"index.ts": "import { config } from \"dotenv\";\nimport { tool } from \"langchain\";\nimport * as z from \"zod\";\nimport { createLoopmanAgent } from \"@loopman/langchain-sdk\";\n\n// Load environment variables\nconfig();\n\n// Simple hello world tool\nconst sayHello = tool(\n ({ name }) => {\n console.log(`Hello, ${name}!`);\n return `Hello, ${name}! Welcome to Loopman.`;\n },\n {\n name: \"say_hello\",\n description: \"Say hello to someone\",\n schema: z.object({\n name: z.string().describe(\"The name of the person to greet\"),\n }),\n }\n);\n\n// Create Loopman agent with full human review process\nconst agent = createLoopmanAgent({\n apiKey: process.env.LOOPMAN_API_KEY!,\n workflowId: process.env.LOOPMAN_WORKFLOW_ID!,\n model: \"openai:gpt-4o-mini\",\n systemPrompt: \"You are a helpful assistant that greets people.\",\n category: \"hello-world\",\n additionalTools: [sayHello],\n requireApprovalForTools: [\"say_hello\"], // Requires validation\n debug: true,\n});\n\n// Run the agent\nasync function main() {\n const result = await agent.processWithHumanValidation({\n input: \"Say hello to Alice\",\n });\n\n console.log(\"Agent response:\", result.response);\n if (result.decision) {\n console.log(\"Decision status:\", result.decision.status);\n if (result.decision.feedback) {\n console.log(\"Human feedback:\", result.decision.feedback);\n }\n }\n\n await agent.disconnect();\n}\n\nmain().catch(console.error);\n\n",
|
|
16
|
-
"package.json": "{\n \"name\": \"loopman-langchain-full-review\",\n \"version\": \"1.0.0\",\n \"description\": \"Loopman LangChain Full Human Review Example\",\n \"main\": \"index.ts\",\n \"type\": \"module\",\n \"scripts\": {\n \"start\": \"tsx index.ts\",\n \"dev\": \"tsx index.ts\",\n \"build\": \"tsc\",\n \"run\": \"node dist/index.js\"\n },\n \"dependencies\": {\n \"@langchain/core\": \"^1.0.2\",\n \"@langchain/mcp-adapters\": \"^1.0.0\",\n \"@langchain/langgraph\": \"^1.0.1\",\n \"@langchain/openai\": \"^1.0.0\",\n \"@loopman/langchain-sdk\": \"^1.
|
|
16
|
+
"package.json": "{\n \"name\": \"loopman-langchain-full-review\",\n \"version\": \"1.0.0\",\n \"description\": \"Loopman LangChain Full Human Review Example\",\n \"main\": \"index.ts\",\n \"type\": \"module\",\n \"scripts\": {\n \"start\": \"tsx index.ts\",\n \"dev\": \"tsx index.ts\",\n \"build\": \"tsc\",\n \"run\": \"node dist/index.js\"\n },\n \"dependencies\": {\n \"@langchain/core\": \"^1.0.2\",\n \"@langchain/mcp-adapters\": \"^1.0.0\",\n \"@langchain/langgraph\": \"^1.0.1\",\n \"@langchain/openai\": \"^1.0.0\",\n \"@loopman/langchain-sdk\": \"^1.16.0\",\n \"dotenv\": \"^17.2.3\",\n \"langchain\": \"^1.0.2\",\n \"tsx\": \"^4.20.6\",\n \"typescript\": \"^5.9.3\",\n \"zod\": \"^3.25.76\"\n },\n \"devDependencies\": {\n \"@types/node\": \"^24.9.2\"\n }\n}\n\n",
|
|
17
17
|
"tsconfig.json": "{\n \"compilerOptions\": {\n \"target\": \"ES2022\",\n \"module\": \"ES2022\",\n \"lib\": [\"ES2022\"],\n \"moduleResolution\": \"bundler\",\n \"resolveJsonModule\": true,\n \"allowJs\": true,\n \"outDir\": \"./dist\",\n \"rootDir\": \"./\",\n \"strict\": true,\n \"esModuleInterop\": true,\n \"skipLibCheck\": true,\n \"forceConsistentCasingInFileNames\": true,\n \"declaration\": true,\n \"declarationMap\": true,\n \"sourceMap\": true\n },\n \"include\": [\"**/*.ts\"],\n \"exclude\": [\"node_modules\", \"dist\"]\n}\n\n",
|
|
18
18
|
"README.md": "# Loopman LangChain - Full Human Review Mode\n\nThis project demonstrates how to integrate Loopman with LangChain using **Full Human Review Process** mode.\n\n## About Full Human Review Mode\n\nIn this mode, the Loopman Agent handles the entire workflow including:\n- Creating validation tasks\n- Waiting for human approval\n- Handling feedback and retries\n- Managing the complete lifecycle\n\nThis is useful when:\n- You want a complete HITL (Human-In-The-Loop) solution\n- The agent should wait for human decisions before proceeding\n- You need full control over the validation workflow\n\n## Setup\n\n1. Install dependencies:\n```bash\nnpm install\n```\n\n2. Copy .env.example to .env and configure your keys:\n```bash\ncp .env.example .env\n```\n\nEdit the .env file and replace the placeholders with your actual values:\n- `OPENAI_API_KEY`: Your OpenAI API key\n- `LOOPMAN_API_KEY`: Your Loopman API key\n- `LOOPMAN_WORKFLOW_ID`: Your workflow ID from Loopman\n\n3. Run the example:\n```bash\nnpm start\n```\n\n## How It Works\n\n### 1. Define Tools\n\n```typescript\nconst sayHello = tool(\n ({ name }) => {\n console.log(`Hello, ${name}!`);\n return `Hello, ${name}! Welcome to Loopman.`;\n },\n {\n name: \"say_hello\",\n description: \"Say hello to someone\",\n schema: z.object({\n name: z.string().describe(\"The name of the person to greet\"),\n }),\n }\n);\n```\n\n### 2. Create Loopman Agent\n\n```typescript\nconst agent = createLoopmanAgent({\n apiKey: process.env.LOOPMAN_API_KEY!,\n workflowId: process.env.LOOPMAN_WORKFLOW_ID!,\n model: \"openai:gpt-4o-mini\",\n systemPrompt: \"You are a helpful assistant that greets people.\",\n category: \"hello-world\",\n additionalTools: [sayHello],\n requireApprovalForTools: [\"say_hello\"],\n debug: true,\n});\n```\n\n### 3. Process with Human Validation\n\n```typescript\nconst result = await agent.processWithHumanValidation({\n input: \"Say hello to Alice\",\n});\n\nconsole.log(\"Agent response:\", result.response);\nif (result.decision) {\n console.log(\"Decision status:\", result.decision.status);\n console.log(\"Human feedback:\", result.decision.feedback);\n}\n```\n\n## Key Features\n\n- **Complete HITL Workflow**: Agent manages the entire validation lifecycle\n- **Automatic Polling**: Waits for human decisions\n- **Feedback Handling**: Processes human feedback and retries if needed\n- **Category Support**: Organize validations by category\n- **Debug Mode**: Verbose logging for development\n\n## Workflow\n\n```\n1. User sends message\n ↓\n2. Agent processes with LLM\n ↓\n3. Agent generates tool call\n ↓\n4. Creates Loopman validation task\n ↓\n5. Polls for human decision\n ↓\n6. If approved → Execute and return result\n If rejected → Process feedback and retry\n If timeout → Handle timeout\n```\n\n## Configuration Options\n\n### requireApprovalForTools\n\nSpecify which tools require validation:\n\n```typescript\nrequireApprovalForTools: [\"say_hello\", \"send_email\"]\n// Only these tools will require human approval\n```\n\n### category\n\nOrganize validations by category:\n\n```typescript\ncategory: \"hello-world\"\n// Helps filter and organize validation tasks\n```\n\n### debug\n\nEnable/disable verbose logging:\n\n```typescript\ndebug: true // Show detailed logs\ndebug: false // Production mode\n```\n\n## Response Structure\n\nThe `processWithHumanValidation` method returns:\n\n```typescript\n{\n response: string, // Final agent response\n decision?: {\n status: \"APPROVED\" | \"REJECTED\" | \"NEEDS_CHANGES\",\n feedback?: string, // Human feedback if provided\n createdAt: Date,\n updatedAt: Date,\n }\n}\n```\n\n## Learn More\n\n- [Loopman Agent Documentation](https://github.com/loopman/loopman-langchain-sdk/blob/main/docs/LOOPMAN_AGENT.md)\n- [LangChain Documentation](https://js.langchain.com/docs)\n- [Loopman Documentation](https://loopman.dev/docs)\n\n"
|
|
19
19
|
}
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"@langchain/mcp-adapters": "^1.0.0",
|
|
16
16
|
"@langchain/langgraph": "^1.0.1",
|
|
17
17
|
"@langchain/openai": "^1.0.0",
|
|
18
|
-
"@loopman/langchain-sdk": "^1.
|
|
18
|
+
"@loopman/langchain-sdk": "^1.16.0",
|
|
19
19
|
"dotenv": "^17.2.3",
|
|
20
20
|
"langchain": "^1.0.2",
|
|
21
21
|
"tsx": "^4.20.6",
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"@langchain/mcp-adapters": "^1.0.0",
|
|
16
16
|
"@langchain/langgraph": "^1.0.1",
|
|
17
17
|
"@langchain/openai": "^1.0.0",
|
|
18
|
-
"@loopman/langchain-sdk": "^1.
|
|
18
|
+
"@loopman/langchain-sdk": "^1.16.0",
|
|
19
19
|
"dotenv": "^17.2.3",
|
|
20
20
|
"langchain": "^1.0.2",
|
|
21
21
|
"tsx": "^4.20.6",
|