mlx-code 0.0.2a6__tar.gz → 0.0.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,88 @@
1
+ Metadata-Version: 2.4
2
+ Name: mlx-code
3
+ Version: 0.0.4
4
+ Summary: Coding Agent for Mac
5
+ Home-page: https://github.com/JosefAlbers/mlx-code
6
+ Author: J Joe
7
+ Author-email: albersj66@gmail.com
8
+ License: Apache-2.0
9
+ Requires-Python: >=3.12.8
10
+ Description-Content-Type: text/markdown
11
+ License-File: LICENSE
12
+ Requires-Dist: mlx-lm>=0.31.3
13
+ Requires-Dist: numpy
14
+ Requires-Dist: httpx
15
+ Requires-Dist: pydantic
16
+ Dynamic: author
17
+ Dynamic: author-email
18
+ Dynamic: description
19
+ Dynamic: description-content-type
20
+ Dynamic: home-page
21
+ Dynamic: license
22
+ Dynamic: license-file
23
+ Dynamic: requires-dist
24
+ Dynamic: requires-python
25
+ Dynamic: summary
26
+
27
+ # mlx-code
28
+
29
+ [![Link](https://raw.githubusercontent.com/JosefAlbers/mlx-code/main/assets/mlx-code.gif)](https://youtu.be/bizPhrHL1_w)
30
+
31
+ A lightweight, powerful Coding Agent for Mac. Built on top of Apple's MLX framework, `mlx-code` provides fast, local inference with built-in prompt caching and robust tool-calling capabilities.
32
+
33
+ It features a multi-provider local server, a terminal-based chat REPL, and a dedicated TUI for inspecting logs.
34
+
35
+ ### Features
36
+
37
+ * **Local MLX Inference**: Powered by `mlx-lm` for optimized performance on Apple Silicon. Includes intelligent prompt caching.
38
+ * **Multi-Provider Compatibility**: Seamlessly translates and handles requests formatted for **Claude**, **Gemini**, **Codex**, **DeepSeek** and standard OpenAI APIs.
39
+ * **Built-in REPL & Tools**: Comes with `pie`, a fully-featured chat REPL with tool execution and reasoning token support.
40
+ * **TUI Log Viewer**: Includes a Curses-based Terminal UI for filtering, inspecting, and tracking JSON logs in real-time.
41
+ * **Server Mode**: Easily spin up a local server compatible with standard LLM tooling.
42
+
43
+ ### Quick Start
44
+
45
+ Install via pip and launch the agent immediately:
46
+
47
+ ```bash
48
+ pip install mlx-code
49
+ mc
50
+ ```
51
+
52
+ ### Command Line Interfaces
53
+
54
+ The package installs three primary command-line tools:
55
+ - mc (Main Agent/Server): Runs the core agent and local API server (defaults to 127.0.0.1:8000).
56
+ - me (REPL): Launches the interactive pie chat REPL.
57
+ - md (Diagnostics/Logs): Opens the TUI viewer to navigate and filter JSON logs generated by the agent.
58
+
59
+ ### Options
60
+
61
+ You can customize the model, server, and behavior using command-line flags.
62
+
63
+ ```bash
64
+ # Use Gemini CLI as the harness
65
+ mc --harness gemini
66
+
67
+ # Use a custom local LLM backend
68
+ mc --model mlx-community/Qwen3.5-4B-OptiQ-4bit
69
+
70
+ # Use DeepSeek V4 Flash API
71
+ me --deepseek
72
+
73
+ # Run the server only
74
+ mc --nocc
75
+
76
+ # General shell piping and chaining works too
77
+ echo "explain symgraph.py" | mc | cat - PLAN.md | mc
78
+ ```
79
+ *(For a full list of mc server arguments, run mc --help)*
80
+
81
+ ### Credits
82
+
83
+ - `main.py`: Built on [MLX](https://github.com/ml-explore/mlx) and [MLX LM](https://github.com/ml-explore/mlx-lm) by Apple.
84
+ - `pie.py`: Adapted from [pi](https://github.com/badlogic/pi-mono) by Mario Zechner (MIT License).
85
+
86
+ ### Licence
87
+
88
+ Apache License 2.0 — see LICENSE for details.
@@ -0,0 +1,62 @@
1
+ # mlx-code
2
+
3
+ [![Link](https://raw.githubusercontent.com/JosefAlbers/mlx-code/main/assets/mlx-code.gif)](https://youtu.be/bizPhrHL1_w)
4
+
5
+ A lightweight, powerful Coding Agent for Mac. Built on top of Apple's MLX framework, `mlx-code` provides fast, local inference with built-in prompt caching and robust tool-calling capabilities.
6
+
7
+ It features a multi-provider local server, a terminal-based chat REPL, and a dedicated TUI for inspecting logs.
8
+
9
+ ### Features
10
+
11
+ * **Local MLX Inference**: Powered by `mlx-lm` for optimized performance on Apple Silicon. Includes intelligent prompt caching.
12
+ * **Multi-Provider Compatibility**: Seamlessly translates and handles requests formatted for **Claude**, **Gemini**, **Codex**, **DeepSeek** and standard OpenAI APIs.
13
+ * **Built-in REPL & Tools**: Comes with `pie`, a fully-featured chat REPL with tool execution and reasoning token support.
14
+ * **TUI Log Viewer**: Includes a Curses-based Terminal UI for filtering, inspecting, and tracking JSON logs in real-time.
15
+ * **Server Mode**: Easily spin up a local server compatible with standard LLM tooling.
16
+
17
+ ### Quick Start
18
+
19
+ Install via pip and launch the agent immediately:
20
+
21
+ ```bash
22
+ pip install mlx-code
23
+ mc
24
+ ```
25
+
26
+ ### Command Line Interfaces
27
+
28
+ The package installs three primary command-line tools:
29
+ - mc (Main Agent/Server): Runs the core agent and local API server (defaults to 127.0.0.1:8000).
30
+ - me (REPL): Launches the interactive pie chat REPL.
31
+ - md (Diagnostics/Logs): Opens the TUI viewer to navigate and filter JSON logs generated by the agent.
32
+
33
+ ### Options
34
+
35
+ You can customize the model, server, and behavior using command-line flags.
36
+
37
+ ```bash
38
+ # Use Gemini CLI as the harness
39
+ mc --harness gemini
40
+
41
+ # Use a custom local LLM backend
42
+ mc --model mlx-community/Qwen3.5-4B-OptiQ-4bit
43
+
44
+ # Use DeepSeek V4 Flash API
45
+ me --deepseek
46
+
47
+ # Run the server only
48
+ mc --nocc
49
+
50
+ # General shell piping and chaining works too
51
+ echo "explain symgraph.py" | mc | cat - PLAN.md | mc
52
+ ```
53
+ *(For a full list of mc server arguments, run mc --help)*
54
+
55
+ ### Credits
56
+
57
+ - `main.py`: Built on [MLX](https://github.com/ml-explore/mlx) and [MLX LM](https://github.com/ml-explore/mlx-lm) by Apple.
58
+ - `pie.py`: Adapted from [pi](https://github.com/badlogic/pi-mono) by Mario Zechner (MIT License).
59
+
60
+ ### Licence
61
+
62
+ Apache License 2.0 — see LICENSE for details.
@@ -0,0 +1,4 @@
1
+ from .main import make_handler, generate
2
+ from .pie import run_repl
3
+
4
+ __all__ = ["make_handler", "run_repl"]