File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
pgml-cms/docs/introduction/apis/client-sdks Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -57,9 +57,9 @@ Continuing with `main`
57
57
{% tab title="JavaScript" %}
58
58
` ` ` javascript
59
59
// Create a pipeline using the default model and splitter
60
- model = pgml .newModel ();
61
- splitter = pgml .newSplitter ();
62
- pipeline = pgml .Pipeline (" sample_pipeline" , model, splitter);
60
+ const model = pgml .newModel ();
61
+ const splitter = pgml .newSplitter ();
62
+ const pipeline = pgml .newPipeline (" sample_pipeline" , model, splitter);
63
63
await collection .add_pipeline (pipeline);
64
64
` ` `
65
65
{% endtab %}
@@ -87,6 +87,7 @@ Continuing with `main`
87
87
{% tabs %}
88
88
{% tab title="JavaScript" %}
89
89
` ` ` javascript
90
+ // Create and upsert documents
90
91
const documents = [
91
92
{
92
93
id: " Document One" ,
@@ -130,6 +131,7 @@ Continuing with `main`
130
131
{% tabs %}
131
132
{% tab title="JavaScript" %}
132
133
` ` ` javascript
134
+ // Query
133
135
const queryResults = await collection
134
136
.query ()
135
137
.vector_recall (" Some user query that will match document one first" , pipeline)
You can’t perform that action at this time.
0 commit comments