diff options
| author | sigoden <sigoden@gmail.com> | 2024-04-24 07:16:56 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-24 07:16:56 +0800 |
| commit | 0a4c0413ef0154cde2e3485ec0415e6069596a23 (patch) | |
| tree | 02527d5ee4b23b43a34bf90eeb817e1cc066d97c /scripts | |
| parent | 9c6c9f10a27d0993636b453f39d8934c95c5c2b2 (diff) | |
| download | aichat-0a4c0413ef0154cde2e3485ec0415e6069596a23.tar.gz | |
feat: serve all LLMs as OpenAI-compatible API (#431)
Diffstat (limited to 'scripts')
| -rw-r--r-- | scripts/completions/aichat.bash | 2 | ||||
| -rw-r--r-- | scripts/completions/aichat.fish | 1 | ||||
| -rw-r--r-- | scripts/completions/aichat.nu | 1 | ||||
| -rw-r--r-- | scripts/completions/aichat.ps1 | 1 | ||||
| -rw-r--r-- | scripts/completions/aichat.zsh | 1 |
5 files changed, 5 insertions, 1 deletions
diff --git a/scripts/completions/aichat.bash b/scripts/completions/aichat.bash index 0d72747..f0b9bc3 100644 --- a/scripts/completions/aichat.bash +++ b/scripts/completions/aichat.bash @@ -19,7 +19,7 @@ _aichat() { case "${cmd}" in aichat) - opts="-m -r -s -e -c -f -H -S -w -h -V --model --role --session --save-session --execute --code --file --no-highlight --no-stream --wrap --light-theme --dry-run --info --list-models --list-roles --list-sessions --help --version" + opts="-m -r -s -e -c -f -H -S -w -h -V --model --role --session --save-session --serve --execute --code --file --no-highlight --no-stream --wrap --light-theme --dry-run --info --list-models --list-roles --list-sessions --help --version" if [[ ${cur} == -* || ${COMP_CWORD} -eq 1 ]] ; then COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") ) return 0 diff --git a/scripts/completions/aichat.fish b/scripts/completions/aichat.fish index 736ca36..586b745 100644 --- a/scripts/completions/aichat.fish +++ b/scripts/completions/aichat.fish @@ -4,6 +4,7 @@ complete -c aichat -s s -l session -x -a"(aichat --list-sessions)" -d 'Start or complete -c aichat -s f -l file -d 'Include files with the message' -r -F complete -c aichat -s w -l wrap -d 'Control text wrapping (no, auto, <max-width>)' complete -c aichat -l save-session -d 'Forces the session to be saved' +complete -c aichat -l serve -d 'Serve all LLMs as OpenAI-compatible API' complete -c aichat -s e -l execute -d 'Execute commands in natural language' complete -c aichat -s c -l code -d 'Output code only' complete -c aichat -s H -l no-highlight -d 'Turn off syntax highlighting' diff --git a/scripts/completions/aichat.nu b/scripts/completions/aichat.nu index 03917a6..95cda81 100644 --- a/scripts/completions/aichat.nu +++ b/scripts/completions/aichat.nu @@ -28,6 +28,7 @@ module completions { --role(-r): string@"nu-complete aichat role" # Select a role --session(-s): string@"nu-complete aichat role" # Start or join a session --save-session # Forces the session to be saved + --serve # Serve all LLMs as OpenAI-compatible API --execute(-e) # Execute commands in natural language --code(-c) # Output code only --file(-f): string # Include files with the message diff --git a/scripts/completions/aichat.ps1 b/scripts/completions/aichat.ps1 index afd9c07..7be4bcf 100644 --- a/scripts/completions/aichat.ps1 +++ b/scripts/completions/aichat.ps1 @@ -31,6 +31,7 @@ Register-ArgumentCompleter -Native -CommandName 'aichat' -ScriptBlock { [CompletionResult]::new('-w', '-w', [CompletionResultType]::ParameterName, 'Control text wrapping (no, auto, <max-width>)') [CompletionResult]::new('--wrap', '--wrap', [CompletionResultType]::ParameterName, 'Control text wrapping (no, auto, <max-width>)') [CompletionResult]::new('--save-session', '--save-session', [CompletionResultType]::ParameterName, 'Forces the session to be saved') + [CompletionResult]::new('--serve', '--serve', [CompletionResultType]::ParameterName, 'Serve all LLMs as OpenAI-compatible API') [CompletionResult]::new('-e', '-e', [CompletionResultType]::ParameterName, 'Execute commands in natural language') [CompletionResult]::new('--execute', '--execute', [CompletionResultType]::ParameterName, 'Execute commands in natural language') [CompletionResult]::new('-c', '-c', [CompletionResultType]::ParameterName, 'Output code only') diff --git a/scripts/completions/aichat.zsh b/scripts/completions/aichat.zsh index 66f9bbb..5f7a74b 100644 --- a/scripts/completions/aichat.zsh +++ b/scripts/completions/aichat.zsh @@ -26,6 +26,7 @@ _aichat() { '-w+[Control text wrapping (no, auto, <max-width>)]:WRAP: ' \ '--wrap=[Control text wrapping (no, auto, <max-width>)]:WRAP: ' \ '--save-session[Forces the session to be saved]' \ +'--serve[Serve all LLMs as OpenAI-compatible API]' \ '-e[Execute commands in natural language]' \ '--execute[Execute commands in natural language]' \ '-c[Output code only]' \ |
