Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 550ab15ef7e48dc913ac6dc9df75547917308dfc Mon Sep 17 00:00:00 2001
From aaa1f7247b3ff779f321fa76ccc12b66f212d5bd Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 10:19:37 +1000
Subject: [PATCH 01/81] Draft skippy ABI header
Subject: [PATCH 01/82] Draft skippy ABI header

---
include/skippy.h | 241 +++++++++++++++++++++++++++++++++++++++++++++++
Expand All @@ -10,7 +10,7 @@ Subject: [PATCH 01/81] Draft skippy ABI header

diff --git a/include/skippy.h b/include/skippy.h
new file mode 100644
index 00000000..b0f3d227
index 000000000..b0f3d227f
--- /dev/null
+++ b/include/skippy.h
@@ -0,0 +1,241 @@
Expand Down Expand Up @@ -256,5 +256,5 @@ index 00000000..b0f3d227
+
+#endif // SKIPPY_ABI_H
--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 9ebca2cf952918f3114fc9b332febc84660f9f73 Mon Sep 17 00:00:00 2001
From 3581accd09ae328190aaaadb70ebc0521c24c365 Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 10:28:54 +1000
Subject: [PATCH 02/81] Implement skippy model info ABI
Subject: [PATCH 02/82] Implement skippy model info ABI

---
CMakeLists.txt | 1 +
Expand All @@ -11,10 +11,10 @@ Subject: [PATCH 02/81] Implement skippy model info ABI
create mode 100644 src/skippy.cpp

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4f7f4eca..a08a32fb 100644
index 9e7b1253c..d1e6b4e6d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -258,6 +258,7 @@ set(LLAMA_BIN_INSTALL_DIR ${CMAKE_INSTALL_BINDIR} CACHE PATH "Location o
@@ -235,6 +235,7 @@ set(LLAMA_BIN_INSTALL_DIR ${CMAKE_INSTALL_BINDIR} CACHE PATH "Location o

set(LLAMA_PUBLIC_HEADERS
${CMAKE_CURRENT_SOURCE_DIR}/include/llama.h
Expand All @@ -23,10 +23,10 @@ index 4f7f4eca..a08a32fb 100644

set_target_properties(llama
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 7b1fcfca..8f3aa8c1 100644
index d15ccfd99..2526f45cd 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -34,6 +34,7 @@ add_library(llama
@@ -35,6 +35,7 @@ add_library(llama
llama-model.cpp
llama-quant.cpp
llama-sampler.cpp
Expand All @@ -36,7 +36,7 @@ index 7b1fcfca..8f3aa8c1 100644
unicode.cpp
diff --git a/src/skippy.cpp b/src/skippy.cpp
new file mode 100644
index 00000000..bd94fa37
index 000000000..bd94fa37f
--- /dev/null
+++ b/src/skippy.cpp
@@ -0,0 +1,219 @@
Expand Down Expand Up @@ -260,5 +260,5 @@ index 00000000..bd94fa37
+
+}
--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
From 3373ba0729f0aa133194bc7f59e640e2de537668 Mon Sep 17 00:00:00 2001
From 7f889e8044c192797c0eb9f4dfbf61b8ede502b5 Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 11:04:49 +1000
Subject: [PATCH 03/81] Implement single-stage runtime ABI baseline
Subject: [PATCH 03/82] Implement single-stage runtime ABI baseline

---
src/skippy.cpp | 323 ++++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 322 insertions(+), 1 deletion(-)

diff --git a/src/skippy.cpp b/src/skippy.cpp
index bd94fa37..4feca3b8 100644
index bd94fa37f..4feca3b8f 100644
--- a/src/skippy.cpp
+++ b/src/skippy.cpp
@@ -2,14 +2,27 @@
Expand Down Expand Up @@ -371,5 +371,5 @@ index bd94fa37..4feca3b8 100644
const char * path,
struct skippy_model_info ** out_info,
--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 2873f2d485da528de4c389ae3ec2260f29b83065 Mon Sep 17 00:00:00 2001
From 655e0e84af1fd7c60e12a0d25b8bbe5bf8e3bddd Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 11:57:45 +1000
Subject: [PATCH 04/81] Implement runtime-slice tensor filtering
Subject: [PATCH 04/82] Implement runtime-slice tensor filtering

---
src/llama-model-loader.cpp | 44 ++++++++++++++++++++++++++++++++++++++
Expand All @@ -10,7 +10,7 @@ Subject: [PATCH 04/81] Implement runtime-slice tensor filtering
3 files changed, 95 insertions(+), 1 deletion(-)

diff --git a/src/llama-model-loader.cpp b/src/llama-model-loader.cpp
index c645d078..7782c250 100644
index 474cabdfc..869092306 100644
--- a/src/llama-model-loader.cpp
+++ b/src/llama-model-loader.cpp
@@ -17,6 +17,16 @@ static const size_t kiB = 1024;
Expand All @@ -30,7 +30,7 @@ index c645d078..7782c250 100644
const char * llama_file_version_name(llama_fver version) {
switch (version) {
case GGUF_FILE_VERSION_V1: return "GGUF V1 (support until nov 2023)";
@@ -1098,6 +1108,40 @@ struct ggml_tensor * llama_model_loader::create_tensor(
@@ -1100,6 +1110,40 @@ struct ggml_tensor * llama_model_loader::create_tensor(
throw std::runtime_error(format("missing tensor info mapping for %s", tn.str().c_str()));
}

Expand Down Expand Up @@ -72,7 +72,7 @@ index c645d078..7782c250 100644
if (info.op == GGML_OP_NONE || (flags & TENSOR_SKIP)) {
const size_t nbytes = ggml_nbytes(t_meta);
diff --git a/src/llama-model-loader.h b/src/llama-model-loader.h
index c476026d..3fb84fdd 100644
index c476026d3..3fb84fdd2 100644
--- a/src/llama-model-loader.h
+++ b/src/llama-model-loader.h
@@ -20,6 +20,17 @@ using llama_buf_map = std::unordered_map<uint32_t, ggml_backend_buffer_t>;
Expand All @@ -94,7 +94,7 @@ index c476026d..3fb84fdd 100644
GGUF_FILE_VERSION_V1 = 1,
GGUF_FILE_VERSION_V2 = 2,
diff --git a/src/skippy.cpp b/src/skippy.cpp
index 4feca3b8..10876ee5 100644
index 4feca3b8f..10876ee50 100644
--- a/src/skippy.cpp
+++ b/src/skippy.cpp
@@ -1,6 +1,7 @@
Expand Down Expand Up @@ -191,5 +191,5 @@ index 4feca3b8..10876ee5 100644
*out_session = nullptr;

--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
From 82245852930b1698669cfb15bf0f5609353bf9c3 Mon Sep 17 00:00:00 2001
From 1da4c2df3ba0ea3ca20f9671ab173ba21c8c67dd Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 12:15:31 +1000
Subject: [PATCH 05/81] Add activation frame runtime ABI
Subject: [PATCH 05/82] Add activation frame runtime ABI

---
include/skippy.h | 50 +++++++++++++++++++++
src/skippy.cpp | 112 ++++++++++++++++++++++++++++++++++++++++++++++-
2 files changed, 161 insertions(+), 1 deletion(-)

diff --git a/include/skippy.h b/include/skippy.h
index b0f3d227..cd72379d 100644
index b0f3d227f..cd72379df 100644
--- a/include/skippy.h
+++ b/include/skippy.h
@@ -36,6 +36,7 @@ enum skippy_feature {
Expand Down Expand Up @@ -91,7 +91,7 @@ index b0f3d227..cd72379d 100644
struct skippy_session * session,
int32_t layer_start,
diff --git a/src/skippy.cpp b/src/skippy.cpp
index 10876ee5..4aef362a 100644
index 10876ee50..4aef362ab 100644
--- a/src/skippy.cpp
+++ b/src/skippy.cpp
@@ -187,6 +187,44 @@ static llama_token skippy_greedy_sample(skippy_session * session) {
Expand Down Expand Up @@ -228,5 +228,5 @@ index 10876ee5..4aef362a 100644
struct skippy_session * session,
int32_t layer_start,
--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From fab9a753c08883775e7a3a53784bbfeb8c8dcaba Mon Sep 17 00:00:00 2001
From ad8f9af6588f8f1482089b9bbd0ab71ae015363d Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 12:33:30 +1000
Subject: [PATCH 06/81] Execute runtime-slice activation frames
Subject: [PATCH 06/82] Execute runtime-slice activation frames

---
src/llama-graph.cpp | 52 ++++---
Expand All @@ -11,10 +11,10 @@ Subject: [PATCH 06/81] Execute runtime-slice activation frames
4 files changed, 365 insertions(+), 53 deletions(-)

diff --git a/src/llama-graph.cpp b/src/llama-graph.cpp
index fc027de8..2e7ae884 100644
index 7468bd9b7..3f6342b2a 100644
--- a/src/llama-graph.cpp
+++ b/src/llama-graph.cpp
@@ -18,6 +18,20 @@
@@ -19,6 +19,20 @@
#include <sstream>
#include <unordered_set>

Expand All @@ -35,7 +35,7 @@ index fc027de8..2e7ae884 100644
// dedup helpers

static ggml_tensor * build_attn_inp_kq_mask(
@@ -1747,28 +1761,32 @@ ggml_tensor * llm_graph_context::build_inp_embd(ggml_tensor * tok_embd) const {
@@ -1842,28 +1856,32 @@ ggml_tensor * llm_graph_context::build_inp_embd(ggml_tensor * tok_embd) const {
{
auto & cur = inps[0];

Expand Down Expand Up @@ -86,10 +86,10 @@ index fc027de8..2e7ae884 100644
}

diff --git a/src/llama-graph.h b/src/llama-graph.h
index bf677823..f01cbabd 100644
index cc5cfe51d..84b7124a1 100644
--- a/src/llama-graph.h
+++ b/src/llama-graph.h
@@ -27,6 +27,18 @@ class llama_memory_recurrent_context;
@@ -28,6 +28,18 @@ class llama_memory_recurrent_context;
class llama_memory_hybrid_context;
class llama_memory_hybrid_iswa_context;

Expand All @@ -109,7 +109,7 @@ index bf677823..f01cbabd 100644
enum llm_graph_type {
LLM_GRAPH_TYPE_DEFAULT,
diff --git a/src/models/llama.cpp b/src/models/llama.cpp
index cef66d05..581826b0 100644
index 4bfebc884..23864f0dd 100644
--- a/src/models/llama.cpp
+++ b/src/models/llama.cpp
@@ -105,7 +105,12 @@ llama_model_llama::graph<embed>::graph(const llama_model & model, const llm_grap
Expand All @@ -135,10 +135,10 @@ index cef66d05..581826b0 100644

- for (int il = 0; il < n_layer; ++il) {
+ for (int il = il_start; il < il_end; ++il) {
ggml_tensor * inpSA = inpL;
res->t_layer_inp[il] = inpL;

// norm
@@ -226,6 +231,13 @@ llama_model_llama::graph<embed>::graph(const llama_model & model, const llm_grap
ggml_tensor * inpSA = inpL;
@@ -228,6 +233,13 @@ llama_model_llama::graph<embed>::graph(const llama_model & model, const llm_grap
}
cur = inpL;

Expand All @@ -153,7 +153,7 @@ index cef66d05..581826b0 100644
model.output_norm, NULL,
LLM_NORM_RMS, -1);
diff --git a/src/skippy.cpp b/src/skippy.cpp
index 4aef362a..732a1a15 100644
index 4aef362ab..732a1a15c 100644
--- a/src/skippy.cpp
+++ b/src/skippy.cpp
@@ -1,6 +1,8 @@
Expand Down Expand Up @@ -612,5 +612,5 @@ index 4aef362a..732a1a15 100644

enum skippy_status skippy_export_state(
--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
From 9f7d122a97d176fa31253dd8b5ce84764c234319 Mon Sep 17 00:00:00 2001
From 47841b44bdf2dbffc25dd15b70ffcc93a1a6364c Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 14:39:10 +1000
Subject: [PATCH 07/81] Implement GGUF slice writer ABI
Subject: [PATCH 07/82] Implement GGUF slice writer ABI

---
src/skippy.cpp | 413 +++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 413 insertions(+)

diff --git a/src/skippy.cpp b/src/skippy.cpp
index 732a1a15..2b54a7db 100644
index 732a1a15c..2b54a7db7 100644
--- a/src/skippy.cpp
+++ b/src/skippy.cpp
@@ -11,9 +11,12 @@
Expand Down Expand Up @@ -470,5 +470,5 @@ index 732a1a15..2b54a7db 100644
+
}
--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
From 991a7982943373f01a161b959cad9816201a12a5 Mon Sep 17 00:00:00 2001
From 3daa6935328e8d61c23a244be7c0327733339005 Mon Sep 17 00:00:00 2001
From: James Dumay <jameswdumay@gmail.com>
Date: Sat, 25 Apr 2026 14:51:18 +1000
Subject: [PATCH 08/81] Add GGUF package part composer ABI
Subject: [PATCH 08/82] Add GGUF package part composer ABI

---
include/skippy.h | 6 +
src/skippy.cpp | 318 +++++++++++++++++++++++++++++++++--------------
2 files changed, 230 insertions(+), 94 deletions(-)

diff --git a/include/skippy.h b/include/skippy.h
index cd72379d..7ab93d35 100644
index cd72379df..7ab93d353 100644
--- a/include/skippy.h
+++ b/include/skippy.h
@@ -284,6 +284,12 @@ LLAMA_API enum skippy_status skippy_write_slice_gguf(
Expand All @@ -26,7 +26,7 @@ index cd72379d..7ab93d35 100644
}
#endif
diff --git a/src/skippy.cpp b/src/skippy.cpp
index 2b54a7db..26169320 100644
index 2b54a7db7..261693203 100644
--- a/src/skippy.cpp
+++ b/src/skippy.cpp
@@ -14,6 +14,7 @@
Expand Down Expand Up @@ -434,5 +434,5 @@ index 2b54a7db..26169320 100644

return skippy_success(out_error);
--
2.50.1 (Apple Git-155)
2.54.0 (Apple Git-156)

Loading
Loading