mlx-examples/llms/mlx_lm/models
Awni Hannun fca087be49
More cache improvements (#1015)
* fix rotating kv cache for chat use case

* reorg + fixes to caching, unify prompt caching across types and use cases for e.g. caching during a chat

* nit in chat

* fix tests

* fix tests

* fix tests

* docs

* chat command

* comments + docs

* Define meta_state on all Cache implementations

* fixes + trim_prompt_cache api

* fix default model

---------

Co-authored-by: Angelos Katharopoulos <a_katharopoulos@apple.com>
2024-10-07 20:45:51 -07:00
..
__init__.py Mlx llm package (#301) 2024-01-12 10:25:56 -08:00
base.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
cache.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
cohere.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
dbrx.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
deepseek_v2.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
deepseek.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
gemma2.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
gemma.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
gpt2.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
gpt_bigcode.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
gpt_neox.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
internlm2.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
llama.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
mamba.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
minicpm.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
mixtral.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
nemotron.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
olmo.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
openelm.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
phi3.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
phi3small.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
phi.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
phimoe.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
phixtral.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
plamo.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
qwen2_moe.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
qwen2.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
qwen.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
recurrent_gemma.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
stablelm.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
starcoder2.py More cache improvements (#1015) 2024-10-07 20:45:51 -07:00
su_rope.py Add Phi-3.5-MoE (#946) 2024-08-24 06:52:33 -07:00
switch_layers.py Handle longer prompt/generation (#931) 2024-08-16 15:28:39 -07:00