@yuktishaalaa/yuktai 5.0.0 → 5.0.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/dist/index.d.mts CHANGED
@@ -136,7 +136,9 @@ interface FilterConfig {
136
136
  }
137
137
  type ViewMode = "table" | "card" | "auto";
138
138
  type GridTheme = "default" | "high-contrast" | "dark" | "color-blind" | "dyslexia";
139
- type GridLocale = "en-IN" | "en-US" | "te-IN" | "hi-IN" | "ta-IN" | "bn-IN" | "mr-IN" | "kn-IN" | "ml-IN" | "gu-IN" | "pa-IN" | "ur-IN";
139
+ type IndicLanguageLocale = "as-IN" | "bn-IN" | "brx-IN" | "doi-IN" | "gu-IN" | "hi-IN" | "kn-IN" | "ks-IN" | "kok-IN" | "mai-IN" | "ml-IN" | "mni-IN" | "mr-IN" | "ne-IN" | "or-IN" | "pa-IN" | "sa-IN" | "sat-IN" | "sd-IN" | "ta-IN" | "te-IN" | "ur-IN";
140
+ type GridLocale = "en-IN" | "en-US" | IndicLanguageLocale;
141
+ type GridInputLanguage = GridLocale;
140
142
  interface AIFeatures {
141
143
  search?: boolean;
142
144
  summary?: boolean;
@@ -171,21 +173,62 @@ interface GridTranslations {
171
173
  ask: string;
172
174
  }
173
175
  interface YuktaiGridRuleContext<T = Record<string, unknown>> {
176
+ /**
177
+ * Original user input.
178
+ */
174
179
  input: string;
180
+ /**
181
+ * Current grid data.
182
+ */
175
183
  data: T[];
184
+ /**
185
+ * Available grid columns.
186
+ */
176
187
  columns: {
177
188
  key: string;
178
189
  label: string;
179
190
  }[];
191
+ /**
192
+ * Execute one of the generic Grid tools.
193
+ *
194
+ * Example:
195
+ *
196
+ * executeTool("count")
197
+ *
198
+ * executeTool("filter", {
199
+ * key: "lines",
200
+ * operator: "greaterThan",
201
+ * value: 6
202
+ * })
203
+ */
204
+ executeTool: (name: string, input?: Record<string, unknown>) => Promise<{
205
+ success: boolean;
206
+ message: string;
207
+ data?: unknown;
208
+ error?: {
209
+ code: string;
210
+ };
211
+ tool?: string;
212
+ }>;
180
213
  }
181
214
  interface YuktaiGridRule<T = Record<string, unknown>> {
182
- /** Application-defined rule name. */
215
+ /**
216
+ * Application-defined rule name.
217
+ */
183
218
  name: string;
184
- /** Phrases that activate this rule. */
219
+ /**
220
+ * User phrases that activate this rule.
221
+ */
185
222
  phrases: string[];
186
- /** Optional description for documentation/debugging. */
223
+ /**
224
+ * Optional description for documentation/debugging.
225
+ */
187
226
  description?: string;
188
- /** Application-specific execution logic. */
227
+ /**
228
+ * Application-specific execution logic.
229
+ *
230
+ * The package does NOT contain application-specific rules.
231
+ */
189
232
  execute: (context: YuktaiGridRuleContext<T>) => Promise<string> | string;
190
233
  }
191
234
  interface YuktaiGridProps<T = Record<string, unknown>> {
@@ -211,18 +254,37 @@ interface YuktaiGridProps<T = Record<string, unknown>> {
211
254
  onRowClick?: (row: T, index: number) => void;
212
255
  onSortChange?: (sort: SortConfig | null) => void;
213
256
  className?: string;
214
- /** Voice input language of the embedded assistant (default: follows `locale`). */
215
- inputLanguage?: "en-US" | "te-IN";
216
- /** Prefix for tool names, e.g. "ratnalabala_poems" → "ratnalabala_poems_search". */
257
+ /**
258
+ * Voice/input language of the embedded assistant.
259
+ *
260
+ * Supports English and the 22 Indian Scheduled Languages.
261
+ */
262
+ inputLanguage?: "en-IN" | "en-US" | IndicLanguageLocale;
263
+ /**
264
+ * Prefix for WebMCP / Agent tool names.
265
+ *
266
+ * Example:
267
+ *
268
+ * "ratnalabala_poems"
269
+ *
270
+ * produces:
271
+ *
272
+ * ratnalabala_poems_search
273
+ * ratnalabala_poems_filter
274
+ * ratnalabala_poems_sort
275
+ */
217
276
  toolName?: string;
218
- /** Agent-facing tool descriptions, e.g. { search: "Search Telugu poems by title or text." } */
277
+ /**
278
+ * Agent-facing tool descriptions.
279
+ */
219
280
  toolDescriptions?: Partial<Record<"search" | "count" | "columns" | "get_row" | "highlight" | "select" | "open" | "filter" | "clear_filters" | "sort" | "clear_sort", string>>;
220
281
  /**
221
- * Expose the grid's tools to AI agents via WebMCP (document.modelContext).
222
- * Uses exactly the same tools as the embedded assistant.
282
+ * Expose Grid tools to AI agents through WebMCP.
223
283
  */
224
284
  webmcp?: boolean;
225
- /** Real WebMCP registration status (state, registered tools, errors). */
285
+ /**
286
+ * Real WebMCP registration status.
287
+ */
226
288
  onWebMCPStatusChange?: (status: {
227
289
  state: "unsupported" | "registering" | "ready" | "partial" | "error";
228
290
  registered: string[];
@@ -231,9 +293,31 @@ interface YuktaiGridProps<T = Record<string, unknown>> {
231
293
  message: string;
232
294
  }[];
233
295
  }) => void;
234
- /** Application-defined content rules executed before generic Grid intent parsing. */
296
+ /**
297
+ * Application-specific Agent rules.
298
+ *
299
+ * Example:
300
+ *
301
+ * customRules={[
302
+ * {
303
+ * name: "show-long-poems",
304
+ * phrases: ["పెద్ద పద్యాలు"],
305
+ * execute: async ({ executeTool }) => {
306
+ * const result = await executeTool("filter", {
307
+ * key: "lines",
308
+ * operator: "greaterThan",
309
+ * value: 6,
310
+ * })
311
+ *
312
+ * return result.message
313
+ * },
314
+ * },
315
+ * ]}
316
+ */
235
317
  customRules?: YuktaiGridRule<T>[];
236
- /** Every result from the Agent (assistant or WebMCP), e.g. for logging. */
318
+ /**
319
+ * Every result from the Agent.
320
+ */
237
321
  onAgentResult?: (result: {
238
322
  success: boolean;
239
323
  message: string;
@@ -395,7 +479,8 @@ interface UseGridReturn<T> {
395
479
  }
396
480
  declare function useGrid<T extends Record<string, unknown>>(options: UseGridOptions<T>): UseGridReturn<T>;
397
481
 
398
- type Language = "en-US" | "te-IN";
482
+ type UILanguage = "en-US" | "te-IN";
483
+ type InputLanguage = GridInputLanguage;
399
484
  interface YuktaiGridAIProps<T> {
400
485
  data: T[];
401
486
  columns: {
@@ -403,10 +488,6 @@ interface YuktaiGridAIProps<T> {
403
488
  label: string;
404
489
  type?: "number" | "text" | "date";
405
490
  }[];
406
- /**
407
- * Used only when no `agent` is given (4.6.x behaviour).
408
- * With an agent, every action goes through agent.ask() instead.
409
- */
410
491
  onSearch?: (query: string) => void;
411
492
  onSort?: (key: string, dir: "asc" | "desc") => void;
412
493
  theme?: "light" | "dark";
@@ -414,22 +495,19 @@ interface YuktaiGridAIProps<T> {
414
495
  * Language of AI UI and AI responses.
415
496
  * Default: English.
416
497
  */
417
- language?: Language;
498
+ language?: UILanguage;
418
499
  /**
419
500
  * Language used by browser voice recognition.
420
501
  * Default: English.
421
502
  */
422
- inputLanguage?: Language;
503
+ inputLanguage?: InputLanguage;
423
504
  /**
424
505
  * When true, AI is rendered inside the grid.
425
506
  * When false, AI uses the floating assistant UI.
426
507
  */
427
508
  embedded?: boolean;
428
509
  /**
429
- * The grid Agent (from useYuktaiGridAgent). When given, search / sort /
430
- * filter / open / clear requests are sent to agent.ask() — the same
431
- * pipeline WebMCP uses — and the Agent's result message is shown.
432
- * Questions like "highest / average / total" are still answered here.
510
+ * The grid Agent.
433
511
  */
434
512
  agent?: {
435
513
  ask: (text: string) => Promise<{
@@ -438,8 +516,10 @@ interface YuktaiGridAIProps<T> {
438
516
  }>;
439
517
  loading?: boolean;
440
518
  };
441
- /** Called when the person switches the voice input language. */
442
- onInputLanguageChange?: (language: Language) => void;
519
+ /**
520
+ * Called when the person switches the voice input language.
521
+ */
522
+ onInputLanguageChange?: (language: InputLanguage) => void;
443
523
  }
444
524
  declare function YuktaiGridAI<T extends Record<string, unknown>>({ data, columns, onSearch, onSort, theme, language, inputLanguage, embedded, agent, onInputLanguageChange, }: YuktaiGridAIProps<T>): react_jsx_runtime.JSX.Element;
445
525
 
@@ -526,7 +606,9 @@ type GridIntent = {
526
606
  tool: string;
527
607
  input: Record<string, unknown>;
528
608
  }
529
- /** "open <something>": search for it, then open the first match */
609
+ /**
610
+ * "open <something>": search for it, then open the first match
611
+ */
530
612
  | {
531
613
  kind: "open";
532
614
  text: string;
@@ -553,7 +635,7 @@ type YuktaiGridAgentProps<T = Record<string, unknown>> = {
553
635
  }[];
554
636
  /** Row ID field — must match the grid's rowKey (default "id"). */
555
637
  rowKey?: string;
556
- /** Replace the built-in regex intent parser (e.g. with an on-device LLM). */
638
+ /** Replace the built-in regex intent parser. */
557
639
  parseIntent?: (text: string, context: GridIntentContext) => GridIntent | null;
558
640
  /** Application-defined content rules executed before the generic intent parser. */
559
641
  customRules?: YuktaiGridRule<T>[];
@@ -562,7 +644,7 @@ type YuktaiGridAgentProps<T = Record<string, unknown>> = {
562
644
  };
563
645
  /** Built-in parser: exported so it can be tested and reused. */
564
646
  declare function parseGridIntent(text: string, context: GridIntentContext): GridIntent | null;
565
- declare function useYuktaiGridAgent<T = Record<string, unknown>>({ tools, data, onResult, onError, locale, columns, rowKey, parseIntent, customRules, historyLimit, }: YuktaiGridAgentProps<T>): {
647
+ declare function useYuktaiGridAgent<T = Record<string, unknown>>({ tools, data, onResult, onError, locale, columns, rowKey, parseIntent: customParseIntent, customRules, historyLimit, }: YuktaiGridAgentProps<T>): {
566
648
  loading: boolean;
567
649
  tools: GridAgentTool[];
568
650
  executeTool: (name: string, input?: Record<string, unknown>) => Promise<GridAgentResult<unknown>>;
@@ -638,4 +720,4 @@ declare const YuktAI: {
638
720
  scan(): A11yReport;
639
721
  };
640
722
 
641
- export { type A11yConfig, type A11yFix, type A11yReport, type AIFeatures, CheckIcon, ChevronLeftIcon, ChevronRightIcon, CloseIcon, type ColorBlindMode, type CreateGridToolsOptions, type FilterConfig, type FilterOperator, type GridAgentErrorCode, type GridAgentResult, type GridAgentStep, type GridAgentTool, type GridColumn, type GridIntent, type GridIntentContext, type GridLocale, type GridTheme, type GridTool, type GridToolColumn, type GridToolContext, type GridToolErrorCode, type GridToolFilter, type GridToolFilterOperator, type GridToolId, type GridToolLocale, type GridToolResult, type GridToolSort, type GridTranslations, IconBase, type IconProps, type PaginationConfig, Runtime, SearchIcon, type Severity, type SortConfig, type SortDirection, SortDownIcon, SortUpIcon, type UseGridOptions, type UseGridReturn, type ViewMode, type VoiceFeatures, type WebMCPState, type WebMCPStatus, YuktAI, YuktAIWrapper, type YuktAIWrapperProps, YuktaiGrid, YuktaiGridAI, type YuktaiGridAIProps, useYuktaiGridAgent as YuktaiGridAgent, type YuktaiGridAgentProps, type YuktaiGridProps, YuktaiGridWebMCP, type YuktaiGridWebMCPProps, aiPlugin, applyGridFilters, clearFilters, clearSort, countGrid, createGridTools, YuktAIWrapper as default, filterGrid, getColumns, getRow, getRowId, highlightRows, openRow, parseGridIntent, searchGrid, selectRow, sortGrid, toGridToolColumns, useGrid, useYuktaiGridAgent, voicePlugin, wcagPlugin as wcag, wcagPlugin };
723
+ export { type A11yConfig, type A11yFix, type A11yReport, type AIFeatures, CheckIcon, ChevronLeftIcon, ChevronRightIcon, CloseIcon, type ColorBlindMode, type CreateGridToolsOptions, type FilterConfig, type FilterOperator, type GridAgentErrorCode, type GridAgentResult, type GridAgentStep, type GridAgentTool, type GridColumn, type GridInputLanguage, type GridIntent, type GridIntentContext, type GridLocale, type GridTheme, type GridTool, type GridToolColumn, type GridToolContext, type GridToolErrorCode, type GridToolFilter, type GridToolFilterOperator, type GridToolId, type GridToolLocale, type GridToolResult, type GridToolSort, type GridTranslations, IconBase, type IconProps, type IndicLanguageLocale, type PaginationConfig, Runtime, SearchIcon, type Severity, type SortConfig, type SortDirection, SortDownIcon, SortUpIcon, type UseGridOptions, type UseGridReturn, type ViewMode, type VoiceFeatures, type WebMCPState, type WebMCPStatus, YuktAI, YuktAIWrapper, type YuktAIWrapperProps, YuktaiGrid, YuktaiGridAI, type YuktaiGridAIProps, useYuktaiGridAgent as YuktaiGridAgent, type YuktaiGridAgentProps, type YuktaiGridProps, type YuktaiGridRule, type YuktaiGridRuleContext, YuktaiGridWebMCP, type YuktaiGridWebMCPProps, aiPlugin, applyGridFilters, clearFilters, clearSort, countGrid, createGridTools, YuktAIWrapper as default, filterGrid, getColumns, getRow, getRowId, highlightRows, openRow, parseGridIntent, searchGrid, selectRow, sortGrid, toGridToolColumns, useGrid, useYuktaiGridAgent, voicePlugin, wcagPlugin as wcag, wcagPlugin };
package/dist/index.d.ts CHANGED
@@ -136,7 +136,9 @@ interface FilterConfig {
136
136
  }
137
137
  type ViewMode = "table" | "card" | "auto";
138
138
  type GridTheme = "default" | "high-contrast" | "dark" | "color-blind" | "dyslexia";
139
- type GridLocale = "en-IN" | "en-US" | "te-IN" | "hi-IN" | "ta-IN" | "bn-IN" | "mr-IN" | "kn-IN" | "ml-IN" | "gu-IN" | "pa-IN" | "ur-IN";
139
+ type IndicLanguageLocale = "as-IN" | "bn-IN" | "brx-IN" | "doi-IN" | "gu-IN" | "hi-IN" | "kn-IN" | "ks-IN" | "kok-IN" | "mai-IN" | "ml-IN" | "mni-IN" | "mr-IN" | "ne-IN" | "or-IN" | "pa-IN" | "sa-IN" | "sat-IN" | "sd-IN" | "ta-IN" | "te-IN" | "ur-IN";
140
+ type GridLocale = "en-IN" | "en-US" | IndicLanguageLocale;
141
+ type GridInputLanguage = GridLocale;
140
142
  interface AIFeatures {
141
143
  search?: boolean;
142
144
  summary?: boolean;
@@ -171,21 +173,62 @@ interface GridTranslations {
171
173
  ask: string;
172
174
  }
173
175
  interface YuktaiGridRuleContext<T = Record<string, unknown>> {
176
+ /**
177
+ * Original user input.
178
+ */
174
179
  input: string;
180
+ /**
181
+ * Current grid data.
182
+ */
175
183
  data: T[];
184
+ /**
185
+ * Available grid columns.
186
+ */
176
187
  columns: {
177
188
  key: string;
178
189
  label: string;
179
190
  }[];
191
+ /**
192
+ * Execute one of the generic Grid tools.
193
+ *
194
+ * Example:
195
+ *
196
+ * executeTool("count")
197
+ *
198
+ * executeTool("filter", {
199
+ * key: "lines",
200
+ * operator: "greaterThan",
201
+ * value: 6
202
+ * })
203
+ */
204
+ executeTool: (name: string, input?: Record<string, unknown>) => Promise<{
205
+ success: boolean;
206
+ message: string;
207
+ data?: unknown;
208
+ error?: {
209
+ code: string;
210
+ };
211
+ tool?: string;
212
+ }>;
180
213
  }
181
214
  interface YuktaiGridRule<T = Record<string, unknown>> {
182
- /** Application-defined rule name. */
215
+ /**
216
+ * Application-defined rule name.
217
+ */
183
218
  name: string;
184
- /** Phrases that activate this rule. */
219
+ /**
220
+ * User phrases that activate this rule.
221
+ */
185
222
  phrases: string[];
186
- /** Optional description for documentation/debugging. */
223
+ /**
224
+ * Optional description for documentation/debugging.
225
+ */
187
226
  description?: string;
188
- /** Application-specific execution logic. */
227
+ /**
228
+ * Application-specific execution logic.
229
+ *
230
+ * The package does NOT contain application-specific rules.
231
+ */
189
232
  execute: (context: YuktaiGridRuleContext<T>) => Promise<string> | string;
190
233
  }
191
234
  interface YuktaiGridProps<T = Record<string, unknown>> {
@@ -211,18 +254,37 @@ interface YuktaiGridProps<T = Record<string, unknown>> {
211
254
  onRowClick?: (row: T, index: number) => void;
212
255
  onSortChange?: (sort: SortConfig | null) => void;
213
256
  className?: string;
214
- /** Voice input language of the embedded assistant (default: follows `locale`). */
215
- inputLanguage?: "en-US" | "te-IN";
216
- /** Prefix for tool names, e.g. "ratnalabala_poems" → "ratnalabala_poems_search". */
257
+ /**
258
+ * Voice/input language of the embedded assistant.
259
+ *
260
+ * Supports English and the 22 Indian Scheduled Languages.
261
+ */
262
+ inputLanguage?: "en-IN" | "en-US" | IndicLanguageLocale;
263
+ /**
264
+ * Prefix for WebMCP / Agent tool names.
265
+ *
266
+ * Example:
267
+ *
268
+ * "ratnalabala_poems"
269
+ *
270
+ * produces:
271
+ *
272
+ * ratnalabala_poems_search
273
+ * ratnalabala_poems_filter
274
+ * ratnalabala_poems_sort
275
+ */
217
276
  toolName?: string;
218
- /** Agent-facing tool descriptions, e.g. { search: "Search Telugu poems by title or text." } */
277
+ /**
278
+ * Agent-facing tool descriptions.
279
+ */
219
280
  toolDescriptions?: Partial<Record<"search" | "count" | "columns" | "get_row" | "highlight" | "select" | "open" | "filter" | "clear_filters" | "sort" | "clear_sort", string>>;
220
281
  /**
221
- * Expose the grid's tools to AI agents via WebMCP (document.modelContext).
222
- * Uses exactly the same tools as the embedded assistant.
282
+ * Expose Grid tools to AI agents through WebMCP.
223
283
  */
224
284
  webmcp?: boolean;
225
- /** Real WebMCP registration status (state, registered tools, errors). */
285
+ /**
286
+ * Real WebMCP registration status.
287
+ */
226
288
  onWebMCPStatusChange?: (status: {
227
289
  state: "unsupported" | "registering" | "ready" | "partial" | "error";
228
290
  registered: string[];
@@ -231,9 +293,31 @@ interface YuktaiGridProps<T = Record<string, unknown>> {
231
293
  message: string;
232
294
  }[];
233
295
  }) => void;
234
- /** Application-defined content rules executed before generic Grid intent parsing. */
296
+ /**
297
+ * Application-specific Agent rules.
298
+ *
299
+ * Example:
300
+ *
301
+ * customRules={[
302
+ * {
303
+ * name: "show-long-poems",
304
+ * phrases: ["పెద్ద పద్యాలు"],
305
+ * execute: async ({ executeTool }) => {
306
+ * const result = await executeTool("filter", {
307
+ * key: "lines",
308
+ * operator: "greaterThan",
309
+ * value: 6,
310
+ * })
311
+ *
312
+ * return result.message
313
+ * },
314
+ * },
315
+ * ]}
316
+ */
235
317
  customRules?: YuktaiGridRule<T>[];
236
- /** Every result from the Agent (assistant or WebMCP), e.g. for logging. */
318
+ /**
319
+ * Every result from the Agent.
320
+ */
237
321
  onAgentResult?: (result: {
238
322
  success: boolean;
239
323
  message: string;
@@ -395,7 +479,8 @@ interface UseGridReturn<T> {
395
479
  }
396
480
  declare function useGrid<T extends Record<string, unknown>>(options: UseGridOptions<T>): UseGridReturn<T>;
397
481
 
398
- type Language = "en-US" | "te-IN";
482
+ type UILanguage = "en-US" | "te-IN";
483
+ type InputLanguage = GridInputLanguage;
399
484
  interface YuktaiGridAIProps<T> {
400
485
  data: T[];
401
486
  columns: {
@@ -403,10 +488,6 @@ interface YuktaiGridAIProps<T> {
403
488
  label: string;
404
489
  type?: "number" | "text" | "date";
405
490
  }[];
406
- /**
407
- * Used only when no `agent` is given (4.6.x behaviour).
408
- * With an agent, every action goes through agent.ask() instead.
409
- */
410
491
  onSearch?: (query: string) => void;
411
492
  onSort?: (key: string, dir: "asc" | "desc") => void;
412
493
  theme?: "light" | "dark";
@@ -414,22 +495,19 @@ interface YuktaiGridAIProps<T> {
414
495
  * Language of AI UI and AI responses.
415
496
  * Default: English.
416
497
  */
417
- language?: Language;
498
+ language?: UILanguage;
418
499
  /**
419
500
  * Language used by browser voice recognition.
420
501
  * Default: English.
421
502
  */
422
- inputLanguage?: Language;
503
+ inputLanguage?: InputLanguage;
423
504
  /**
424
505
  * When true, AI is rendered inside the grid.
425
506
  * When false, AI uses the floating assistant UI.
426
507
  */
427
508
  embedded?: boolean;
428
509
  /**
429
- * The grid Agent (from useYuktaiGridAgent). When given, search / sort /
430
- * filter / open / clear requests are sent to agent.ask() — the same
431
- * pipeline WebMCP uses — and the Agent's result message is shown.
432
- * Questions like "highest / average / total" are still answered here.
510
+ * The grid Agent.
433
511
  */
434
512
  agent?: {
435
513
  ask: (text: string) => Promise<{
@@ -438,8 +516,10 @@ interface YuktaiGridAIProps<T> {
438
516
  }>;
439
517
  loading?: boolean;
440
518
  };
441
- /** Called when the person switches the voice input language. */
442
- onInputLanguageChange?: (language: Language) => void;
519
+ /**
520
+ * Called when the person switches the voice input language.
521
+ */
522
+ onInputLanguageChange?: (language: InputLanguage) => void;
443
523
  }
444
524
  declare function YuktaiGridAI<T extends Record<string, unknown>>({ data, columns, onSearch, onSort, theme, language, inputLanguage, embedded, agent, onInputLanguageChange, }: YuktaiGridAIProps<T>): react_jsx_runtime.JSX.Element;
445
525
 
@@ -526,7 +606,9 @@ type GridIntent = {
526
606
  tool: string;
527
607
  input: Record<string, unknown>;
528
608
  }
529
- /** "open <something>": search for it, then open the first match */
609
+ /**
610
+ * "open <something>": search for it, then open the first match
611
+ */
530
612
  | {
531
613
  kind: "open";
532
614
  text: string;
@@ -553,7 +635,7 @@ type YuktaiGridAgentProps<T = Record<string, unknown>> = {
553
635
  }[];
554
636
  /** Row ID field — must match the grid's rowKey (default "id"). */
555
637
  rowKey?: string;
556
- /** Replace the built-in regex intent parser (e.g. with an on-device LLM). */
638
+ /** Replace the built-in regex intent parser. */
557
639
  parseIntent?: (text: string, context: GridIntentContext) => GridIntent | null;
558
640
  /** Application-defined content rules executed before the generic intent parser. */
559
641
  customRules?: YuktaiGridRule<T>[];
@@ -562,7 +644,7 @@ type YuktaiGridAgentProps<T = Record<string, unknown>> = {
562
644
  };
563
645
  /** Built-in parser: exported so it can be tested and reused. */
564
646
  declare function parseGridIntent(text: string, context: GridIntentContext): GridIntent | null;
565
- declare function useYuktaiGridAgent<T = Record<string, unknown>>({ tools, data, onResult, onError, locale, columns, rowKey, parseIntent, customRules, historyLimit, }: YuktaiGridAgentProps<T>): {
647
+ declare function useYuktaiGridAgent<T = Record<string, unknown>>({ tools, data, onResult, onError, locale, columns, rowKey, parseIntent: customParseIntent, customRules, historyLimit, }: YuktaiGridAgentProps<T>): {
566
648
  loading: boolean;
567
649
  tools: GridAgentTool[];
568
650
  executeTool: (name: string, input?: Record<string, unknown>) => Promise<GridAgentResult<unknown>>;
@@ -638,4 +720,4 @@ declare const YuktAI: {
638
720
  scan(): A11yReport;
639
721
  };
640
722
 
641
- export { type A11yConfig, type A11yFix, type A11yReport, type AIFeatures, CheckIcon, ChevronLeftIcon, ChevronRightIcon, CloseIcon, type ColorBlindMode, type CreateGridToolsOptions, type FilterConfig, type FilterOperator, type GridAgentErrorCode, type GridAgentResult, type GridAgentStep, type GridAgentTool, type GridColumn, type GridIntent, type GridIntentContext, type GridLocale, type GridTheme, type GridTool, type GridToolColumn, type GridToolContext, type GridToolErrorCode, type GridToolFilter, type GridToolFilterOperator, type GridToolId, type GridToolLocale, type GridToolResult, type GridToolSort, type GridTranslations, IconBase, type IconProps, type PaginationConfig, Runtime, SearchIcon, type Severity, type SortConfig, type SortDirection, SortDownIcon, SortUpIcon, type UseGridOptions, type UseGridReturn, type ViewMode, type VoiceFeatures, type WebMCPState, type WebMCPStatus, YuktAI, YuktAIWrapper, type YuktAIWrapperProps, YuktaiGrid, YuktaiGridAI, type YuktaiGridAIProps, useYuktaiGridAgent as YuktaiGridAgent, type YuktaiGridAgentProps, type YuktaiGridProps, YuktaiGridWebMCP, type YuktaiGridWebMCPProps, aiPlugin, applyGridFilters, clearFilters, clearSort, countGrid, createGridTools, YuktAIWrapper as default, filterGrid, getColumns, getRow, getRowId, highlightRows, openRow, parseGridIntent, searchGrid, selectRow, sortGrid, toGridToolColumns, useGrid, useYuktaiGridAgent, voicePlugin, wcagPlugin as wcag, wcagPlugin };
723
+ export { type A11yConfig, type A11yFix, type A11yReport, type AIFeatures, CheckIcon, ChevronLeftIcon, ChevronRightIcon, CloseIcon, type ColorBlindMode, type CreateGridToolsOptions, type FilterConfig, type FilterOperator, type GridAgentErrorCode, type GridAgentResult, type GridAgentStep, type GridAgentTool, type GridColumn, type GridInputLanguage, type GridIntent, type GridIntentContext, type GridLocale, type GridTheme, type GridTool, type GridToolColumn, type GridToolContext, type GridToolErrorCode, type GridToolFilter, type GridToolFilterOperator, type GridToolId, type GridToolLocale, type GridToolResult, type GridToolSort, type GridTranslations, IconBase, type IconProps, type IndicLanguageLocale, type PaginationConfig, Runtime, SearchIcon, type Severity, type SortConfig, type SortDirection, SortDownIcon, SortUpIcon, type UseGridOptions, type UseGridReturn, type ViewMode, type VoiceFeatures, type WebMCPState, type WebMCPStatus, YuktAI, YuktAIWrapper, type YuktAIWrapperProps, YuktaiGrid, YuktaiGridAI, type YuktaiGridAIProps, useYuktaiGridAgent as YuktaiGridAgent, type YuktaiGridAgentProps, type YuktaiGridProps, type YuktaiGridRule, type YuktaiGridRuleContext, YuktaiGridWebMCP, type YuktaiGridWebMCPProps, aiPlugin, applyGridFilters, clearFilters, clearSort, countGrid, createGridTools, YuktAIWrapper as default, filterGrid, getColumns, getRow, getRowId, highlightRows, openRow, parseGridIntent, searchGrid, selectRow, sortGrid, toGridToolColumns, useGrid, useYuktaiGridAgent, voicePlugin, wcagPlugin as wcag, wcagPlugin };