Skip to content

Commit

Permalink
Support --apibase on the GUI
Browse files Browse the repository at this point in the history
  • Loading branch information
machinewrapped committed Jul 18, 2023
1 parent f1318ef commit f582624
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions gui-subtrans.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ def parse_arguments():
parser.add_argument('-r', '--ratelimit', type=int, default=None, help="Maximum number of batches per minute to process")
parser.add_argument('-k', '--apikey', type=str, default=None, help="Your OpenAI API Key (https://platform.openai.com/account/api-keys)")
parser.add_argument('-p', '--project', type=str, default=None, help="Read or Write project file to working directory")
parser.add_argument('-b', '--apibase', type=str, default=None, help="API backend base address, the default value is https://api.openai.com/v1")
parser.add_argument('--minbatchsize', type=int, default=None, help="Minimum number of lines to consider starting a new batch")
parser.add_argument('--maxbatchsize', type=int, default=None, help="Maximum number of lines before starting a new batch is compulsory")
parser.add_argument('--batchthreshold', type=float, default=None, help="Number of seconds between lines to consider for batching")
Expand All @@ -38,6 +39,7 @@ def parse_arguments():

arguments = {
'api_key': args.apikey,
'api_base': args.apibase,
'max_lines': args.maxlines,
'rate_limit': args.ratelimit,
'target_language': args.target_language,
Expand Down

0 comments on commit f582624

Please sign in to comment.