We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parent803731b commit34e64d8Copy full SHA for 34e64d8
pgml-extension/src/bindings/transformers/mod.rs
@@ -7,7 +7,7 @@ use anyhow::{anyhow, bail, Context, Result};
7
use pgrx::*;
8
use pyo3::prelude::*;
9
use pyo3::types::{PyBool,PyDict,PyFloat,PyInt,PyList,PyString,PyTuple};
10
-use serde::Deserialize;
+use serde::{Deserialize,Serialize};
11
use serde_json::Value;
12
13
usecrate::create_pymodule;
@@ -23,7 +23,7 @@ pub use transform::*;
23
create_pymodule!("/src/bindings/transformers/transformers.py");
24
25
// Need a wrapper so we can implement traits for it
26
-structJson(Value);
+pubstructJson(pubValue);
27
28
implFrom<Json>forValue{
29
fnfrom(value:Json) ->Self{
@@ -109,7 +109,7 @@ pub fn embed(transformer: &str, inputs: Vec<&str>, kwargs: &serde_json::Value) -
109
})
110
}
111
112
-#[derive(Deserialize)]
+#[derive(Debug,Deserialize,Serialize,PartialEq,Clone)]
113
pubstructRankResult{
114
pubcorpus_id:i64,
115
pubscore:f64,