@databricks/appkit-ui 0.89.0 → 0.91.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.
Files changed (82) hide show
  1. package/CLAUDE.md +8 -0
  2. package/dist/cli/commands/agent/eval.js +18 -2
  3. package/dist/cli/commands/agent/eval.js.map +1 -1
  4. package/dist/cli/commands/doctor/bundle.js +10 -1
  5. package/dist/cli/commands/doctor/bundle.js.map +1 -1
  6. package/dist/cli/commands/doctor/checks-wiring.js +1 -1
  7. package/dist/cli/commands/doctor/checks-wiring.js.map +1 -1
  8. package/dist/cli/commands/doctor/databricks-client.js +8 -3
  9. package/dist/cli/commands/doctor/databricks-client.js.map +1 -1
  10. package/dist/cli/commands/doctor/run.js +1 -1
  11. package/dist/cli/commands/doctor/run.js.map +1 -1
  12. package/dist/cli/commands/registry/add.js +6 -9
  13. package/dist/cli/commands/registry/add.js.map +1 -1
  14. package/dist/cli/commands/registry/client.js +9 -31
  15. package/dist/cli/commands/registry/client.js.map +1 -1
  16. package/dist/cli/commands/registry/constants.js +2 -41
  17. package/dist/cli/commands/registry/constants.js.map +1 -1
  18. package/dist/cli/commands/registry/info.js +1 -3
  19. package/dist/cli/commands/registry/info.js.map +1 -1
  20. package/dist/cli/commands/registry/list.js +5 -13
  21. package/dist/cli/commands/registry/list.js.map +1 -1
  22. package/dist/react/charts/area/index.d.ts.map +1 -1
  23. package/dist/react/charts/area/index.js.map +1 -1
  24. package/dist/react/charts/bar/index.d.ts.map +1 -1
  25. package/dist/react/charts/bar/index.js.map +1 -1
  26. package/dist/react/charts/heatmap/index.d.ts.map +1 -1
  27. package/dist/react/charts/heatmap/index.js.map +1 -1
  28. package/dist/react/charts/line/index.d.ts.map +1 -1
  29. package/dist/react/charts/line/index.js.map +1 -1
  30. package/dist/react/charts/pie/index.d.ts.map +1 -1
  31. package/dist/react/charts/pie/index.js.map +1 -1
  32. package/dist/react/charts/radar/index.d.ts.map +1 -1
  33. package/dist/react/charts/radar/index.js.map +1 -1
  34. package/dist/react/charts/scatter/index.d.ts.map +1 -1
  35. package/dist/react/charts/scatter/index.js.map +1 -1
  36. package/dist/react/ui/button.d.ts +1 -1
  37. package/docs/api/appkit/TypeAlias.IDatabaseConfig.md +12 -0
  38. package/docs/api/appkit-ui/data/AreaChart.md +82 -0
  39. package/docs/api/appkit-ui/data/BarChart.md +77 -0
  40. package/docs/api/appkit-ui/data/DonutChart.md +75 -0
  41. package/docs/api/appkit-ui/data/HeatmapChart.md +94 -0
  42. package/docs/api/appkit-ui/data/LineChart.md +80 -0
  43. package/docs/api/appkit-ui/data/PieChart.md +75 -0
  44. package/docs/api/appkit-ui/data/RadarChart.md +77 -0
  45. package/docs/api/appkit-ui/data/ScatterChart.md +79 -0
  46. package/docs/api/appkit-ui/genie/GenieChatMessageList.md +7 -7
  47. package/docs/api/appkit-ui/ui/Accordion.md +3 -3
  48. package/docs/api/appkit-ui/ui/ButtonGroup.md +5 -5
  49. package/docs/api/appkit-ui/ui/Calendar.md +7 -7
  50. package/docs/api/appkit-ui/ui/Carousel.md +1 -1
  51. package/docs/api/appkit-ui/ui/ContextMenu.md +13 -13
  52. package/docs/api/appkit-ui/ui/Drawer.md +1 -1
  53. package/docs/api/appkit-ui/ui/DropdownMenu.md +15 -15
  54. package/docs/api/appkit-ui/ui/Field.md +3 -3
  55. package/docs/api/appkit-ui/ui/HoverCard.md +4 -4
  56. package/docs/api/appkit-ui/ui/InputOTP.md +2 -2
  57. package/docs/api/appkit-ui/ui/Item.md +5 -5
  58. package/docs/api/appkit-ui/ui/Menubar.md +15 -15
  59. package/docs/api/appkit-ui/ui/NavigationMenu.md +11 -11
  60. package/docs/api/appkit-ui/ui/Popover.md +4 -4
  61. package/docs/api/appkit-ui/ui/RadioGroup.md +12 -12
  62. package/docs/api/appkit-ui/ui/ResizableHandle.md +23 -23
  63. package/docs/api/appkit-ui/ui/ScrollArea.md +11 -11
  64. package/docs/api/appkit-ui/ui/Select.md +10 -10
  65. package/docs/api/appkit-ui/ui/Separator.md +5 -5
  66. package/docs/api/appkit-ui/ui/Sheet.md +1 -1
  67. package/docs/api/appkit-ui/ui/Sidebar.md +15 -15
  68. package/docs/api/appkit-ui/ui/Slider.md +2 -2
  69. package/docs/api/appkit-ui/ui/Tabs.md +9 -9
  70. package/docs/api/appkit-ui/ui/Toaster.md +22 -22
  71. package/docs/api/appkit-ui/ui/ToggleGroup.md +3 -3
  72. package/docs/api/appkit-ui/ui/Tooltip.md +4 -4
  73. package/docs/development/llm-guide.md +1 -0
  74. package/docs/development/local-development.md +2 -0
  75. package/docs/plugins/agents.md +22 -22
  76. package/docs/plugins/caching.md +1 -1
  77. package/docs/plugins/database.md +11 -0
  78. package/docs/plugins/execution-context.md +1 -1
  79. package/docs/plugins/lakebase.md +3 -1
  80. package/llms.txt +8 -0
  81. package/package.json +1 -1
  82. package/sbom.cdx.json +1 -1
@@ -17,4 +17,6 @@ npm run dev
17
17
 
18
18
  This command will start the development server with hot reload for both UI and backend code. Open the displayed URL in your browser to see the app. Modify the code in the `src/` directory to see the changes reflected in the browser.
19
19
 
20
+ Hot reload doesn't type-check. If your `package.json` has a `typecheck` script, the development server runs it in the background at startup and after each TypeScript change, and logs any type errors. Deployment validation runs the same script, so fix these errors before you deploy.
21
+
20
22
  To see the other available commands, read the `README.md` file in the application root directory.
@@ -353,7 +353,7 @@ In markdown, set `auth: on-behalf-of-user` in the frontmatter. A per-agent value
353
353
  An on-behalf-of-user agent fails closed:
354
354
 
355
355
  * No forwarded user token: `401` before any model or tool call, in production and in development. There is no service-principal fallback.
356
- * A `401` from the model mid-run becomes an `IDENTITY_EXPIRED` error event and the stream ends. The run is not retried as the service principal.
356
+ * A `401` (or an invalid-token `403`) from the model mid-run becomes an `IDENTITY_EXPIRED` error event and the stream ends. The run is not retried as the service principal.
357
357
  * A sub-agent never widens: under an on-behalf-of-user parent, a mixed sub-agent also runs as the user.
358
358
 
359
359
  **Exceptions.** MLflow tracing, the thread store, and catalog skills (see [Catalog skills](#catalog-skills-unity-catalog-volume)) are app-owned and stay service principal in every mode. Thread rows are keyed by the user id.
@@ -920,30 +920,30 @@ appkit agent eval dataset --root apps/dev-playground --url http://localhost:3000
920
920
 
921
921
  `appkit agent eval [filter]` — run agent evals (`server/agents/<id>/evals/*.eval.ts`) against a running app.
922
922
 
923
- | Flag | Description |
924
- | ---------------------------- | --------------------------------------------------------------------------------------------------------------- |
925
- | `[filter]` | Only run evals whose `<agent>/<id>` contains this substring (or an exact agent id) |
926
- | `--url <url>` | Base URL of the running app (default `http://localhost:3000`) |
927
- | `--strict` | Fail on soft-assertion misses too |
928
- | `--root <dir>` | Project root containing `server/agents/` (default: cwd) |
929
- | `--header <header...>` | Extra request header as `'Key: value'` (repeatable) |
930
- | `--tag <tag...>` | Only run evals tagged with one of these tags (repeatable) |
931
- | `--profile <name>` | Databricks CLI profile to authenticate with via OAuth (default: `DATABRICKS_CONFIG_PROFILE`) |
932
- | `--databricks-host <host>` | Databricks host for writing MLflow assessments (default: `DATABRICKS_HOST`) |
933
- | `--databricks-token <token>` | Databricks token for writing MLflow assessments (default: `DATABRICKS_TOKEN`) |
934
- | `--experiment <id>` | MLflow experiment id for the evaluation run (default: `MLFLOW_EXPERIMENT_ID`) |
935
- | `--warehouse-id <id>` | SQL warehouse id for reading managed evaluation datasets (default: `DATABRICKS_WAREHOUSE_ID`) |
936
- | `--judge-model <endpoint>` | Databricks serving endpoint to use as the LLM judge for `t.judge.*` (default: `APPKIT_JUDGE_MODEL`) |
937
- | `--concurrency <n>` | Max evals/dataset rows to drive concurrently (default: 4) |
938
- | `--timeout <ms>` | Default per-eval timeout in ms (a per-eval `timeoutMs` overrides it) |
939
- | `--retries <n>` | Re-run an eval up to N times when it fails on an infra error (turn/timeout); assertion failures are not retried |
940
- | `--min-pass-rate <rate>` | Gate on aggregate pass rate (0..1) instead of requiring every eval to pass; exit 1 when below |
941
- | `--reporter <format>` | Report format: `text` (live console), `json` (dashboards), or `junit` (CI test reporters) |
942
- | `--output <file>` | Write the json/junit report to this file instead of stdout (ignored for text) |
923
+ | Flag | Description |
924
+ | ---------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
925
+ | `[filter]` | Only run evals whose `<agent>/<id>` contains this substring (or an exact agent id) |
926
+ | `--url <url>` | Base URL of the running app (default `http://localhost:3000`) |
927
+ | `--strict` | Fail on soft-assertion misses too |
928
+ | `--root <dir>` | Project root containing `server/agents/` (default: cwd) |
929
+ | `--header <header...>` | Extra request header as `'Key: value'` (repeatable) |
930
+ | `--tag <tag...>` | Only run evals tagged with one of these tags (repeatable) |
931
+ | `--profile <name>` | Databricks CLI profile to authenticate with via OAuth; the token is also sent to a deployed `*.databricksapps.com` `--url` (default: `DATABRICKS_CONFIG_PROFILE`) |
932
+ | `--databricks-host <host>` | Databricks host for writing MLflow assessments (default: `DATABRICKS_HOST`) |
933
+ | `--databricks-token <token>` | Databricks token for writing MLflow assessments (default: `DATABRICKS_TOKEN`) |
934
+ | `--experiment <id>` | MLflow experiment id for the evaluation run (default: `MLFLOW_EXPERIMENT_ID`) |
935
+ | `--warehouse-id <id>` | SQL warehouse id for reading managed evaluation datasets (default: `DATABRICKS_WAREHOUSE_ID`) |
936
+ | `--judge-model <endpoint>` | Databricks serving endpoint to use as the LLM judge for `t.judge.*` (default: `APPKIT_JUDGE_MODEL`) |
937
+ | `--concurrency <n>` | Max evals/dataset rows to drive concurrently (default: 4) |
938
+ | `--timeout <ms>` | Default per-eval timeout in ms (a per-eval `timeoutMs` overrides it) |
939
+ | `--retries <n>` | Re-run an eval up to N times when it fails on an infra error (turn/timeout); assertion failures are not retried |
940
+ | `--min-pass-rate <rate>` | Gate on aggregate pass rate (0..1) instead of requiring every eval to pass; exit 1 when below |
941
+ | `--reporter <format>` | Report format: `text` (live console), `json` (dashboards), or `junit` (CI test reporters) |
942
+ | `--output <file>` | Write the json/junit report to this file instead of stdout (ignored for text) |
943
943
 
944
944
  Notes:
945
945
 
946
- * **Auth is OAuth-first.** `--profile <name>` mints an OAuth token from your Databricks CLI profile — no PAT needed. An explicit `--databricks-host`/`--databricks-token` (or the `DATABRICKS_*` env vars) wins over the profile.
946
+ * **Auth is OAuth-first.** `--profile <name>` mints an OAuth token from your Databricks CLI profile — no PAT needed. An explicit `--databricks-host`/`--databricks-token` (or the `DATABRICKS_*` env vars) wins over the profile. When `--url` is a deployed app (`https://*.databricksapps.com`), that token is sent as its `Authorization` bearer unless you pass your own with `--header`. Databricks Apps accept only OAuth tokens, so a PAT (`--databricks-token`, `DATABRICKS_TOKEN`) is rejected there with a 401.
947
947
  * **`--retries` only absorbs infra flakiness.** A retry fires only when an eval throws or times out (`result.error` set); a wrong reply is real signal and is never retried. Each attempt gets a fresh driver.
948
948
  * **Gating.** By default the run exits non-zero if any eval fails. `--min-pass-rate 0.9` switches to threshold mode: it exits non-zero only when the aggregate pass rate drops below the threshold. `--strict` additionally treats soft-assertion misses as failures.
949
949
  * **CI reports.** `--reporter junit --output results.xml` writes a JUnit file for CI test reporters; `--reporter json` emits machine-readable results. In machine reporters, human-facing lines go to stderr so stdout stays clean for the report.
@@ -16,7 +16,7 @@ await createApp({
16
16
 
17
17
  ```
18
18
 
19
- Storage auto-selects **Lakebase Autoscaling persistent cache when healthy**, otherwise falls back to in-memory.
19
+ Storage auto-selects **Lakebase Autoscaling persistent cache when healthy**, otherwise falls back to in-memory. When Lakebase is configured but unusable, AppKit logs a warning with the cause.
20
20
 
21
21
  The database-backed cache requires the same Lakebase environment variables as the [Lakebase plugin](./docs/plugins/lakebase.md#environment-variables) (`PGHOST`, `PGDATABASE`, `LAKEBASE_ENDPOINT`, `PGSSLMODE`).
22
22
 
@@ -77,6 +77,17 @@ An explicit schema always takes precedence and skips file discovery. An invalid
77
77
 
78
78
  Run `appkit generate-types` to generate the database registry. With that registry, configuration without an explicit schema still infers table names and hook payloads. An explicitly supplied schema also checks configuration keys against its own table names.
79
79
 
80
+ ## Connection pool[​](#connection-pool "Direct link to Connection pool")
81
+
82
+ The plugin keeps one pool of up to 105 connections, the whole direct-connection budget of a 0.5 CU compute, the smallest size. Other pools on the same compute, such as `lakebase()`, every replica of the app, and any other client share that budget, so lower `max` until the sum fits. Larger computes allow more. Check **Max Connections** in the compute's *Edit compute* drawer.
83
+
84
+ ```ts
85
+ database({ pool: { max: 20, connectionTimeoutMillis: 5000 } });
86
+
87
+ ```
88
+
89
+ Only `max`, `idleTimeoutMillis`, and `connectionTimeoutMillis` can be set. When callers queue because every connection is in use, the plugin logs a warning at most once a minute.
90
+
80
91
  ## Restrict the generated API[​](#restrict-the-generated-api "Direct link to Restrict the generated API")
81
92
 
82
93
  Omitting `api`, or setting it to `true` or `{}`, enables full CRUD. Restrictions are optional. There is no separate write opt-in.
@@ -94,7 +94,7 @@ Missing-token messages distinguish OBO-capable resources from generic operations
94
94
 
95
95
  ## Credential expiration and telemetry[​](#credential-expiration-and-telemetry "Direct link to Credential expiration and telemetry")
96
96
 
97
- A structured downstream HTTP 401 inside a caller scope throws `IdentityExpiredError` with code `IDENTITY_EXPIRED`. It includes the existing token fingerprint, not the token or upstream credential-bearing error. Obtain fresh user credentials before retrying. Non-401 failures and SP execution keep their existing behavior. Plugin `execute()` preserves its failed-result envelope and adds the typed error in the optional `error` field; SSE streams expose `IDENTITY_EXPIRED` in the error payload's `errorCode` field.
97
+ A structured downstream HTTP 401 inside a caller scope throws `IdentityExpiredError` with code `IDENTITY_EXPIRED`. So does a 403 that reports an invalid token, which is how Databricks rejects expired or revoked PATs and expired OAuth tokens. It includes the existing token fingerprint, not the token or upstream credential-bearing error. Obtain fresh user credentials before retrying. Other failures, including permission-denied 403s, and SP execution keep their existing behavior. Plugin `execute()` preserves its failed-result envelope and adds the typed error in the optional `error` field; SSE streams expose `IDENTITY_EXPIRED` in the error payload's `errorCode` field.
98
98
 
99
99
  AppKit-managed spans include `appkit.execution.principal` (`app` or `user`) and `appkit.execution.principal_id` (user or SP ID, or `app` before initialization). `appkit.execution.actor_id` is present when an initiating user exists. Tokens are never attached to these attributes.
100
100
 
@@ -107,7 +107,7 @@ await createApp({
107
107
  plugins: [
108
108
  lakebase({
109
109
  pool: {
110
- max: 10, // Max pool connections (default: 10)
110
+ max: 105, // Max pool connections (default: 105)
111
111
  connectionTimeoutMillis: 5000, // Connection timeout ms (default: 10000)
112
112
  idleTimeoutMillis: 30000, // Idle connection timeout ms (default: 30000)
113
113
  },
@@ -117,6 +117,8 @@ await createApp({
117
117
 
118
118
  ```
119
119
 
120
+ The default `max` of 105 is the whole direct-connection budget of a 0.5 CU compute. The SP pool, the legacy per-user OBO pools (3 connections each), a `database()` pool, every replica of the app, and any other client share that budget. Lower `max` until the sum fits the compute. When callers queue because every connection is in use, the plugin logs a warning at most once a minute.
121
+
120
122
  ## On-Behalf-Of (OBO)[​](#on-behalf-of-obo--per-user-connections "Direct link to On-Behalf-Of (OBO)")
121
123
 
122
124
  Lakebase is app-only through the new `appkit.asUser` and `runInCallerContext` APIs. Operations in those scopes fail with a clear error. For a connector call without a manifest alias:
package/llms.txt CHANGED
@@ -326,7 +326,15 @@ npx @databricks/appkit docs <query>
326
326
  ## appkit-ui API reference [collapsed]
327
327
 
328
328
  - [@databricks/appkit-ui](./docs/api/appkit-ui.md): The library provides a set of UI primitives for building Databricks apps in React.
329
+ - [AreaChart](./docs/api/appkit-ui/data/AreaChart.md): Area Chart component for trend visualization with filled areas.
330
+ - [BarChart](./docs/api/appkit-ui/data/BarChart.md): Bar Chart component for categorical comparisons.
329
331
  - [DataTable](./docs/api/appkit-ui/data/DataTable.md): Production-ready data table with automatic data fetching and state management
332
+ - [DonutChart](./docs/api/appkit-ui/data/DonutChart.md): Donut Chart component (Pie chart with inner radius).
333
+ - [HeatmapChart](./docs/api/appkit-ui/data/HeatmapChart.md): Heatmap Chart component for matrix-style data visualization.
334
+ - [LineChart](./docs/api/appkit-ui/data/LineChart.md): Line Chart component for time-series and trend visualization.
335
+ - [PieChart](./docs/api/appkit-ui/data/PieChart.md): Pie Chart component for proportional data visualization.
336
+ - [RadarChart](./docs/api/appkit-ui/data/RadarChart.md): Radar Chart component for multi-dimensional data comparison.
337
+ - [ScatterChart](./docs/api/appkit-ui/data/ScatterChart.md): Scatter Chart component for correlation and distribution visualization.
330
338
  - [DirectoryList](./docs/api/appkit-ui/files/DirectoryList.md): Card-wrapped directory listing with loading, error, and empty states
331
339
  - [FileBreadcrumb](./docs/api/appkit-ui/files/FileBreadcrumb.md): Path-aware breadcrumb navigation built on top of Breadcrumb primitives
332
340
  - [FileEntry](./docs/api/appkit-ui/files/FileEntry.md): Single file or directory row with icon, name, size, and selection state
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@databricks/appkit-ui",
3
3
  "type": "module",
4
- "version": "0.89.0",
4
+ "version": "0.91.0",
5
5
  "license": "Apache-2.0",
6
6
  "sideEffects": [
7
7
  "**/*.css"