You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -59,6 +59,8 @@ This will display detailed usage information.
59
59
-`-t`, `--api_timeout`: Timeout (in seconds) for API requests (default: 10).
60
60
-`-i`, `--poll_interval`: Interval (in seconds) between API status polls (default: 5).
61
61
-`-p`, `--parallel_call_count`: Number of parallel API calls (default: 10).
62
+
-`--csv_report`: Path to export the detailed report as a CSV file.
63
+
-`--db_path`: Path where the SQlite DB file is stored (default: './file_processing.db')
62
64
-`--retry_failed`: Retry processing of failed files.
63
65
-`--retry_pending`: Retry processing of pending files by making new requests.
64
66
-`--skip_pending`: Skip processing of pending files.
@@ -67,7 +69,6 @@ This will display detailed usage information.
67
69
-`--print_report`: Print a detailed report of all processed files at the end.
68
70
-`--exclude_metadata`: Exclude metadata on tokens consumed and the context passed to LLMs for prompt studio exported tools in the result for each file.
parser=argparse.ArgumentParser(description="Process files using the API.")
505
+
parser=argparse.ArgumentParser(description="Process files using Unstract's API deployment")
505
506
parser.add_argument(
506
507
"-e",
507
508
"--api_endpoint",
508
509
dest="api_endpoint",
509
510
type=str,
510
511
required=True,
511
-
help="API Endpoint to use for processing the files.",
512
+
help="API Endpoint to use for processing the files",
512
513
)
513
514
parser.add_argument(
514
515
"-k",
@@ -524,55 +525,68 @@ def main():
524
525
dest="api_timeout",
525
526
type=int,
526
527
default=10,
527
-
help="Time in seconds to wait before switching to async mode.",
528
+
help="Time in seconds to wait before switching to async mode (default: 10)",
528
529
)
529
530
parser.add_argument(
530
531
"-i",
531
532
"--poll_interval",
532
533
dest="poll_interval",
533
534
type=int,
534
535
default=5,
535
-
help="Time in seconds the process will sleep between polls in async mode.",
536
+
help="Time in seconds the process will sleep between polls in async mode (default: 5)",
536
537
)
537
538
parser.add_argument(
538
539
"-f",
539
540
"--input_folder_path",
540
541
dest="input_folder_path",
541
542
type=str,
542
543
required=True,
543
-
help="Path where the files to process are present.",
544
+
help="Path where the files to process are present",
544
545
)
545
546
parser.add_argument(
546
547
"-p",
547
548
"--parallel_call_count",
548
549
dest="parallel_call_count",
549
550
type=int,
550
551
default=5,
551
-
help="Number of calls to be made in parallel.",
552
+
help="Number of calls to be made in parallel (default: 5)",
553
+
)
554
+
parser.add_argument(
555
+
"--db_path",
556
+
dest="db_path",
557
+
type=str,
558
+
default="file_processing.db",
559
+
help="Path where the SQlite DB file is stored (default: './file_processing.db)'",
560
+
)
561
+
parser.add_argument(
562
+
'--csv_report',
563
+
dest="csv_report",
564
+
type=str,
565
+
help='Path to export the detailed report as a CSV file',
552
566
)
553
567
parser.add_argument(
554
568
"--retry_failed",
555
569
dest="retry_failed",
556
570
action="store_true",
557
-
help="Retry processing of failed files.",
571
+
help="Retry processing of failed files (default: True)",
558
572
)
559
573
parser.add_argument(
560
574
"--retry_pending",
561
575
dest="retry_pending",
562
576
action="store_true",
563
-
help="Retry processing of pending files as new request (Without this it will try to fetch the results using status API).",
577
+
help="Retry processing of pending files as new request (Without this it will try to fetch the results using status API) (default: True)",
564
578
)
565
579
parser.add_argument(
566
580
"--skip_pending",
567
581
dest="skip_pending",
568
582
action="store_true",
569
-
help="Skip processing of pending files (Over rides --retry-pending).",
583
+
help="Skip processing of pending files (overrides --retry-pending) (default: True)",
570
584
)
571
585
parser.add_argument(
572
586
"--skip_unprocessed",
573
587
dest="skip_unprocessed",
574
588
action="store_true",
575
-
help="Skip unprocessed files while retry processing of failed files.",
589
+
help="Skip unprocessed files while retry processing of failed files (default: True)",
576
590
)
577
591
parser.add_argument(
578
592
"--log_level",
@@ -586,52 +600,47 @@ def main():
586
600
"--print_report",
587
601
dest="print_report",
588
602
action="store_true",
589
-
help="Print a detailed report of all file processed.",
603
+
help="Print a detailed report of all file processed (default: True)",
590
604
)
591
-
592
605
parser.add_argument(
593
606
"--exclude_metadata",
594
607
dest="include_metadata",
595
608
action="store_false",
596
-
help="Exclude metadata on tokens consumed and the context passed to LLMs for prompt studio exported tools in the result for each file.",
609
+
help="Exclude metadata on tokens consumed and the context passed to LLMs for prompt studio exported tools in the result for each file (default: False)",
597
610
)
598
-
599
611
parser.add_argument(
600
612
"--no_verify",
601
613
dest="verify",
602
614
action="store_false",
603
-
help="Disable SSL certificate verification.",
604
-
)
605
-
606
-
parser.add_argument(
607
-
'--csv_report',
608
-
dest="csv_report",
609
-
type=str,
610
-
help='Path to export the detailed report as a CSV file',
0 commit comments