@juspay/neurolink 8.20.1 → 8.21.0

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
@@ -1,3 +1,9 @@
1
+ ## [8.21.0](https://github.com/juspay/neurolink/compare/v8.20.1...v8.21.0) (2025-12-22)
2
+
3
+ ### Features
4
+
5
+ - **(types):** Add office document type definitions and comprehensive tests ([1b34d3d](https://github.com/juspay/neurolink/commit/1b34d3de8114bdc56600cc785e7e52aa1af1ddc7))
6
+
1
7
  ## [8.20.1](https://github.com/juspay/neurolink/compare/v8.20.0...v8.20.1) (2025-12-22)
2
8
 
3
9
  ### Bug Fixes
@@ -4,7 +4,11 @@
4
4
  /**
5
5
  * Supported file types for multimodal input
6
6
  */
7
- export type FileType = "csv" | "image" | "pdf" | "audio" | "text" | "unknown";
7
+ export type FileType = "csv" | "image" | "pdf" | "audio" | "text" | "docx" | "pptx" | "xlsx" | "unknown";
8
+ /**
9
+ * Office document types
10
+ */
11
+ export type OfficeDocumentType = "docx" | "pptx" | "xlsx";
8
12
  /**
9
13
  * File input can be Buffer or string (path/URL/data URI)
10
14
  */
@@ -47,6 +51,16 @@ export type FileProcessingResult = {
47
51
  estimatedPages?: number | null;
48
52
  provider?: string;
49
53
  apiType?: PDFAPIType;
54
+ officeFormat?: OfficeDocumentType;
55
+ pageCount?: number;
56
+ slideCount?: number;
57
+ sheetCount?: number;
58
+ sheetNames?: string[];
59
+ author?: string;
60
+ createdDate?: string;
61
+ modifiedDate?: string;
62
+ hasFormulas?: boolean;
63
+ hasImages?: boolean;
50
64
  };
51
65
  };
52
66
  /**
@@ -152,6 +166,50 @@ export type AudioProcessorOptions = {
152
166
  /** Maximum file size in megabytes */
153
167
  maxSizeMB?: number;
154
168
  };
169
+ /**
170
+ * Office processor options for Word, PowerPoint, and Excel documents
171
+ *
172
+ * @example Word document processing (docx)
173
+ * ```typescript
174
+ * const options: OfficeProcessorOptions = {
175
+ * format: "docx",
176
+ * extractTextOnly: false,
177
+ * includeMetadata: true
178
+ * };
179
+ * ```
180
+ *
181
+ * @example PowerPoint processing (pptx)
182
+ * ```typescript
183
+ * const options: OfficeProcessorOptions = {
184
+ * format: "pptx",
185
+ * includeSlideNotes: true, // pptx-specific
186
+ * includeMetadata: true
187
+ * };
188
+ * ```
189
+ *
190
+ * @example Excel processing (xlsx)
191
+ * ```typescript
192
+ * const options: OfficeProcessorOptions = {
193
+ * format: "xlsx",
194
+ * processAllSheets: true, // xlsx-specific
195
+ * includeMetadata: true
196
+ * };
197
+ * ```
198
+ */
199
+ export type OfficeProcessorOptions = {
200
+ /** Office document format type */
201
+ format?: OfficeDocumentType;
202
+ /** Whether to extract text only (true) or preserve formatting (false). Applies to: docx, pptx, xlsx */
203
+ extractTextOnly?: boolean;
204
+ /** Maximum file size in megabytes. Applies to: docx, pptx, xlsx */
205
+ maxSizeMB?: number;
206
+ /** Whether to include metadata (author, created date, etc.). Applies to: docx, pptx, xlsx */
207
+ includeMetadata?: boolean;
208
+ /** For spreadsheets (xlsx only): whether to process all sheets or just the first */
209
+ processAllSheets?: boolean;
210
+ /** For presentations (pptx only): whether to include slide notes */
211
+ includeSlideNotes?: boolean;
212
+ };
155
213
  /**
156
214
  * File detector options
157
215
  */
@@ -161,6 +219,7 @@ export type FileDetectorOptions = {
161
219
  allowedTypes?: FileType[];
162
220
  audioOptions?: AudioProcessorOptions;
163
221
  csvOptions?: CSVProcessorOptions;
222
+ officeOptions?: OfficeProcessorOptions;
164
223
  confidenceThreshold?: number;
165
224
  provider?: string;
166
225
  };
@@ -4,7 +4,11 @@
4
4
  /**
5
5
  * Supported file types for multimodal input
6
6
  */
7
- export type FileType = "csv" | "image" | "pdf" | "audio" | "text" | "unknown";
7
+ export type FileType = "csv" | "image" | "pdf" | "audio" | "text" | "docx" | "pptx" | "xlsx" | "unknown";
8
+ /**
9
+ * Office document types
10
+ */
11
+ export type OfficeDocumentType = "docx" | "pptx" | "xlsx";
8
12
  /**
9
13
  * File input can be Buffer or string (path/URL/data URI)
10
14
  */
@@ -47,6 +51,16 @@ export type FileProcessingResult = {
47
51
  estimatedPages?: number | null;
48
52
  provider?: string;
49
53
  apiType?: PDFAPIType;
54
+ officeFormat?: OfficeDocumentType;
55
+ pageCount?: number;
56
+ slideCount?: number;
57
+ sheetCount?: number;
58
+ sheetNames?: string[];
59
+ author?: string;
60
+ createdDate?: string;
61
+ modifiedDate?: string;
62
+ hasFormulas?: boolean;
63
+ hasImages?: boolean;
50
64
  };
51
65
  };
52
66
  /**
@@ -152,6 +166,50 @@ export type AudioProcessorOptions = {
152
166
  /** Maximum file size in megabytes */
153
167
  maxSizeMB?: number;
154
168
  };
169
+ /**
170
+ * Office processor options for Word, PowerPoint, and Excel documents
171
+ *
172
+ * @example Word document processing (docx)
173
+ * ```typescript
174
+ * const options: OfficeProcessorOptions = {
175
+ * format: "docx",
176
+ * extractTextOnly: false,
177
+ * includeMetadata: true
178
+ * };
179
+ * ```
180
+ *
181
+ * @example PowerPoint processing (pptx)
182
+ * ```typescript
183
+ * const options: OfficeProcessorOptions = {
184
+ * format: "pptx",
185
+ * includeSlideNotes: true, // pptx-specific
186
+ * includeMetadata: true
187
+ * };
188
+ * ```
189
+ *
190
+ * @example Excel processing (xlsx)
191
+ * ```typescript
192
+ * const options: OfficeProcessorOptions = {
193
+ * format: "xlsx",
194
+ * processAllSheets: true, // xlsx-specific
195
+ * includeMetadata: true
196
+ * };
197
+ * ```
198
+ */
199
+ export type OfficeProcessorOptions = {
200
+ /** Office document format type */
201
+ format?: OfficeDocumentType;
202
+ /** Whether to extract text only (true) or preserve formatting (false). Applies to: docx, pptx, xlsx */
203
+ extractTextOnly?: boolean;
204
+ /** Maximum file size in megabytes. Applies to: docx, pptx, xlsx */
205
+ maxSizeMB?: number;
206
+ /** Whether to include metadata (author, created date, etc.). Applies to: docx, pptx, xlsx */
207
+ includeMetadata?: boolean;
208
+ /** For spreadsheets (xlsx only): whether to process all sheets or just the first */
209
+ processAllSheets?: boolean;
210
+ /** For presentations (pptx only): whether to include slide notes */
211
+ includeSlideNotes?: boolean;
212
+ };
155
213
  /**
156
214
  * File detector options
157
215
  */
@@ -161,6 +219,7 @@ export type FileDetectorOptions = {
161
219
  allowedTypes?: FileType[];
162
220
  audioOptions?: AudioProcessorOptions;
163
221
  csvOptions?: CSVProcessorOptions;
222
+ officeOptions?: OfficeProcessorOptions;
164
223
  confidenceThreshold?: number;
165
224
  provider?: string;
166
225
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@juspay/neurolink",
3
- "version": "8.20.1",
3
+ "version": "8.21.0",
4
4
  "description": "Universal AI Development Platform with working MCP integration, multi-provider support, and professional CLI. Built-in tools operational, 58+ external MCP servers discoverable. Connect to filesystem, GitHub, database operations, and more. Build, test, and deploy AI applications with 9 major providers: OpenAI, Anthropic, Google AI, AWS Bedrock, Azure, Hugging Face, Ollama, and Mistral AI.",
5
5
  "author": {
6
6
  "name": "Juspay Technologies",