aboutsummaryrefslogtreecommitdiff
path: root/pplx_distributed.h
diff options
context:
space:
mode:
authorOnur Gündüz <ogunduz@gmail.com>2026-06-03 00:30:12 +0200
committerOnur Gündüz <ogunduz@gmail.com>2026-06-14 08:27:03 +0200
commit9d69c13793c4c69c080ed4273bcd36ded69de2bb (patch)
tree0797e83999613a327579d60dcf2b422bb7978d60 /pplx_distributed.h
parent8d412f8a225f3e337dac271ea2491ac3c1c099af (diff)
downloadffwd-9d69c13793c4c69c080ed4273bcd36ded69de2bb.tar.gz
ffwd-9d69c13793c4c69c080ed4273bcd36ded69de2bb.zip
mlx: add opt-in 8-bit weight quantization
Diffstat (limited to 'pplx_distributed.h')
-rw-r--r--pplx_distributed.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/pplx_distributed.h b/pplx_distributed.h
index 2979ede..f84056c 100644
--- a/pplx_distributed.h
+++ b/pplx_distributed.h
@@ -9,6 +9,11 @@
typedef struct pplx_dist_client pplx_dist_client_t;
+typedef struct {
+ int mlx_quantize_bits;
+ int mlx_quantize_group_size;
+} pplx_dist_options_t;
+
/*
* Open a coordinator-side connection. The coordinator owns layers
* [0, local_layer_end); the remote worker must own [local_layer_end, N).
@@ -16,6 +21,9 @@ typedef struct pplx_dist_client pplx_dist_client_t;
pplx_dist_client_t *pplx_dist_client_open(const char *model_dir,
const char *host, int port,
int local_layer_end, int use_mlx);
+pplx_dist_client_t *pplx_dist_client_open_with_options(
+ const char *model_dir, const char *host, int port,
+ int local_layer_end, int use_mlx, const pplx_dist_options_t *opts);
void pplx_dist_client_free(pplx_dist_client_t *client);
const pplx_config_t *pplx_dist_client_config(const pplx_dist_client_t *client);
@@ -30,5 +38,9 @@ int pplx_dist_client_embed_batch(pplx_dist_client_t *client,
*/
int pplx_dist_run_worker(const char *model_dir, const char *host, int port,
int layer_start, int layer_end, int use_mlx);
+int pplx_dist_run_worker_with_options(
+ const char *model_dir, const char *host, int port,
+ int layer_start, int layer_end, int use_mlx,
+ const pplx_dist_options_t *opts);
#endif /* PPLX_DISTRIBUTED_H */