Skip to content

Commit 4ee3b10

Browse files
committed
Switch to wit-bindgen 0.34
Signed-off-by: itowlson <[email protected]>
1 parent d373a79 commit 4ee3b10

File tree

10 files changed

+145
-103
lines changed

10 files changed

+145
-103
lines changed

Cargo.lock

Lines changed: 120 additions & 79 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,6 @@ rust-version = "1.73"
9090
homepage = "https://developer.fermyon.com/spin/v2/rust-components"
9191

9292
[workspace.dependencies]
93-
wit-bindgen = "0.16.0"
93+
wit-bindgen = "0.34.0"
9494
futures = "0.3.28"
9595
once_cell = "1.18.0"

src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ pub mod wit {
3131
"wasi:io/[email protected]": spin_executor::bindings::wasi::io::error,
3232
"wasi:io/[email protected]": spin_executor::bindings::wasi::io::streams,
3333
"wasi:io/[email protected]": spin_executor::bindings::wasi::io::poll,
34-
}
34+
},
35+
generate_all,
3536
});
3637
pub use fermyon::spin2_0_0 as v2;
3738
pub use spin::postgres::postgres as pg3;

wit/deps/[email protected]/postgres.wit

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ interface postgres {
3535
int16(s16),
3636
int32(s32),
3737
int64(s64),
38-
floating32(float32),
39-
floating64(float64),
38+
floating32(f32),
39+
floating64(f64),
4040
str(string),
4141
binary(list<u8>),
4242
date(tuple<s32, u8, u8>), // (year, month, day)
@@ -57,8 +57,8 @@ interface postgres {
5757
int16(s16),
5858
int32(s32),
5959
int64(s64),
60-
floating32(float32),
61-
floating64(float64),
60+
floating32(f32),
61+
floating64(f64),
6262
str(string),
6363
binary(list<u8>),
6464
date(tuple<s32, u8, u8>), // (year, month, day)

wit/deps/[email protected]/llm.wit

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ interface llm {
1010
/// Note: the backing implementation may return less tokens.
1111
max-tokens: u32,
1212
/// The amount the model should avoid repeating tokens.
13-
repeat-penalty: float32,
13+
repeat-penalty: f32,
1414
/// The number of tokens the model should apply the repeat penalty to.
1515
repeat-penalty-last-n-token-count: u32,
1616
/// The randomness with which the next token is selected.
17-
temperature: float32,
17+
temperature: f32,
1818
/// The number of possible next tokens the model will choose from.
1919
top-k: u32,
2020
/// The probability total of next tokens the model will choose from.
21-
top-p: float32
21+
top-p: f32
2222
}
2323

2424
/// The set of errors which may be raised by functions in this interface
@@ -57,7 +57,7 @@ interface llm {
5757
/// Result of generating embeddings
5858
record embeddings-result {
5959
/// The embeddings generated by the request
60-
embeddings: list<list<float32>>,
60+
embeddings: list<list<f32>>,
6161
/// Usage related to the embeddings generation request
6262
usage: embeddings-usage
6363
}

wit/deps/[email protected]/rdbms-types.wit

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ interface rdbms-types {
3737
uint16(u16),
3838
uint32(u32),
3939
uint64(u64),
40-
floating32(float32),
41-
floating64(float64),
40+
floating32(f32),
41+
floating64(f64),
4242
str(string),
4343
binary(list<u8>),
4444
db-null,
@@ -56,8 +56,8 @@ interface rdbms-types {
5656
uint16(u16),
5757
uint32(u32),
5858
uint64(u64),
59-
floating32(float32),
60-
floating64(float64),
59+
floating32(f32),
60+
floating64(f64),
6161
str(string),
6262
binary(list<u8>),
6363
db-null,

wit/deps/[email protected]/sqlite.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ interface sqlite {
4242
/// A single column's result from a database query
4343
variant value {
4444
integer(s64),
45-
real(float64),
45+
real(f64),
4646
text(string),
4747
blob(list<u8>),
4848
null

wit/deps/spin@unversioned/llm.wit

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ interface llm {
1010
/// Note: the backing implementation may return less tokens.
1111
max-tokens: u32,
1212
/// The amount the model should avoid repeating tokens.
13-
repeat-penalty: float32,
13+
repeat-penalty: f32,
1414
/// The number of tokens the model should apply the repeat penalty to.
1515
repeat-penalty-last-n-token-count: u32,
1616
/// The randomness with which the next token is selected.
17-
temperature: float32,
17+
temperature: f32,
1818
/// The number of possible next tokens the model will choose from.
1919
top-k: u32,
2020
/// The probability total of next tokens the model will choose from.
21-
top-p: float32
21+
top-p: f32
2222
}
2323

2424
/// The set of errors which may be raised by functions in this interface
@@ -57,7 +57,7 @@ interface llm {
5757
/// Result of generating embeddings
5858
record embeddings-result {
5959
/// The embeddings generated by the request
60-
embeddings: list<list<float32>>,
60+
embeddings: list<list<f32>>,
6161
/// Usage related to the embeddings generation request
6262
usage: embeddings-usage
6363
}

wit/deps/spin@unversioned/rdbms-types.wit

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ interface rdbms-types {
2626
uint16(u16),
2727
uint32(u32),
2828
uint64(u64),
29-
floating32(float32),
30-
floating64(float64),
29+
floating32(f32),
30+
floating64(f64),
3131
str(string),
3232
binary(list<u8>),
3333
db-null,
@@ -44,8 +44,8 @@ interface rdbms-types {
4444
uint16(u16),
4545
uint32(u32),
4646
uint64(u64),
47-
floating32(float32),
48-
floating64(float64),
47+
floating32(f32),
48+
floating64(f64),
4949
str(string),
5050
binary(list<u8>),
5151
db-null,

wit/deps/spin@unversioned/sqlite.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ interface sqlite {
4444

4545
variant value {
4646
integer(s64),
47-
real(float64),
47+
real(f64),
4848
text(string),
4949
blob(list<u8>),
5050
null

0 commit comments

Comments
 (0)