@praxisui/ai 10.0.0-rc.7 → 10.0.0-rc.71
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/README.md +34 -2
- package/ai/component-registry.json +2 -2
- package/fesm2022/praxisui-ai.mjs +10151 -2274
- package/package.json +2 -2
- package/types/praxisui-ai.d.ts +1371 -54
package/README.md
CHANGED
|
@@ -34,7 +34,7 @@ Peer dependencies:
|
|
|
34
34
|
- `@angular/forms` `^21.0.0`
|
|
35
35
|
- `@angular/material` `^21.0.0`
|
|
36
36
|
- `@google/generative-ai` `^0.24.1`
|
|
37
|
-
- `@praxisui/core` `^
|
|
37
|
+
- `@praxisui/core` `^10.0.0-rc.48`
|
|
38
38
|
- `rxjs` `~7.8.0`
|
|
39
39
|
|
|
40
40
|
## When to use
|
|
@@ -144,7 +144,7 @@ The shell ships with centralized PT-BR default labels and accepts the `labels` i
|
|
|
144
144
|
|
|
145
145
|
By default, the prompt composer submits with `Enter` and keeps `Shift+Enter` for multiline prompts. Hosts with custom composer behavior can set `submitOnEnter` to `false`.
|
|
146
146
|
|
|
147
|
-
The prompt composer supports governed provider-backed transcription with `voiceInputMode="governed-transcription"`. It captures a short audio blob with `MediaRecorder`, sends it to `POST /api/praxis/config/ai/transcriptions` using the normal tenant/user/environment scope, appends the returned text to the prompt and never auto-submits the assistant turn. Provider selection, credentials, limits and audit policy remain backend-owned by Praxis Config. The older `browser-speech` mode remains an explicit compatibility option for approved low-risk environments, but it is not the enterprise/default path because `SpeechRecognition` availability varies by browser.
|
|
147
|
+
The prompt composer supports governed provider-backed transcription with `voiceInputMode="governed-transcription"`. It captures a short audio blob with `MediaRecorder`, sends it to `POST /api/praxis/config/ai/transcriptions` using the normal tenant/user/environment scope, appends the returned text to the prompt and never auto-submits the assistant turn. The 44px microphone sits beside Send and stops an active recording; pending states disable it and expose a separate Cancel dictation control. A reserved status row shows progress and recording time without announcing every timer tick. Focus moves between voice controls only when needed, preserving the editable draft's focus. Provider selection, credentials, limits and audit policy remain backend-owned by Praxis Config. The older `browser-speech` mode remains an explicit compatibility option for approved low-risk environments, but it is not the enterprise/default path because `SpeechRecognition` availability varies by browser.
|
|
148
148
|
|
|
149
149
|
When a user pastes an image into the prompt composer, the shell emits `attachmentsPasted` with `PraxisAssistantShellAttachment` items containing the original `File`, image metadata, `source: 'paste'` and a local preview URL.
|
|
150
150
|
|
|
@@ -277,6 +277,21 @@ Notes:
|
|
|
277
277
|
|
|
278
278
|
`AiBackendApiService` exposes these endpoints through typed methods so hosts can inspect the executable manifest, resolve targets, validate a component edit plan and compile a backend-owned patch without routing by local keywords.
|
|
279
279
|
|
|
280
|
+
### Operational agent turn streaming, workspace orchestrator & governed blocks
|
|
281
|
+
- `POST /api/praxis/config/ai/agent/turn/stream/start`
|
|
282
|
+
- `GET /api/praxis/config/ai/agent/turn/stream/{streamId}`
|
|
283
|
+
- `GET /api/praxis/config/ai/agent/turn/stream/{streamId}/probe`
|
|
284
|
+
- `POST /api/praxis/config/ai/agent/turn/stream/{streamId}/cancel`
|
|
285
|
+
- `POST /api/praxis/config/ai/agent/proposals/{proposalId}/confirm`
|
|
286
|
+
- `POST /api/praxis/config/ai/agent/proposals/{proposalId}/reject`
|
|
287
|
+
- `POST /api/praxis/config/ai/agent/proposals/{proposalId}/complete-form`
|
|
288
|
+
|
|
289
|
+
`OperationalAgentTurnClientService` starts and cancels turns (forwarding `streamAccessToken`) via `HttpClient` (`withCredentials: true`, preserving CSRF headers), probes `EventSource` readiness before opening (failing fast on `401`/`403`/`404`/`410`), and consumes SSE frames over `fetch()` `ReadableStream` with `Last-Event-ID` resume and bounded reconnects (`5` attempts / `125s` timeout). `PraxisAiAssistantShellComponent` renders governed `assistantContent` (`praxis.assistant-content/v2`) operational blocks through `PraxisAssistantOperationalBlockComponent` (`alert-list`, `widget-block` via `DynamicWidgetLoaderDirective` with fail-closed `hostCapabilities`, `simulation-preview`, `action-proposals`, `calculation-memory`, `knowledge-citations`, 5-row `compact-collection`, and `action-bar`) and emits `blockAction` events.
|
|
290
|
+
|
|
291
|
+
`PraxisWorkspaceAssistantComponent` and `WorkspaceAssistantOrchestratorService` wrap the dock, shell, grounding, runtime observations, and workspace query scope, including the full proposal lifecycle (`confirmActionProposal` with `If-Match`/`Idempotency-Key` handling `200`/`403`/`409`/`412`/`422`, `rejectActionProposal`, `revalidate-stale-proposal` preserving `prefill`, `open-proposal-form` with `overlayInitialValueOnEdit` hints, and `completeProposalViaForm`). Governed bulk proposals in `action-proposals` disable direct single-click confirmation (`409 BULK_REQUIRES_MODAL_REVIEW`) and hand off through `PRAXIS_BULK_PROPOSAL_BRIDGE` (`providePraxisCrudBulkProposalBridge()` from `@praxisui/crud`) to the 680px modal before reconciling execution metrics back to `/complete-form`. Surfaces such as CRUD headers, quick views, and analytical drawers trigger pre-grounded assistant conversations via `PRAXIS_OPERATIONAL_ASSISTANT_LAUNCHER` (bound to `providePraxisWorkspaceAssistantLauncher()`).
|
|
292
|
+
|
|
293
|
+
`AssistantHistoryService` is exported in the public API and preserves both conversational paragraphs and all 8 `assistantContent` operational block types in scoped local storage while redacting tokens/JWTs/Mod-11 personal tax identifiers and normalizing expired `PENDING`/`EXECUTING` proposals to `EXPIRED` (`confirmBusy: false`) on restore.
|
|
294
|
+
|
|
280
295
|
### Agentic authoring turn streaming
|
|
281
296
|
- `POST /api/praxis/config/ai/authoring/turn/stream/start`
|
|
282
297
|
- `GET /api/praxis/config/ai/authoring/turn/stream/{streamId}`
|
|
@@ -327,6 +342,23 @@ The manual patch editor UI is disabled by default and can be enabled explicitly
|
|
|
327
342
|
|
|
328
343
|
- `projects/praxis-ai/docs/ai-deployment-flow.md`
|
|
329
344
|
|
|
345
|
+
### Shared assistant voice policy
|
|
346
|
+
|
|
347
|
+
Configure `{ provide: PRAXIS_ASSISTANT_VOICE_INPUT_MODE, useValue: 'governed-transcription' }` once in the host application (token from `@praxisui/ai`). The shell, Page Builder and Table inherit it; explicit component inputs can override it, including `disabled`. The default remains disabled when the host does not opt in.
|
|
348
|
+
|
|
349
|
+
The shared composer checks `GET /api/praxis/config/ai/transcriptions/capabilities` before requesting microphone permission. Readiness means local provider/credential configuration, not quota or network health. Recording, transcription and cancellation preserve the editable draft and never auto-submit. Deploy the backend capability before enabling the updated client.
|
|
350
|
+
|
|
351
|
+
Voice language also inherits `PRAXIS_ASSISTANT_VOICE_LANGUAGE`; explicit component inputs override it. Governed capture is bound to confirmed enterprise context (user/tenant/profile/version) and is cancelled when that authority is invalidated. Page Builder session resets and Table owner changes discard the old shell capture; editing the current draft does not cancel it. The host must keep its session and runtime authority coherent and invalidate it on session-generation changes.
|
|
352
|
+
|
|
353
|
+
Corporate adoption requires a ready context and current context-version headers, a host resolver bound to the server session/membership, and the correct cookie transport. The quickstart enterprise resolver applies this admission to all its AI callers. Local header-only integration cannot detect cookie changes that the host does not report. Focused/mock tests are not proof of durable session persistence, provider connectivity or published package adoption.
|
|
354
|
+
|
|
355
|
+
### CSS Custom Properties (Assistant Icon & Context Chips)
|
|
356
|
+
|
|
357
|
+
- **Header Identity Badge:** `--praxis-ai-identity-size`, `--praxis-ai-identity-radius`, `--praxis-ai-identity-bg`, `--praxis-ai-identity-color`, `--praxis-ai-identity-shadow`, and `--praxis-ai-identity-glyph-size`.
|
|
358
|
+
- **Frameless / Scoped Surface Icons:** Shared frame appearance (`--praxis-ai-icon-frame-bg`, `--praxis-ai-icon-frame-border`, `--praxis-ai-icon-frame-border-color`, `--praxis-ai-icon-frame-radius`, plus legacy size fallback `--praxis-ai-icon-frame-size`) and surface-specific sizing tokens `--praxis-ai-recommended-icon-frame-size`, `--praxis-ai-recommended-icon-glyph-size`, `--praxis-ai-block-icon-frame-size`, `--praxis-ai-block-icon-glyph-size`, `--praxis-ai-quick-reply-frame-size`, `--praxis-ai-quick-reply-mobile-frame-size`, and `--praxis-ai-quick-reply-icon-size`.
|
|
359
|
+
- **Context Chips:** `--praxis-ai-context-item-max-width`.
|
|
360
|
+
- **Operational Alert Cards (`.praxis-ai-op-alert`):** `--praxis-ai-op-alert-accent-width` (default `3px`), `--praxis-ai-op-alert-accent-opacity` (default `1`), and `--praxis-ai-op-alert-padding` (default `8px 10px 8px 13px`).
|
|
361
|
+
|
|
330
362
|
<!-- praxis-npm-catalog-links:start -->
|
|
331
363
|
## Official documentation and examples
|
|
332
364
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": "1.0.0",
|
|
3
|
-
"generatedAt": "2026-
|
|
3
|
+
"generatedAt": "2026-11-29T01:12:09.027Z",
|
|
4
4
|
"packageName": "@praxisui/ai",
|
|
5
|
-
"packageVersion": "10.0.0-rc.
|
|
5
|
+
"packageVersion": "10.0.0-rc.71",
|
|
6
6
|
"sourceRegistry": "praxis-component-registry-ingestion",
|
|
7
7
|
"sourceRegistryVersion": "1.0.0",
|
|
8
8
|
"componentCount": 0,
|