All-in-one AI-Powered CLI Chat & Copilot that integrates 10+ AI platforms, including OpenAI, Azure-OpenAI, Gemini, VertexAI, Claude, Mistral, Cohere, Ollama, Ernie, Qianwen...
ctrlc_exit: false # Whether to exit REPL when Ctrl+C is pressed
Full Changelog: https://github.com/sigoden/aichat/compare/v0.15.0...v0.16.0
clients:
-- type: localai
++ type: openai-compatible
++ name: localai
block_threshold
configuration (#375)block_threshold: BLOCK_ONLY_HIGH # Optional field
save_session: null # Whether to save the session, if null, asking
.save session [name]
.set save_session <null|true|false>
.role <name> <text...> # Works in session
--save-session Whether to save the session
Full Changelog: https://github.com/sigoden/aichat/compare/v0.14.0...v0.15.0
When the total number of tokens in the session messages exceeds compress_threshold
, aichat will automatically compress the session.
This means you can chat forever in the session.
The default compress_threshold
is 2000, set this value to zero to disable automatic compression.
max_tokens
to max_input_tokens
(#339)To avoid misunderstandings. The max_input_tokens
also be referred to as context_window
.
models:
- name: mistral
-- max_tokens: 8192
++ max_input_tokens: 8192
claude
mistral
ernie
-c/--code
generate code only (#327).clear messages
to clear session messages (#332)Full Changelog: https://github.com/sigoden/aichat/compare/v0.13.0...v0.14.0
extra_fields
to models of localai/ollama clients by @kelvie in https://github.com/sigoden/aichat/pull/298
-e/--execute
to execute shell command by @sigoden in https://github.com/sigoden/aichat/pull/318
Full Changelog: https://github.com/sigoden/aichat/compare/v0.12.0...v0.13.0
Full Changelog: https://github.com/sigoden/aichat/compare/v0.11.0...v0.12.0
Full Changelog: https://github.com/sigoden/aichat/compare/v0.10.0...v0.11.0
.edit
〉::: This
is
a
multi-line
message
:::
coder〉.role shell how to unzip a file
unzip file.zip
coder〉
As shown above, you temporarily switched to the shell role in the coder role and sent a message. After sending, the current role is still coder.
config.prelude
For those who want aichat to enter a session after startup, you can set it as follows:
prelude: session:mysession
For those who want aichat to use a role after startup, you can set it as follows:
prelude: role:myrole
--list-models
If OpenAI releases a new model in the future, it can be used without upgrading Aichat.
$ aichat --model openai:gpt-4-vision-preview
〉.model openai:gpt-4-vision-preview
config.prelude
to allow setting default role/session by @sigoden in https://github.com/sigoden/aichat/pull/224
.edit
, use """ instead by @sigoden in https://github.com/sigoden/aichat/pull/225
Full Changelog: https://github.com/sigoden/aichat/compare/v0.9.0...v0.10.0
New in command mode
--list-sessions List all available sessions
-s, --session [<SESSION>] Create or reuse a session
New in chat mode
.session Start a context-aware chat session
.info session Show session info
.exit session End the current session
Other features:
config.conversation_first
, use aichat -s
instead.In command mode
aichat --info # Show system info
aichat --role shell --info # Show role info
aichat --session temp --info # Show session info
In chat mode
.info Print system info
.info role Show role info
.info session Show session info
Configuration:
wrap: no # Specify the text-wrapping mode (no*, auto, <max-width>)
wrap_code: false # Whether wrap code block
Command:
aichat -w 120 # set max width
aichat -w auto # use term width
aichat -w no # no wrap
light_theme: false # If set true, use light theme
wrap: no # Specify the text-wrapping mode (no*, auto, <max-width>)
wrap_code: false # Whether wrap code block
auto_copy: false # Automatically copy the last output to the clipboard
keybindings: emacs # REPL keybindings, possible values: emacs (default), vi
.copy
to Copy the last output to the clipboard.read
to Read the contents of a file and submit.edit
for Multi-line editing (CTRL+S to finish).info session
to show system info.info role
to show role info.conversation
to .session
.clear conversation
to .exit session
.clear role
to .exit role
.clear
.prompt
.hisotry
.clear history
AICHAT_API_KEY
with OPENAI_API_KEY
, Also support OPENAI_API_BASE
--prompt
and .prompt
are removedconfig.connect_timeout
by @sigoden in https://github.com/sigoden/aichat/pull/76
config.organization_id
by @sigoden in https://github.com/sigoden/aichat/pull/77
--info
by @sigoden in https://github.com/sigoden/aichat/pull/79
--dry-run
by @sigoden in https://github.com/sigoden/aichat/pull/83
Full Changelog: https://github.com/sigoden/aichat/compare/v0.7.0...v0.8.0
--prompt
for adding a prompt from cli by @sigoden in https://github.com/sigoden/aichat/pull/62
Full Changelog: https://github.com/sigoden/aichat/compare/v0.6.0...v0.7.0