Spaces:
Running
Running
Revive the graph RAG example with a working setup.
Browse files
lynxkite-app/data/Graph RAG
CHANGED
@@ -7,22 +7,24 @@
|
|
7 |
"data": {
|
8 |
"title": "Input document",
|
9 |
"params": {
|
10 |
-
"filename": "/
|
11 |
},
|
12 |
"display": null,
|
13 |
"error": null,
|
|
|
14 |
"meta": {
|
15 |
-
"
|
16 |
"params": {
|
17 |
"filename": {
|
18 |
-
"name": "filename",
|
19 |
-
"default": null,
|
20 |
"type": {
|
21 |
"format": "path"
|
22 |
-
}
|
|
|
|
|
23 |
}
|
24 |
},
|
25 |
"inputs": {},
|
|
|
26 |
"outputs": {
|
27 |
"output": {
|
28 |
"name": "output",
|
@@ -31,16 +33,17 @@
|
|
31 |
},
|
32 |
"position": "right"
|
33 |
}
|
34 |
-
}
|
35 |
-
|
36 |
-
|
37 |
-
}
|
38 |
},
|
39 |
"position": {
|
40 |
-
"x": -
|
41 |
-
"y": -
|
42 |
},
|
43 |
-
"parentId": null
|
|
|
|
|
44 |
},
|
45 |
{
|
46 |
"id": "View 1",
|
@@ -188,7 +191,6 @@
|
|
188 |
"error": null,
|
189 |
"meta": {
|
190 |
"name": "View",
|
191 |
-
"params": {},
|
192 |
"inputs": {
|
193 |
"input": {
|
194 |
"name": "input",
|
@@ -199,8 +201,8 @@
|
|
199 |
}
|
200 |
},
|
201 |
"outputs": {},
|
202 |
-
"
|
203 |
-
"
|
204 |
},
|
205 |
"beingResized": false
|
206 |
},
|
@@ -209,8 +211,8 @@
|
|
209 |
"y": -562.3096858852143
|
210 |
},
|
211 |
"parentId": null,
|
212 |
-
"width":
|
213 |
-
"height":
|
214 |
},
|
215 |
{
|
216 |
"id": "Split document 1",
|
@@ -223,25 +225,26 @@
|
|
223 |
"display": null,
|
224 |
"error": null,
|
225 |
"meta": {
|
226 |
-
"name": "Split document",
|
227 |
"params": {
|
228 |
"delimiter": {
|
229 |
"name": "delimiter",
|
230 |
-
"default": "\\n\\n",
|
231 |
"type": {
|
232 |
"type": "<class 'str'>"
|
233 |
-
}
|
|
|
234 |
}
|
235 |
},
|
|
|
236 |
"inputs": {
|
237 |
"input": {
|
238 |
-
"name": "input",
|
239 |
"type": {
|
240 |
"type": "<class 'inspect._empty'>"
|
241 |
},
|
242 |
-
"position": "left"
|
|
|
243 |
}
|
244 |
},
|
|
|
245 |
"outputs": {
|
246 |
"output": {
|
247 |
"name": "output",
|
@@ -250,16 +253,16 @@
|
|
250 |
},
|
251 |
"position": "right"
|
252 |
}
|
253 |
-
}
|
254 |
-
"type": "basic",
|
255 |
-
"sub_nodes": null
|
256 |
}
|
257 |
},
|
258 |
"position": {
|
259 |
-
"x": -
|
260 |
-
"y": -
|
261 |
},
|
262 |
-
"parentId": null
|
|
|
|
|
263 |
},
|
264 |
{
|
265 |
"id": "Input chat 1",
|
@@ -271,7 +274,9 @@
|
|
271 |
},
|
272 |
"display": null,
|
273 |
"error": null,
|
|
|
274 |
"meta": {
|
|
|
275 |
"name": "Input chat",
|
276 |
"params": {
|
277 |
"chat": {
|
@@ -285,25 +290,24 @@
|
|
285 |
"inputs": {},
|
286 |
"outputs": {
|
287 |
"output": {
|
288 |
-
"
|
289 |
"type": {
|
290 |
"type": "None"
|
291 |
},
|
292 |
-
"
|
293 |
}
|
294 |
-
}
|
295 |
-
"type": "basic",
|
296 |
-
"sub_nodes": null
|
297 |
},
|
|
|
298 |
"beingResized": false
|
299 |
},
|
300 |
"position": {
|
301 |
-
"x": -
|
302 |
-
"y":
|
303 |
},
|
304 |
"parentId": null,
|
305 |
-
"width":
|
306 |
-
"height":
|
307 |
},
|
308 |
{
|
309 |
"id": "Create prompt 1",
|
@@ -311,56 +315,59 @@
|
|
311 |
"data": {
|
312 |
"title": "Create prompt",
|
313 |
"params": {
|
314 |
-
"
|
315 |
-
"
|
316 |
},
|
317 |
"display": null,
|
318 |
"error": null,
|
|
|
|
|
319 |
"meta": {
|
320 |
"name": "Create prompt",
|
321 |
-
"params": {
|
322 |
-
"save_as": {
|
323 |
-
"name": "save_as",
|
324 |
-
"default": "prompt",
|
325 |
-
"type": {
|
326 |
-
"type": "<class 'str'>"
|
327 |
-
}
|
328 |
-
},
|
329 |
-
"template": {
|
330 |
-
"name": "template",
|
331 |
-
"default": null,
|
332 |
-
"type": {
|
333 |
-
"format": "textarea"
|
334 |
-
}
|
335 |
-
}
|
336 |
-
},
|
337 |
"inputs": {
|
338 |
"input": {
|
339 |
-
"
|
340 |
"type": {
|
341 |
"type": "<class 'inspect._empty'>"
|
342 |
},
|
343 |
-
"
|
344 |
}
|
345 |
},
|
346 |
"outputs": {
|
347 |
"output": {
|
348 |
"name": "output",
|
|
|
349 |
"type": {
|
350 |
"type": "None"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
351 |
},
|
352 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
353 |
}
|
354 |
},
|
355 |
-
"type": "basic"
|
356 |
-
"sub_nodes": null
|
357 |
}
|
358 |
},
|
359 |
"position": {
|
360 |
"x": 324.81988008998496,
|
361 |
"y": -9.071826950189632
|
362 |
},
|
363 |
-
"
|
|
|
|
|
364 |
},
|
365 |
{
|
366 |
"id": "RAG 1",
|
@@ -369,8 +376,8 @@
|
|
369 |
"title": "RAG",
|
370 |
"params": {
|
371 |
"engine": "Custom",
|
372 |
-
"input_field": "text",
|
373 |
"db_field": "text",
|
|
|
374 |
"num_matches": "1"
|
375 |
},
|
376 |
"display": null,
|
@@ -378,16 +385,6 @@
|
|
378 |
"meta": {
|
379 |
"name": "RAG",
|
380 |
"params": {
|
381 |
-
"engine": {
|
382 |
-
"name": "engine",
|
383 |
-
"default": "Chroma",
|
384 |
-
"type": {
|
385 |
-
"enum": [
|
386 |
-
"Chroma",
|
387 |
-
"Custom"
|
388 |
-
]
|
389 |
-
}
|
390 |
-
},
|
391 |
"input_field": {
|
392 |
"name": "input_field",
|
393 |
"default": "text",
|
@@ -402,20 +399,39 @@
|
|
402 |
"type": "<class 'str'>"
|
403 |
}
|
404 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
405 |
"num_matches": {
|
406 |
-
"name": "num_matches",
|
407 |
-
"default": 10,
|
408 |
"type": {
|
409 |
"type": "<class 'int'>"
|
410 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
411 |
}
|
412 |
},
|
413 |
"inputs": {
|
414 |
"input": {
|
415 |
-
"name": "input",
|
416 |
"type": {
|
417 |
"type": "<class 'inspect._empty'>"
|
418 |
},
|
|
|
419 |
"position": "left"
|
420 |
},
|
421 |
"db": {
|
@@ -426,24 +442,16 @@
|
|
426 |
"position": "top"
|
427 |
}
|
428 |
},
|
429 |
-
"
|
430 |
-
"output": {
|
431 |
-
"name": "output",
|
432 |
-
"type": {
|
433 |
-
"type": "None"
|
434 |
-
},
|
435 |
-
"position": "right"
|
436 |
-
}
|
437 |
-
},
|
438 |
-
"type": "basic",
|
439 |
-
"sub_nodes": null
|
440 |
}
|
441 |
},
|
442 |
"position": {
|
443 |
-
"x": -
|
444 |
-
"y":
|
445 |
},
|
446 |
-
"parentId": null
|
|
|
|
|
447 |
},
|
448 |
{
|
449 |
"id": "View 3",
|
@@ -470,31 +478,30 @@
|
|
470 |
}
|
471 |
},
|
472 |
"error": null,
|
|
|
473 |
"meta": {
|
474 |
"name": "View",
|
475 |
"params": {},
|
476 |
"inputs": {
|
477 |
"input": {
|
478 |
-
"name": "input",
|
479 |
"type": {
|
480 |
"type": "<class 'inspect._empty'>"
|
481 |
},
|
482 |
-
"position": "left"
|
|
|
483 |
}
|
484 |
},
|
485 |
"outputs": {},
|
486 |
-
"type": "table_view"
|
487 |
-
|
488 |
-
},
|
489 |
-
"beingResized": false
|
490 |
},
|
491 |
"position": {
|
492 |
-
"x": -
|
493 |
-
"y":
|
494 |
},
|
495 |
"parentId": null,
|
496 |
-
"width": 296,
|
497 |
-
"height": 228
|
498 |
},
|
499 |
{
|
500 |
"id": "Ask LLM 1",
|
@@ -502,63 +509,66 @@
|
|
502 |
"data": {
|
503 |
"title": "Ask LLM",
|
504 |
"params": {
|
505 |
-
"
|
506 |
-
"accepted_regex":
|
507 |
-
"
|
508 |
},
|
509 |
"display": null,
|
510 |
"error": null,
|
|
|
|
|
511 |
"meta": {
|
512 |
-
"
|
513 |
-
|
514 |
-
|
515 |
-
"name": "
|
516 |
-
"default": null,
|
517 |
"type": {
|
518 |
-
"type": "<class '
|
519 |
}
|
520 |
-
}
|
|
|
|
|
521 |
"accepted_regex": {
|
522 |
-
"name": "accepted_regex",
|
523 |
-
"default": null,
|
524 |
"type": {
|
525 |
"type": "<class 'str'>"
|
526 |
-
}
|
|
|
|
|
527 |
},
|
528 |
"max_tokens": {
|
529 |
"name": "max_tokens",
|
530 |
-
"default": 100,
|
531 |
"type": {
|
532 |
"type": "<class 'int'>"
|
533 |
}
|
534 |
-
}
|
535 |
-
|
536 |
-
"inputs": {
|
537 |
-
"input": {
|
538 |
-
"name": "input",
|
539 |
"type": {
|
540 |
-
"type": "<class '
|
541 |
},
|
542 |
-
"
|
|
|
543 |
}
|
544 |
},
|
545 |
"outputs": {
|
546 |
"output": {
|
547 |
-
"name": "output",
|
548 |
"type": {
|
549 |
"type": "None"
|
550 |
},
|
551 |
-
"position": "right"
|
|
|
552 |
}
|
553 |
},
|
554 |
-
"
|
555 |
-
"
|
556 |
}
|
557 |
},
|
558 |
"position": {
|
559 |
"x": 649.0730411878703,
|
560 |
"y": 29.290926423828694
|
561 |
},
|
|
|
|
|
562 |
"parentId": null
|
563 |
},
|
564 |
{
|
@@ -585,7 +595,7 @@
|
|
585 |
"Available options: Coke, Diet Coke, Sprite, Root Beer, Lemonade."
|
586 |
],
|
587 |
"\n\n---\n### 6. **Drinks**\n\n---\n| Size | Price |\n|--------------------|---------------|\n| 20 oz Bottle | $1.99 |\n| 2-Liter Bottle | $3.50 |\n\n---\nAvailable options: Coke, Diet Coke, Sprite, Root Beer, Lemonade.\n\n---\nIs the information above sufficient to answer the following question?\n- What's your cheapest drink?\n\nIf the information is insufficient please say so. Otherwise, provide the answer.",
|
588 |
-
"The information is sufficient to answer the question
|
589 |
]
|
590 |
]
|
591 |
}
|
@@ -593,27 +603,28 @@
|
|
593 |
},
|
594 |
"error": null,
|
595 |
"meta": {
|
596 |
-
"
|
|
|
597 |
"params": {},
|
598 |
"inputs": {
|
599 |
"input": {
|
600 |
-
"
|
601 |
"type": {
|
602 |
"type": "<class 'inspect._empty'>"
|
603 |
},
|
604 |
-
"
|
605 |
}
|
606 |
},
|
607 |
-
"
|
608 |
-
"type": "table_view",
|
609 |
-
"sub_nodes": null
|
610 |
}
|
611 |
},
|
612 |
"position": {
|
613 |
-
"x":
|
614 |
-
"y": -
|
615 |
},
|
616 |
-
"
|
|
|
|
|
617 |
},
|
618 |
{
|
619 |
"id": "Build document graph 1",
|
@@ -623,37 +634,38 @@
|
|
623 |
"params": {},
|
624 |
"display": null,
|
625 |
"error": null,
|
|
|
626 |
"meta": {
|
627 |
"name": "Build document graph",
|
628 |
"params": {},
|
629 |
-
"inputs": {
|
630 |
-
"input": {
|
631 |
-
"name": "input",
|
632 |
-
"type": {
|
633 |
-
"type": "<class 'inspect._empty'>"
|
634 |
-
},
|
635 |
-
"position": "top"
|
636 |
-
}
|
637 |
-
},
|
638 |
"outputs": {
|
639 |
"output": {
|
640 |
"name": "output",
|
|
|
641 |
"type": {
|
642 |
"type": "None"
|
643 |
-
}
|
644 |
-
"position": "right"
|
645 |
}
|
646 |
},
|
647 |
-
"
|
648 |
-
|
649 |
-
|
650 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
651 |
},
|
652 |
"position": {
|
653 |
"x": -36.39166052931119,
|
654 |
"y": -212.34993098590766
|
655 |
},
|
656 |
-
"
|
|
|
|
|
657 |
},
|
658 |
{
|
659 |
"id": "Add neighbors 1",
|
@@ -664,42 +676,41 @@
|
|
664 |
"display": null,
|
665 |
"error": null,
|
666 |
"meta": {
|
667 |
-
"
|
668 |
-
"params": {},
|
669 |
"inputs": {
|
670 |
"nodes": {
|
671 |
-
"name": "nodes",
|
672 |
"type": {
|
673 |
"type": "<class 'inspect._empty'>"
|
674 |
},
|
|
|
675 |
"position": "top"
|
676 |
},
|
677 |
-
"
|
678 |
-
"
|
|
|
679 |
"type": {
|
680 |
"type": "<class 'inspect._empty'>"
|
681 |
-
}
|
682 |
-
"position": "top"
|
683 |
},
|
684 |
-
"
|
685 |
-
"name": "
|
|
|
686 |
"type": {
|
687 |
"type": "<class 'inspect._empty'>"
|
688 |
-
}
|
689 |
-
"position": "left"
|
690 |
}
|
691 |
},
|
|
|
|
|
692 |
"outputs": {
|
693 |
"output": {
|
|
|
694 |
"name": "output",
|
695 |
"type": {
|
696 |
"type": "None"
|
697 |
-
}
|
698 |
-
"position": "right"
|
699 |
}
|
700 |
-
}
|
701 |
-
"type": "basic",
|
702 |
-
"sub_nodes": null
|
703 |
},
|
704 |
"collapsed": true
|
705 |
},
|
@@ -707,7 +718,9 @@
|
|
707 |
"x": -2.516468588848724,
|
708 |
"y": 167.64180115746848
|
709 |
},
|
710 |
-
"parentId": null
|
|
|
|
|
711 |
},
|
712 |
{
|
713 |
"id": "Predict links 1",
|
@@ -717,25 +730,26 @@
|
|
717 |
"params": {},
|
718 |
"display": null,
|
719 |
"error": null,
|
|
|
720 |
"meta": {
|
721 |
"name": "Predict links",
|
722 |
-
"params": {},
|
723 |
"inputs": {
|
724 |
-
"
|
725 |
-
"name": "nodes",
|
726 |
"type": {
|
727 |
"type": "<class 'inspect._empty'>"
|
728 |
},
|
|
|
729 |
"position": "top"
|
730 |
},
|
731 |
-
"
|
732 |
-
"name": "
|
|
|
733 |
"type": {
|
734 |
"type": "<class 'inspect._empty'>"
|
735 |
-
}
|
736 |
-
"position": "top"
|
737 |
}
|
738 |
},
|
|
|
739 |
"outputs": {
|
740 |
"output": {
|
741 |
"name": "output",
|
@@ -745,17 +759,16 @@
|
|
745 |
"position": "right"
|
746 |
}
|
747 |
},
|
748 |
-
"
|
749 |
-
|
750 |
-
|
751 |
-
"y": 179
|
752 |
-
}
|
753 |
-
}
|
754 |
},
|
755 |
"position": {
|
756 |
"x": 34.865308360949726,
|
757 |
"y": -37.44504613652989
|
758 |
},
|
|
|
|
|
759 |
"parentId": null
|
760 |
}
|
761 |
],
|
|
|
7 |
"data": {
|
8 |
"title": "Input document",
|
9 |
"params": {
|
10 |
+
"filename": "data/example-pizza.md"
|
11 |
},
|
12 |
"display": null,
|
13 |
"error": null,
|
14 |
+
"__execution_delay": 0.0,
|
15 |
"meta": {
|
16 |
+
"type": "basic",
|
17 |
"params": {
|
18 |
"filename": {
|
|
|
|
|
19 |
"type": {
|
20 |
"format": "path"
|
21 |
+
},
|
22 |
+
"name": "filename",
|
23 |
+
"default": null
|
24 |
}
|
25 |
},
|
26 |
"inputs": {},
|
27 |
+
"name": "Input document",
|
28 |
"outputs": {
|
29 |
"output": {
|
30 |
"name": "output",
|
|
|
33 |
},
|
34 |
"position": "right"
|
35 |
}
|
36 |
+
}
|
37 |
+
},
|
38 |
+
"collapsed": null
|
|
|
39 |
},
|
40 |
"position": {
|
41 |
+
"x": -1138.7178641442829,
|
42 |
+
"y": -307.0280242240266
|
43 |
},
|
44 |
+
"parentId": null,
|
45 |
+
"width": 290.0,
|
46 |
+
"height": 217.0
|
47 |
},
|
48 |
{
|
49 |
"id": "View 1",
|
|
|
191 |
"error": null,
|
192 |
"meta": {
|
193 |
"name": "View",
|
|
|
194 |
"inputs": {
|
195 |
"input": {
|
196 |
"name": "input",
|
|
|
201 |
}
|
202 |
},
|
203 |
"outputs": {},
|
204 |
+
"params": {},
|
205 |
+
"type": "table_view"
|
206 |
},
|
207 |
"beingResized": false
|
208 |
},
|
|
|
211 |
"y": -562.3096858852143
|
212 |
},
|
213 |
"parentId": null,
|
214 |
+
"width": 909.0,
|
215 |
+
"height": 367.0
|
216 |
},
|
217 |
{
|
218 |
"id": "Split document 1",
|
|
|
225 |
"display": null,
|
226 |
"error": null,
|
227 |
"meta": {
|
|
|
228 |
"params": {
|
229 |
"delimiter": {
|
230 |
"name": "delimiter",
|
|
|
231 |
"type": {
|
232 |
"type": "<class 'str'>"
|
233 |
+
},
|
234 |
+
"default": "\\n\\n"
|
235 |
}
|
236 |
},
|
237 |
+
"type": "basic",
|
238 |
"inputs": {
|
239 |
"input": {
|
|
|
240 |
"type": {
|
241 |
"type": "<class 'inspect._empty'>"
|
242 |
},
|
243 |
+
"position": "left",
|
244 |
+
"name": "input"
|
245 |
}
|
246 |
},
|
247 |
+
"name": "Split document",
|
248 |
"outputs": {
|
249 |
"output": {
|
250 |
"name": "output",
|
|
|
253 |
},
|
254 |
"position": "right"
|
255 |
}
|
256 |
+
}
|
|
|
|
|
257 |
}
|
258 |
},
|
259 |
"position": {
|
260 |
+
"x": -671.5138580866221,
|
261 |
+
"y": -394.5831190981944
|
262 |
},
|
263 |
+
"parentId": null,
|
264 |
+
"height": 200.0,
|
265 |
+
"width": 200.0
|
266 |
},
|
267 |
{
|
268 |
"id": "Input chat 1",
|
|
|
274 |
},
|
275 |
"display": null,
|
276 |
"error": null,
|
277 |
+
"__execution_delay": 0.0,
|
278 |
"meta": {
|
279 |
+
"type": "basic",
|
280 |
"name": "Input chat",
|
281 |
"params": {
|
282 |
"chat": {
|
|
|
290 |
"inputs": {},
|
291 |
"outputs": {
|
292 |
"output": {
|
293 |
+
"position": "right",
|
294 |
"type": {
|
295 |
"type": "None"
|
296 |
},
|
297 |
+
"name": "output"
|
298 |
}
|
299 |
+
}
|
|
|
|
|
300 |
},
|
301 |
+
"collapsed": null,
|
302 |
"beingResized": false
|
303 |
},
|
304 |
"position": {
|
305 |
+
"x": -1169.0221491975267,
|
306 |
+
"y": 142.6860253469853
|
307 |
},
|
308 |
"parentId": null,
|
309 |
+
"width": 347.0,
|
310 |
+
"height": 197.0
|
311 |
},
|
312 |
{
|
313 |
"id": "Create prompt 1",
|
|
|
315 |
"data": {
|
316 |
"title": "Create prompt",
|
317 |
"params": {
|
318 |
+
"template": "\n{% for item in rag %}\n---\n{{item}}\n{% endfor %}\n---\nIs the information above sufficient to answer the following question?\n- {{text}}\n\nIf the information is insufficient please say so. Otherwise, provide the answer.",
|
319 |
+
"save_as": "prompt"
|
320 |
},
|
321 |
"display": null,
|
322 |
"error": null,
|
323 |
+
"collapsed": null,
|
324 |
+
"__execution_delay": 0.0,
|
325 |
"meta": {
|
326 |
"name": "Create prompt",
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
327 |
"inputs": {
|
328 |
"input": {
|
329 |
+
"position": "left",
|
330 |
"type": {
|
331 |
"type": "<class 'inspect._empty'>"
|
332 |
},
|
333 |
+
"name": "input"
|
334 |
}
|
335 |
},
|
336 |
"outputs": {
|
337 |
"output": {
|
338 |
"name": "output",
|
339 |
+
"position": "right",
|
340 |
"type": {
|
341 |
"type": "None"
|
342 |
+
}
|
343 |
+
}
|
344 |
+
},
|
345 |
+
"params": {
|
346 |
+
"save_as": {
|
347 |
+
"type": {
|
348 |
+
"type": "<class 'str'>"
|
349 |
},
|
350 |
+
"default": "prompt",
|
351 |
+
"name": "save_as"
|
352 |
+
},
|
353 |
+
"template": {
|
354 |
+
"default": null,
|
355 |
+
"type": {
|
356 |
+
"format": "textarea"
|
357 |
+
},
|
358 |
+
"name": "template"
|
359 |
}
|
360 |
},
|
361 |
+
"type": "basic"
|
|
|
362 |
}
|
363 |
},
|
364 |
"position": {
|
365 |
"x": 324.81988008998496,
|
366 |
"y": -9.071826950189632
|
367 |
},
|
368 |
+
"height": 362.0,
|
369 |
+
"parentId": null,
|
370 |
+
"width": 270.0
|
371 |
},
|
372 |
{
|
373 |
"id": "RAG 1",
|
|
|
376 |
"title": "RAG",
|
377 |
"params": {
|
378 |
"engine": "Custom",
|
|
|
379 |
"db_field": "text",
|
380 |
+
"input_field": "text",
|
381 |
"num_matches": "1"
|
382 |
},
|
383 |
"display": null,
|
|
|
385 |
"meta": {
|
386 |
"name": "RAG",
|
387 |
"params": {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
388 |
"input_field": {
|
389 |
"name": "input_field",
|
390 |
"default": "text",
|
|
|
399 |
"type": "<class 'str'>"
|
400 |
}
|
401 |
},
|
402 |
+
"engine": {
|
403 |
+
"type": {
|
404 |
+
"enum": [
|
405 |
+
"Chroma",
|
406 |
+
"Custom"
|
407 |
+
]
|
408 |
+
},
|
409 |
+
"name": "engine",
|
410 |
+
"default": "RagEngine.Chroma"
|
411 |
+
},
|
412 |
"num_matches": {
|
|
|
|
|
413 |
"type": {
|
414 |
"type": "<class 'int'>"
|
415 |
+
},
|
416 |
+
"name": "num_matches",
|
417 |
+
"default": 10.0
|
418 |
+
}
|
419 |
+
},
|
420 |
+
"outputs": {
|
421 |
+
"output": {
|
422 |
+
"name": "output",
|
423 |
+
"type": {
|
424 |
+
"type": "None"
|
425 |
+
},
|
426 |
+
"position": "right"
|
427 |
}
|
428 |
},
|
429 |
"inputs": {
|
430 |
"input": {
|
|
|
431 |
"type": {
|
432 |
"type": "<class 'inspect._empty'>"
|
433 |
},
|
434 |
+
"name": "input",
|
435 |
"position": "left"
|
436 |
},
|
437 |
"db": {
|
|
|
442 |
"position": "top"
|
443 |
}
|
444 |
},
|
445 |
+
"type": "basic"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
446 |
}
|
447 |
},
|
448 |
"position": {
|
449 |
+
"x": -645.0268659124858,
|
450 |
+
"y": 44.3669514323544
|
451 |
},
|
452 |
+
"parentId": null,
|
453 |
+
"width": 423.0,
|
454 |
+
"height": 424.0
|
455 |
},
|
456 |
{
|
457 |
"id": "View 3",
|
|
|
478 |
}
|
479 |
},
|
480 |
"error": null,
|
481 |
+
"beingResized": false,
|
482 |
"meta": {
|
483 |
"name": "View",
|
484 |
"params": {},
|
485 |
"inputs": {
|
486 |
"input": {
|
|
|
487 |
"type": {
|
488 |
"type": "<class 'inspect._empty'>"
|
489 |
},
|
490 |
+
"position": "left",
|
491 |
+
"name": "input"
|
492 |
}
|
493 |
},
|
494 |
"outputs": {},
|
495 |
+
"type": "table_view"
|
496 |
+
}
|
|
|
|
|
497 |
},
|
498 |
"position": {
|
499 |
+
"x": -43.795911596608875,
|
500 |
+
"y": 457.1809102819045
|
501 |
},
|
502 |
"parentId": null,
|
503 |
+
"width": 296.0,
|
504 |
+
"height": 228.0
|
505 |
},
|
506 |
{
|
507 |
"id": "Ask LLM 1",
|
|
|
509 |
"data": {
|
510 |
"title": "Ask LLM",
|
511 |
"params": {
|
512 |
+
"max_tokens": 100.0,
|
513 |
+
"accepted_regex": "",
|
514 |
+
"model": "SultanR/SmolTulu-1.7b-Instruct"
|
515 |
},
|
516 |
"display": null,
|
517 |
"error": null,
|
518 |
+
"collapsed": null,
|
519 |
+
"__execution_delay": 0.0,
|
520 |
"meta": {
|
521 |
+
"inputs": {
|
522 |
+
"input": {
|
523 |
+
"position": "left",
|
524 |
+
"name": "input",
|
|
|
525 |
"type": {
|
526 |
+
"type": "<class 'inspect._empty'>"
|
527 |
}
|
528 |
+
}
|
529 |
+
},
|
530 |
+
"params": {
|
531 |
"accepted_regex": {
|
|
|
|
|
532 |
"type": {
|
533 |
"type": "<class 'str'>"
|
534 |
+
},
|
535 |
+
"default": null,
|
536 |
+
"name": "accepted_regex"
|
537 |
},
|
538 |
"max_tokens": {
|
539 |
"name": "max_tokens",
|
540 |
+
"default": 100.0,
|
541 |
"type": {
|
542 |
"type": "<class 'int'>"
|
543 |
}
|
544 |
+
},
|
545 |
+
"model": {
|
|
|
|
|
|
|
546 |
"type": {
|
547 |
+
"type": "<class 'str'>"
|
548 |
},
|
549 |
+
"default": null,
|
550 |
+
"name": "model"
|
551 |
}
|
552 |
},
|
553 |
"outputs": {
|
554 |
"output": {
|
|
|
555 |
"type": {
|
556 |
"type": "None"
|
557 |
},
|
558 |
+
"position": "right",
|
559 |
+
"name": "output"
|
560 |
}
|
561 |
},
|
562 |
+
"name": "Ask LLM",
|
563 |
+
"type": "basic"
|
564 |
}
|
565 |
},
|
566 |
"position": {
|
567 |
"x": 649.0730411878703,
|
568 |
"y": 29.290926423828694
|
569 |
},
|
570 |
+
"height": 329.0,
|
571 |
+
"width": 249.0,
|
572 |
"parentId": null
|
573 |
},
|
574 |
{
|
|
|
595 |
"Available options: Coke, Diet Coke, Sprite, Root Beer, Lemonade."
|
596 |
],
|
597 |
"\n\n---\n### 6. **Drinks**\n\n---\n| Size | Price |\n|--------------------|---------------|\n| 20 oz Bottle | $1.99 |\n| 2-Liter Bottle | $3.50 |\n\n---\nAvailable options: Coke, Diet Coke, Sprite, Root Beer, Lemonade.\n\n---\nIs the information above sufficient to answer the following question?\n- What's your cheapest drink?\n\nIf the information is insufficient please say so. Otherwise, provide the answer.",
|
598 |
+
"The provided information is sufficient to answer the question:\n\n- **Cheapest Drink:** \n\nThe cheapest drink is the 20 oz Bottle of Coke, which costs $1.99.\n\n**Why?**\n- The 20 oz Bottle of Coke is the only option listed with a price of $1.99, making it the most cost-effective option among the given drink sizes and prices."
|
599 |
]
|
600 |
]
|
601 |
}
|
|
|
603 |
},
|
604 |
"error": null,
|
605 |
"meta": {
|
606 |
+
"outputs": {},
|
607 |
+
"type": "table_view",
|
608 |
"params": {},
|
609 |
"inputs": {
|
610 |
"input": {
|
611 |
+
"position": "left",
|
612 |
"type": {
|
613 |
"type": "<class 'inspect._empty'>"
|
614 |
},
|
615 |
+
"name": "input"
|
616 |
}
|
617 |
},
|
618 |
+
"name": "View"
|
|
|
|
|
619 |
}
|
620 |
},
|
621 |
"position": {
|
622 |
+
"x": 1017.4149773467798,
|
623 |
+
"y": -71.64715104646865
|
624 |
},
|
625 |
+
"height": 644.0,
|
626 |
+
"parentId": null,
|
627 |
+
"width": 502.0
|
628 |
},
|
629 |
{
|
630 |
"id": "Build document graph 1",
|
|
|
634 |
"params": {},
|
635 |
"display": null,
|
636 |
"error": null,
|
637 |
+
"collapsed": true,
|
638 |
"meta": {
|
639 |
"name": "Build document graph",
|
640 |
"params": {},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
641 |
"outputs": {
|
642 |
"output": {
|
643 |
"name": "output",
|
644 |
+
"position": "right",
|
645 |
"type": {
|
646 |
"type": "None"
|
647 |
+
}
|
|
|
648 |
}
|
649 |
},
|
650 |
+
"inputs": {
|
651 |
+
"input": {
|
652 |
+
"position": "top",
|
653 |
+
"name": "input",
|
654 |
+
"type": {
|
655 |
+
"type": "<class 'inspect._empty'>"
|
656 |
+
}
|
657 |
+
}
|
658 |
+
},
|
659 |
+
"type": "basic"
|
660 |
+
}
|
661 |
},
|
662 |
"position": {
|
663 |
"x": -36.39166052931119,
|
664 |
"y": -212.34993098590766
|
665 |
},
|
666 |
+
"width": 200.0,
|
667 |
+
"parentId": null,
|
668 |
+
"height": 80.0
|
669 |
},
|
670 |
{
|
671 |
"id": "Add neighbors 1",
|
|
|
676 |
"display": null,
|
677 |
"error": null,
|
678 |
"meta": {
|
679 |
+
"type": "basic",
|
|
|
680 |
"inputs": {
|
681 |
"nodes": {
|
|
|
682 |
"type": {
|
683 |
"type": "<class 'inspect._empty'>"
|
684 |
},
|
685 |
+
"name": "nodes",
|
686 |
"position": "top"
|
687 |
},
|
688 |
+
"item": {
|
689 |
+
"position": "left",
|
690 |
+
"name": "item",
|
691 |
"type": {
|
692 |
"type": "<class 'inspect._empty'>"
|
693 |
+
}
|
|
|
694 |
},
|
695 |
+
"edges": {
|
696 |
+
"name": "edges",
|
697 |
+
"position": "top",
|
698 |
"type": {
|
699 |
"type": "<class 'inspect._empty'>"
|
700 |
+
}
|
|
|
701 |
}
|
702 |
},
|
703 |
+
"params": {},
|
704 |
+
"name": "Add neighbors",
|
705 |
"outputs": {
|
706 |
"output": {
|
707 |
+
"position": "right",
|
708 |
"name": "output",
|
709 |
"type": {
|
710 |
"type": "None"
|
711 |
+
}
|
|
|
712 |
}
|
713 |
+
}
|
|
|
|
|
714 |
},
|
715 |
"collapsed": true
|
716 |
},
|
|
|
718 |
"x": -2.516468588848724,
|
719 |
"y": 167.64180115746848
|
720 |
},
|
721 |
+
"parentId": null,
|
722 |
+
"height": 56.0,
|
723 |
+
"width": 200.0
|
724 |
},
|
725 |
{
|
726 |
"id": "Predict links 1",
|
|
|
730 |
"params": {},
|
731 |
"display": null,
|
732 |
"error": null,
|
733 |
+
"__execution_delay": null,
|
734 |
"meta": {
|
735 |
"name": "Predict links",
|
|
|
736 |
"inputs": {
|
737 |
+
"edges": {
|
|
|
738 |
"type": {
|
739 |
"type": "<class 'inspect._empty'>"
|
740 |
},
|
741 |
+
"name": "edges",
|
742 |
"position": "top"
|
743 |
},
|
744 |
+
"nodes": {
|
745 |
+
"name": "nodes",
|
746 |
+
"position": "top",
|
747 |
"type": {
|
748 |
"type": "<class 'inspect._empty'>"
|
749 |
+
}
|
|
|
750 |
}
|
751 |
},
|
752 |
+
"type": "basic",
|
753 |
"outputs": {
|
754 |
"output": {
|
755 |
"name": "output",
|
|
|
759 |
"position": "right"
|
760 |
}
|
761 |
},
|
762 |
+
"params": {}
|
763 |
+
},
|
764 |
+
"collapsed": true
|
|
|
|
|
|
|
765 |
},
|
766 |
"position": {
|
767 |
"x": 34.865308360949726,
|
768 |
"y": -37.44504613652989
|
769 |
},
|
770 |
+
"height": 200.0,
|
771 |
+
"width": 200.0,
|
772 |
"parentId": null
|
773 |
}
|
774 |
],
|
lynxkite-app/data/example-pizza.md
ADDED
@@ -0,0 +1,136 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
hello
|
2 |
+
|
3 |
+
### 1. **Overview**
|
4 |
+
|
5 |
+
This document outlines the pricing structure and available options for our pizza delivery service. The goal is to provide clear guidance on the pricing tiers, additional offerings, and optional extras to ensure consistency across all locations and platforms (phone, online, in-app). All pricing is based on current market trends, food costs, and competitive analysis.
|
6 |
+
|
7 |
+
---
|
8 |
+
|
9 |
+
### 2. **Pizza Options**
|
10 |
+
|
11 |
+
#### 2.1 **Size & Base Pricing**
|
12 |
+
|
13 |
+
| Size | Diameter | Price (Cheese Pizza) |
|
14 |
+
|------------------|------------|----------------------|
|
15 |
+
| Small | 10 inches | $8.99 |
|
16 |
+
| Medium | 12 inches | $11.99 |
|
17 |
+
| Large | 14 inches | $14.99 |
|
18 |
+
| Extra Large | 16 inches | $17.99 |
|
19 |
+
|
20 |
+
**Note**: Cheese pizza pricing includes sauce and cheese. Toppings are additional (see section 2.3).
|
21 |
+
|
22 |
+
#### 2.2 **Crust Options**
|
23 |
+
|
24 |
+
| Crust Type | Description | Price Adjustment |
|
25 |
+
|------------------|------------------------------------------|------------------|
|
26 |
+
| Classic Hand-Tossed | Soft, airy texture | No Change |
|
27 |
+
| Thin & Crispy | Light and crunchy | No Change |
|
28 |
+
| Stuffed Crust | Filled with mozzarella | +$2.00 (M-XL) |
|
29 |
+
| Gluten-Free | 10" only; made with rice flour | +$2.50 (Small Only) |
|
30 |
+
|
31 |
+
---
|
32 |
+
|
33 |
+
### 3. **Toppings**
|
34 |
+
|
35 |
+
#### 3.1 **Standard Toppings**
|
36 |
+
**Price per topping:**
|
37 |
+
|
38 |
+
- Small: $1.00
|
39 |
+
- Medium: $1.50
|
40 |
+
- Large: $2.00
|
41 |
+
- Extra Large: $2.50
|
42 |
+
|
43 |
+
| Topping | Category |
|
44 |
+
|------------------|----------------|
|
45 |
+
| Pepperoni | Meat |
|
46 |
+
| Sausage | Meat |
|
47 |
+
| Mushrooms | Vegetable |
|
48 |
+
| Onions | Vegetable |
|
49 |
+
| Bell Peppers | Vegetable |
|
50 |
+
| Olives | Vegetable |
|
51 |
+
| Extra Cheese | Dairy |
|
52 |
+
|
53 |
+
#### 3.2 **Premium Toppings**
|
54 |
+
**Price per topping:**
|
55 |
+
|
56 |
+
- Small: $1.75
|
57 |
+
- Medium: $2.25
|
58 |
+
- Large: $2.75
|
59 |
+
- Extra Large: $3.25
|
60 |
+
|
61 |
+
| Topping | Category |
|
62 |
+
|------------------|----------------|
|
63 |
+
| Grilled Chicken | Meat |
|
64 |
+
| Bacon | Meat |
|
65 |
+
| Sun-Dried Tomatoes| Vegetable |
|
66 |
+
| Artichoke Hearts | Vegetable |
|
67 |
+
| Feta Cheese | Dairy |
|
68 |
+
| Vegan Cheese | Dairy Alternative |
|
69 |
+
|
70 |
+
---
|
71 |
+
|
72 |
+
### 4. **Specialty Pizzas**
|
73 |
+
|
74 |
+
Specialty pizzas include a combination of premium toppings and are available in all sizes. Prices below are for Medium size, with additional costs for upgrading to larger sizes.
|
75 |
+
|
76 |
+
| Pizza Name | Description | Price (Medium) |
|
77 |
+
|----------------------|----------------------------------------------------|-----------------|
|
78 |
+
| Meat Lover’s | Pepperoni, sausage, bacon, ham | $16.99 |
|
79 |
+
| Veggie Delight | Mushrooms, bell peppers, onions, olives | $14.99 |
|
80 |
+
| BBQ Chicken | BBQ sauce, grilled chicken, red onions, cilantro | $17.99 |
|
81 |
+
| Margherita | Fresh mozzarella, tomatoes, basil | $15.99 |
|
82 |
+
| Hawaiian | Ham, pineapple | $14.99 |
|
83 |
+
|
84 |
+
---
|
85 |
+
|
86 |
+
### 5. **Additional Menu Items**
|
87 |
+
|
88 |
+
#### 5.1 **Side Orders**
|
89 |
+
|
90 |
+
| Item | Description | Price |
|
91 |
+
|--------------------|--------------------------------------|---------------|
|
92 |
+
| Garlic Breadsticks | Served with marinara dipping sauce | $5.99 |
|
93 |
+
| Chicken Wings | Buffalo, BBQ, or plain (10 pieces) | $9.99 |
|
94 |
+
| Mozzarella Sticks | Served with marinara (8 pieces) | $6.99 |
|
95 |
+
| Caesar Salad | Romaine, croutons, Caesar dressing | $7.99 |
|
96 |
+
|
97 |
+
#### 5.2 **Desserts**
|
98 |
+
|
99 |
+
| Item | Description | Price |
|
100 |
+
|--------------------|--------------------------------------|---------------|
|
101 |
+
| Chocolate Brownies | Chewy and rich (6 pieces) | $4.99 |
|
102 |
+
| Cinnamon Sticks | Dusted with cinnamon sugar | $5.99 |
|
103 |
+
|
104 |
+
---
|
105 |
+
|
106 |
+
### 6. **Drinks**
|
107 |
+
|
108 |
+
| Size | Price |
|
109 |
+
|--------------------|---------------|
|
110 |
+
| 20 oz Bottle | $1.99 |
|
111 |
+
| 2-Liter Bottle | $3.50 |
|
112 |
+
|
113 |
+
Available options: Coke, Diet Coke, Sprite, Root Beer, Lemonade.
|
114 |
+
|
115 |
+
---
|
116 |
+
|
117 |
+
### 7. **Delivery Fees & Minimum Order**
|
118 |
+
|
119 |
+
- **Delivery Fee**: $2.99
|
120 |
+
- **Minimum Order**: $12.00
|
121 |
+
|
122 |
+
*Note: Delivery fees and minimum order thresholds apply to all delivery orders within a 5-mile radius. Additional charges may apply for orders outside this zone.*
|
123 |
+
|
124 |
+
---
|
125 |
+
|
126 |
+
### 8. **Promotions & Discounts**
|
127 |
+
|
128 |
+
- **Monday Madness**: Buy one large pizza, get a second pizza for 50% off.
|
129 |
+
- **Student Discount**: 10% off with valid student ID (pickup only).
|
130 |
+
- **Family Deal**: 2 large pizzas, 1 side, and 2-liter soda for $29.99.
|
131 |
+
|
132 |
+
---
|
133 |
+
|
134 |
+
### 9. **Conclusion**
|
135 |
+
|
136 |
+
This pricing and menu structure is designed to offer a wide range of choices for our customers while maintaining competitive pricing and ensuring profitability. Please ensure all team members are familiar with the details in this document and implement it accordingly.
|
lynxkite-lynxscribe/README.md
CHANGED
@@ -15,3 +15,12 @@ Run tests with:
|
|
15 |
```bash
|
16 |
uv run pytest
|
17 |
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
```bash
|
16 |
uv run pytest
|
17 |
```
|
18 |
+
|
19 |
+
The LLM agent flow examples use local models.
|
20 |
+
|
21 |
+
```bash
|
22 |
+
uv pip install infinity-emb[all]
|
23 |
+
infinity_emb v2 --model-id michaelfeil/bge-small-en-v1.5
|
24 |
+
uv pip install "sglang[all]>=0.4.2.post2" --find-links https://flashinfer.ai/whl/cu124/torch2.5/flashinfer/
|
25 |
+
python -m sglang.launch_server --model-path SultanR/SmolTulu-1.7b-Instruct --port 8080
|
26 |
+
```
|
lynxkite-lynxscribe/src/lynxkite_plugins/lynxscribe/llm_ops.py
CHANGED
@@ -212,7 +212,7 @@ def rag(
|
|
212 |
results = [db[int(r)] for r in results["ids"][0]]
|
213 |
return {**input, "rag": results, "_collection": collection}
|
214 |
if engine == RagEngine.Custom:
|
215 |
-
model = "
|
216 |
chat = input[input_field]
|
217 |
embeddings = [embedding(input=[r[db_field]], model=model) for r in db]
|
218 |
q = embedding(input=[chat], model=model)
|
|
|
212 |
results = [db[int(r)] for r in results["ids"][0]]
|
213 |
return {**input, "rag": results, "_collection": collection}
|
214 |
if engine == RagEngine.Custom:
|
215 |
+
model = "michaelfeil/bge-small-en-v1.5"
|
216 |
chat = input[input_field]
|
217 |
embeddings = [embedding(input=[r[db_field]], model=model) for r in db]
|
218 |
q = embedding(input=[chat], model=model)
|