@falkordb/text-to-cypher 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -8,7 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
8
8
  ## [0.1.0] - 2025-12-23
9
9
 
10
10
  ### Added
11
- - Initial release of text-to-cypher-node
11
+ - Initial release of @falkordb/text-to-cypher
12
12
  - NAPI-RS bindings for the text-to-cypher Rust library
13
13
  - `TextToCypher` class with the following methods:
14
14
  - `textToCypher(graphName, question)` - Convert natural language to Cypher and execute
package/INTEGRATION.md CHANGED
@@ -1,17 +1,17 @@
1
1
  # Integration Guide for FalkorDB Browser
2
2
 
3
- This guide explains how to integrate `@falkordb/text-to-cypher-node` into the [FalkorDB Browser](https://github.com/FalkorDB/falkordb-browser).
3
+ This guide explains how to integrate `@falkordb/text-to-cypher` into the [FalkorDB Browser](https://github.com/FalkorDB/falkordb-browser).
4
4
 
5
5
  ## Overview
6
6
 
7
- The FalkorDB Browser can use text-to-cypher-node to provide a natural language interface for querying graphs. Users can ask questions in plain English instead of writing Cypher queries.
7
+ The FalkorDB Browser can use @falkordb/text-to-cypher to provide a natural language interface for querying graphs. Users can ask questions in plain English instead of writing Cypher queries.
8
8
 
9
9
  ## Installation
10
10
 
11
11
  In your FalkorDB Browser project:
12
12
 
13
13
  ```bash
14
- npm install @falkordb/text-to-cypher-node
14
+ npm install @falkordb/text-to-cypher
15
15
  ```
16
16
 
17
17
  ## Backend Integration (Node.js/Express)
@@ -20,7 +20,7 @@ npm install @falkordb/text-to-cypher-node
20
20
 
21
21
  ```typescript
22
22
  // services/textToCypherService.ts
23
- import { TextToCypher, TextToCypherResponse } from '@falkordb/text-to-cypher-node';
23
+ import { TextToCypher, TextToCypherResponse } from '@falkordb/text-to-cypher';
24
24
 
25
25
  export class TextToCypherService {
26
26
  private client: TextToCypher;
package/README.md CHANGED
@@ -1,8 +1,8 @@
1
- # @falkordb/text-to-cypher-node
1
+ # @falkordb/text-to-cypher
2
2
 
3
3
  Node.js bindings for the [FalkorDB text-to-cypher](https://github.com/FalkorDB/text-to-cypher) library - Convert natural language to Cypher queries using AI.
4
4
 
5
- [![npm version](https://img.shields.io/npm/v/@falkordb/text-to-cypher-node.svg)](https://www.npmjs.com/package/@falkordb/text-to-cypher-node)
5
+ [![npm version](https://img.shields.io/npm/v/@falkordb/text-to-cypher.svg)](https://www.npmjs.com/package/@falkordb/text-to-cypher)
6
6
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
7
7
 
8
8
  ## Features
@@ -17,7 +17,7 @@ Node.js bindings for the [FalkorDB text-to-cypher](https://github.com/FalkorDB/t
17
17
  ## Installation
18
18
 
19
19
  ```bash
20
- npm install @falkordb/text-to-cypher-node
20
+ npm install @falkordb/text-to-cypher
21
21
  ```
22
22
 
23
23
  **📚 New to this library? Check out the [Quick Start Guide](QUICKSTART.md) for a 5-minute introduction!**
@@ -25,7 +25,7 @@ npm install @falkordb/text-to-cypher-node
25
25
  ## Quick Start
26
26
 
27
27
  ```javascript
28
- const { TextToCypher } = require('@falkordb/text-to-cypher-node');
28
+ const { TextToCypher } = require('@falkordb/text-to-cypher');
29
29
 
30
30
  // Create a client
31
31
  const client = new TextToCypher({
@@ -175,7 +175,7 @@ See [genai documentation](https://docs.rs/genai/latest/genai/) for a complete li
175
175
  ### Using with FalkorDB Browser
176
176
 
177
177
  ```javascript
178
- const { TextToCypher } = require('@falkordb/text-to-cypher-node');
178
+ const { TextToCypher } = require('@falkordb/text-to-cypher');
179
179
 
180
180
  // In your Express.js or other Node.js server
181
181
  app.post('/api/text-to-cypher', async (req, res) => {
@@ -199,7 +199,7 @@ app.post('/api/text-to-cypher', async (req, res) => {
199
199
  ### TypeScript Usage
200
200
 
201
201
  ```typescript
202
- import { TextToCypher, ClientOptions, TextToCypherResponse } from '@falkordb/text-to-cypher-node';
202
+ import { TextToCypher, ClientOptions, TextToCypherResponse } from '@falkordb/text-to-cypher';
203
203
 
204
204
  const options: ClientOptions = {
205
205
  model: 'gpt-4o-mini',
@@ -1,6 +1,6 @@
1
1
  # Examples
2
2
 
3
- This directory contains example code demonstrating how to use `@falkordb/text-to-cypher-node`.
3
+ This directory contains example code demonstrating how to use `@falkordb/text-to-cypher`.
4
4
 
5
5
  ## Running Examples
6
6
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Basic usage example for text-to-cypher-node
2
+ * Basic usage example for @falkordb/text-to-cypher
3
3
  *
4
4
  * This example demonstrates how to:
5
5
  * 1. Create a TextToCypher client
@@ -1,5 +1,5 @@
1
1
  /**
2
- * TypeScript example for text-to-cypher-node
2
+ * TypeScript example for @falkordb/text-to-cypher
3
3
  */
4
4
 
5
5
  import { TextToCypher, ClientOptions, TextToCypherResponse } from '../index';
package/index.js CHANGED
@@ -32,24 +32,24 @@ switch (platform) {
32
32
  case 'android':
33
33
  switch (arch) {
34
34
  case 'arm64':
35
- localFileExisted = existsSync(join(__dirname, 'text-to-cypher-node.android-arm64.node'))
35
+ localFileExisted = existsSync(join(__dirname, 'text-to-cypher.android-arm64.node'))
36
36
  try {
37
37
  if (localFileExisted) {
38
- nativeBinding = require('./text-to-cypher-node.android-arm64.node')
38
+ nativeBinding = require('./text-to-cypher.android-arm64.node')
39
39
  } else {
40
- nativeBinding = require('@falkordb/text-to-cypher-node-android-arm64')
40
+ nativeBinding = require('@falkordb/text-to-cypher-android-arm64')
41
41
  }
42
42
  } catch (e) {
43
43
  loadError = e
44
44
  }
45
45
  break
46
46
  case 'arm':
47
- localFileExisted = existsSync(join(__dirname, 'text-to-cypher-node.android-arm-eabi.node'))
47
+ localFileExisted = existsSync(join(__dirname, 'text-to-cypher.android-arm-eabi.node'))
48
48
  try {
49
49
  if (localFileExisted) {
50
- nativeBinding = require('./text-to-cypher-node.android-arm-eabi.node')
50
+ nativeBinding = require('./text-to-cypher.android-arm-eabi.node')
51
51
  } else {
52
- nativeBinding = require('@falkordb/text-to-cypher-node-android-arm-eabi')
52
+ nativeBinding = require('@falkordb/text-to-cypher-android-arm-eabi')
53
53
  }
54
54
  } catch (e) {
55
55
  loadError = e
@@ -63,13 +63,13 @@ switch (platform) {
63
63
  switch (arch) {
64
64
  case 'x64':
65
65
  localFileExisted = existsSync(
66
- join(__dirname, 'text-to-cypher-node.win32-x64-msvc.node')
66
+ join(__dirname, 'text-to-cypher.win32-x64-msvc.node')
67
67
  )
68
68
  try {
69
69
  if (localFileExisted) {
70
- nativeBinding = require('./text-to-cypher-node.win32-x64-msvc.node')
70
+ nativeBinding = require('./text-to-cypher.win32-x64-msvc.node')
71
71
  } else {
72
- nativeBinding = require('@falkordb/text-to-cypher-node-win32-x64-msvc')
72
+ nativeBinding = require('@falkordb/text-to-cypher-win32-x64-msvc')
73
73
  }
74
74
  } catch (e) {
75
75
  loadError = e
@@ -77,13 +77,13 @@ switch (platform) {
77
77
  break
78
78
  case 'ia32':
79
79
  localFileExisted = existsSync(
80
- join(__dirname, 'text-to-cypher-node.win32-ia32-msvc.node')
80
+ join(__dirname, 'text-to-cypher.win32-ia32-msvc.node')
81
81
  )
82
82
  try {
83
83
  if (localFileExisted) {
84
- nativeBinding = require('./text-to-cypher-node.win32-ia32-msvc.node')
84
+ nativeBinding = require('./text-to-cypher.win32-ia32-msvc.node')
85
85
  } else {
86
- nativeBinding = require('@falkordb/text-to-cypher-node-win32-ia32-msvc')
86
+ nativeBinding = require('@falkordb/text-to-cypher-win32-ia32-msvc')
87
87
  }
88
88
  } catch (e) {
89
89
  loadError = e
@@ -91,13 +91,13 @@ switch (platform) {
91
91
  break
92
92
  case 'arm64':
93
93
  localFileExisted = existsSync(
94
- join(__dirname, 'text-to-cypher-node.win32-arm64-msvc.node')
94
+ join(__dirname, 'text-to-cypher.win32-arm64-msvc.node')
95
95
  )
96
96
  try {
97
97
  if (localFileExisted) {
98
- nativeBinding = require('./text-to-cypher-node.win32-arm64-msvc.node')
98
+ nativeBinding = require('./text-to-cypher.win32-arm64-msvc.node')
99
99
  } else {
100
- nativeBinding = require('@falkordb/text-to-cypher-node-win32-arm64-msvc')
100
+ nativeBinding = require('@falkordb/text-to-cypher-win32-arm64-msvc')
101
101
  }
102
102
  } catch (e) {
103
103
  loadError = e
@@ -108,23 +108,23 @@ switch (platform) {
108
108
  }
109
109
  break
110
110
  case 'darwin':
111
- localFileExisted = existsSync(join(__dirname, 'text-to-cypher-node.darwin-universal.node'))
111
+ localFileExisted = existsSync(join(__dirname, 'text-to-cypher.darwin-universal.node'))
112
112
  try {
113
113
  if (localFileExisted) {
114
- nativeBinding = require('./text-to-cypher-node.darwin-universal.node')
114
+ nativeBinding = require('./text-to-cypher.darwin-universal.node')
115
115
  } else {
116
- nativeBinding = require('@falkordb/text-to-cypher-node-darwin-universal')
116
+ nativeBinding = require('@falkordb/text-to-cypher-darwin-universal')
117
117
  }
118
118
  break
119
119
  } catch {}
120
120
  switch (arch) {
121
121
  case 'x64':
122
- localFileExisted = existsSync(join(__dirname, 'text-to-cypher-node.darwin-x64.node'))
122
+ localFileExisted = existsSync(join(__dirname, 'text-to-cypher.darwin-x64.node'))
123
123
  try {
124
124
  if (localFileExisted) {
125
- nativeBinding = require('./text-to-cypher-node.darwin-x64.node')
125
+ nativeBinding = require('./text-to-cypher.darwin-x64.node')
126
126
  } else {
127
- nativeBinding = require('@falkordb/text-to-cypher-node-darwin-x64')
127
+ nativeBinding = require('@falkordb/text-to-cypher-darwin-x64')
128
128
  }
129
129
  } catch (e) {
130
130
  loadError = e
@@ -132,13 +132,13 @@ switch (platform) {
132
132
  break
133
133
  case 'arm64':
134
134
  localFileExisted = existsSync(
135
- join(__dirname, 'text-to-cypher-node.darwin-arm64.node')
135
+ join(__dirname, 'text-to-cypher.darwin-arm64.node')
136
136
  )
137
137
  try {
138
138
  if (localFileExisted) {
139
- nativeBinding = require('./text-to-cypher-node.darwin-arm64.node')
139
+ nativeBinding = require('./text-to-cypher.darwin-arm64.node')
140
140
  } else {
141
- nativeBinding = require('@falkordb/text-to-cypher-node-darwin-arm64')
141
+ nativeBinding = require('@falkordb/text-to-cypher-darwin-arm64')
142
142
  }
143
143
  } catch (e) {
144
144
  loadError = e
@@ -152,12 +152,12 @@ switch (platform) {
152
152
  if (arch !== 'x64') {
153
153
  throw new Error(`Unsupported architecture on FreeBSD: ${arch}`)
154
154
  }
155
- localFileExisted = existsSync(join(__dirname, 'text-to-cypher-node.freebsd-x64.node'))
155
+ localFileExisted = existsSync(join(__dirname, 'text-to-cypher.freebsd-x64.node'))
156
156
  try {
157
157
  if (localFileExisted) {
158
- nativeBinding = require('./text-to-cypher-node.freebsd-x64.node')
158
+ nativeBinding = require('./text-to-cypher.freebsd-x64.node')
159
159
  } else {
160
- nativeBinding = require('@falkordb/text-to-cypher-node-freebsd-x64')
160
+ nativeBinding = require('@falkordb/text-to-cypher-freebsd-x64')
161
161
  }
162
162
  } catch (e) {
163
163
  loadError = e
@@ -168,26 +168,26 @@ switch (platform) {
168
168
  case 'x64':
169
169
  if (isMusl()) {
170
170
  localFileExisted = existsSync(
171
- join(__dirname, 'text-to-cypher-node.linux-x64-musl.node')
171
+ join(__dirname, 'text-to-cypher.linux-x64-musl.node')
172
172
  )
173
173
  try {
174
174
  if (localFileExisted) {
175
- nativeBinding = require('./text-to-cypher-node.linux-x64-musl.node')
175
+ nativeBinding = require('./text-to-cypher.linux-x64-musl.node')
176
176
  } else {
177
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-x64-musl')
177
+ nativeBinding = require('@falkordb/text-to-cypher-linux-x64-musl')
178
178
  }
179
179
  } catch (e) {
180
180
  loadError = e
181
181
  }
182
182
  } else {
183
183
  localFileExisted = existsSync(
184
- join(__dirname, 'text-to-cypher-node.linux-x64-gnu.node')
184
+ join(__dirname, 'text-to-cypher.linux-x64-gnu.node')
185
185
  )
186
186
  try {
187
187
  if (localFileExisted) {
188
- nativeBinding = require('./text-to-cypher-node.linux-x64-gnu.node')
188
+ nativeBinding = require('./text-to-cypher.linux-x64-gnu.node')
189
189
  } else {
190
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-x64-gnu')
190
+ nativeBinding = require('@falkordb/text-to-cypher-linux-x64-gnu')
191
191
  }
192
192
  } catch (e) {
193
193
  loadError = e
@@ -197,26 +197,26 @@ switch (platform) {
197
197
  case 'arm64':
198
198
  if (isMusl()) {
199
199
  localFileExisted = existsSync(
200
- join(__dirname, 'text-to-cypher-node.linux-arm64-musl.node')
200
+ join(__dirname, 'text-to-cypher.linux-arm64-musl.node')
201
201
  )
202
202
  try {
203
203
  if (localFileExisted) {
204
- nativeBinding = require('./text-to-cypher-node.linux-arm64-musl.node')
204
+ nativeBinding = require('./text-to-cypher.linux-arm64-musl.node')
205
205
  } else {
206
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-arm64-musl')
206
+ nativeBinding = require('@falkordb/text-to-cypher-linux-arm64-musl')
207
207
  }
208
208
  } catch (e) {
209
209
  loadError = e
210
210
  }
211
211
  } else {
212
212
  localFileExisted = existsSync(
213
- join(__dirname, 'text-to-cypher-node.linux-arm64-gnu.node')
213
+ join(__dirname, 'text-to-cypher.linux-arm64-gnu.node')
214
214
  )
215
215
  try {
216
216
  if (localFileExisted) {
217
- nativeBinding = require('./text-to-cypher-node.linux-arm64-gnu.node')
217
+ nativeBinding = require('./text-to-cypher.linux-arm64-gnu.node')
218
218
  } else {
219
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-arm64-gnu')
219
+ nativeBinding = require('@falkordb/text-to-cypher-linux-arm64-gnu')
220
220
  }
221
221
  } catch (e) {
222
222
  loadError = e
@@ -226,26 +226,26 @@ switch (platform) {
226
226
  case 'arm':
227
227
  if (isMusl()) {
228
228
  localFileExisted = existsSync(
229
- join(__dirname, 'text-to-cypher-node.linux-arm-musleabihf.node')
229
+ join(__dirname, 'text-to-cypher.linux-arm-musleabihf.node')
230
230
  )
231
231
  try {
232
232
  if (localFileExisted) {
233
- nativeBinding = require('./text-to-cypher-node.linux-arm-musleabihf.node')
233
+ nativeBinding = require('./text-to-cypher.linux-arm-musleabihf.node')
234
234
  } else {
235
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-arm-musleabihf')
235
+ nativeBinding = require('@falkordb/text-to-cypher-linux-arm-musleabihf')
236
236
  }
237
237
  } catch (e) {
238
238
  loadError = e
239
239
  }
240
240
  } else {
241
241
  localFileExisted = existsSync(
242
- join(__dirname, 'text-to-cypher-node.linux-arm-gnueabihf.node')
242
+ join(__dirname, 'text-to-cypher.linux-arm-gnueabihf.node')
243
243
  )
244
244
  try {
245
245
  if (localFileExisted) {
246
- nativeBinding = require('./text-to-cypher-node.linux-arm-gnueabihf.node')
246
+ nativeBinding = require('./text-to-cypher.linux-arm-gnueabihf.node')
247
247
  } else {
248
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-arm-gnueabihf')
248
+ nativeBinding = require('@falkordb/text-to-cypher-linux-arm-gnueabihf')
249
249
  }
250
250
  } catch (e) {
251
251
  loadError = e
@@ -255,26 +255,26 @@ switch (platform) {
255
255
  case 'riscv64':
256
256
  if (isMusl()) {
257
257
  localFileExisted = existsSync(
258
- join(__dirname, 'text-to-cypher-node.linux-riscv64-musl.node')
258
+ join(__dirname, 'text-to-cypher.linux-riscv64-musl.node')
259
259
  )
260
260
  try {
261
261
  if (localFileExisted) {
262
- nativeBinding = require('./text-to-cypher-node.linux-riscv64-musl.node')
262
+ nativeBinding = require('./text-to-cypher.linux-riscv64-musl.node')
263
263
  } else {
264
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-riscv64-musl')
264
+ nativeBinding = require('@falkordb/text-to-cypher-linux-riscv64-musl')
265
265
  }
266
266
  } catch (e) {
267
267
  loadError = e
268
268
  }
269
269
  } else {
270
270
  localFileExisted = existsSync(
271
- join(__dirname, 'text-to-cypher-node.linux-riscv64-gnu.node')
271
+ join(__dirname, 'text-to-cypher.linux-riscv64-gnu.node')
272
272
  )
273
273
  try {
274
274
  if (localFileExisted) {
275
- nativeBinding = require('./text-to-cypher-node.linux-riscv64-gnu.node')
275
+ nativeBinding = require('./text-to-cypher.linux-riscv64-gnu.node')
276
276
  } else {
277
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-riscv64-gnu')
277
+ nativeBinding = require('@falkordb/text-to-cypher-linux-riscv64-gnu')
278
278
  }
279
279
  } catch (e) {
280
280
  loadError = e
@@ -283,13 +283,13 @@ switch (platform) {
283
283
  break
284
284
  case 's390x':
285
285
  localFileExisted = existsSync(
286
- join(__dirname, 'text-to-cypher-node.linux-s390x-gnu.node')
286
+ join(__dirname, 'text-to-cypher.linux-s390x-gnu.node')
287
287
  )
288
288
  try {
289
289
  if (localFileExisted) {
290
- nativeBinding = require('./text-to-cypher-node.linux-s390x-gnu.node')
290
+ nativeBinding = require('./text-to-cypher.linux-s390x-gnu.node')
291
291
  } else {
292
- nativeBinding = require('@falkordb/text-to-cypher-node-linux-s390x-gnu')
292
+ nativeBinding = require('@falkordb/text-to-cypher-linux-s390x-gnu')
293
293
  }
294
294
  } catch (e) {
295
295
  loadError = e
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@falkordb/text-to-cypher",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Node.js bindings for FalkorDB text-to-cypher library - Convert natural language to Cypher queries",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -25,7 +25,7 @@
25
25
  },
26
26
  "homepage": "https://github.com/FalkorDB/text-to-cypher-node#readme",
27
27
  "napi": {
28
- "name": "text-to-cypher-node",
28
+ "name": "text-to-cypher",
29
29
  "triples": {
30
30
  "defaults": true,
31
31
  "additional": [
@@ -73,15 +73,12 @@
73
73
  ],
74
74
  "packageManager": "npm@9.6.7",
75
75
  "optionalDependencies": {
76
- "@falkordb/text-to-cypher-win32-x64-msvc": "0.1.0",
77
- "@falkordb/text-to-cypher-darwin-x64": "0.1.0",
78
- "@falkordb/text-to-cypher-linux-x64-gnu": "0.1.0",
79
- "@falkordb/text-to-cypher-linux-x64-musl": "0.1.0",
80
- "@falkordb/text-to-cypher-linux-arm64-gnu": "0.1.0",
81
- "@falkordb/text-to-cypher-linux-arm64-musl": "0.1.0",
82
- "@falkordb/text-to-cypher-darwin-arm64": "0.1.0"
83
- },
84
- "publishConfig": {
85
- "access": "public"
76
+ "@falkordb/text-to-cypher-win32-x64-msvc": "0.1.1",
77
+ "@falkordb/text-to-cypher-darwin-x64": "0.1.1",
78
+ "@falkordb/text-to-cypher-linux-x64-gnu": "0.1.1",
79
+ "@falkordb/text-to-cypher-linux-x64-musl": "0.1.1",
80
+ "@falkordb/text-to-cypher-linux-arm64-gnu": "0.1.1",
81
+ "@falkordb/text-to-cypher-linux-arm64-musl": "0.1.1",
82
+ "@falkordb/text-to-cypher-darwin-arm64": "0.1.1"
86
83
  }
87
84
  }