Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .changeset/calm-lists-align.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/drop-orphan-comment-ranges.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/eigenpal-image-border-rendering.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/fresh-tables-flow.md

This file was deleted.

6 changes: 0 additions & 6 deletions .changeset/revision-id-int32-bounds.md

This file was deleted.

11 changes: 0 additions & 11 deletions .changeset/security-agent-preconditions.md

This file was deleted.

16 changes: 0 additions & 16 deletions .changeset/security-compare-agent-dos.md

This file was deleted.

13 changes: 0 additions & 13 deletions .changeset/security-fonts-watermark.md

This file was deleted.

14 changes: 0 additions & 14 deletions .changeset/security-hidden-active-content.md

This file was deleted.

16 changes: 0 additions & 16 deletions .changeset/security-ooxml-css-injection.md

This file was deleted.

13 changes: 0 additions & 13 deletions .changeset/security-parse-layout-dos.md

This file was deleted.

11 changes: 0 additions & 11 deletions .changeset/security-review-action-scoping.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/security-untrusted-input-hardening.md

This file was deleted.

13 changes: 0 additions & 13 deletions .changeset/security-url-sanitization.md

This file was deleted.

40 changes: 0 additions & 40 deletions .changeset/suggestion-layer.md

This file was deleted.

58 changes: 58 additions & 0 deletions packages/agents/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,63 @@
# @stll/folio-agents

## 0.8.0

### Minor Changes

- [#412](https://github.com/stella/folio/pull/412) [`21274be`](https://github.com/stella/folio/commit/21274be83afaadc9d28053c87b5ea84ea619c491) Thanks [@jan-kubica](https://github.com/jan-kubica)! - Add a first-class suggestion layer to tracked changes. AI-proposed edits can be
applied with the new `"suggested"` apply mode: they render with the
tracked-change grammar but a dotted stroke and a dedicated hue, and are always
stripped from serialized DOCX output until accepted. Accepting a suggestion
converts it into a normal tracked change authored by the accepting user (or, for
a whole inserted table, applies it directly since OOXML has no tracked
representation for it); rejecting inverse-applies it.

Suggested mode covers inline text/format operations (`replaceInBlock`,
`replaceRange`, `formatRange`) and block/table structural operations
(`insertAfterBlock`, `insertBeforeBlock`, `replaceBlock`, `deleteBlock`,
`insertSignatureTable`, `insertTableRow`, `deleteTableRow`, `insertTableColumn`,
`deleteTableColumn`). Whole-node inserts are stripped entirely; suggested
deletes serialize as though they never happened; the strip is the single
`fromProseDoc`/`extractBlocks` boundary every serialization path funnels through.
Cell merge/split and comment operations remain `unsupportedMode`.

New core commands (`getSuggestions`, `acceptSuggestion`, `acceptAllSuggestions`,
`rejectSuggestion`, `rejectAllSuggestions`, `findSuggestionRange`) and
editor-ref methods (`getSuggestions`, `acceptSuggestion` returning
`{ accepted, appliedAs }`, `rejectSuggestion`, `scrollToSuggestion`) expose the
layer to hosts; `getSuggestions` reports each suggestion's kinds and `appliedAs`
(`"tracked"` vs `"direct"`). The React and Vue adapters expose the same ref
surface (the Nuxt module re-exports it).

Tracked changes also gain an optional `initials` field, carried through the
model and the ProseMirror marks/node attrs for UI attribution (hover, accept
authoring). It is intentionally NOT serialized onto `w:ins`/`w:del`/`w:*PrChange`
or table row/cell markers — `w:initials` is not part of ECMA-376
`CT_TrackChange`, so output stays schema-strict — but the parser remains tolerant
of it if an external document supplies one.

### Patch Changes

- [#420](https://github.com/stella/folio/pull/420) [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5) Thanks [@jan-kubica](https://github.com/jan-kubica)! - Harden agent operation integrity: `read_document`/`read_section`/`find_text`
now return a per-block text hash and `suggest_changes`/`add_comment` accept a
caller-supplied precondition, so a stale edit prepared against content the model
read earlier is detected instead of being stamped from a fresh apply-time
snapshot. Operation-mode and block-range lookups use own-property checks so
prototype keys (`__proto__`, `constructor`) can no longer crash the API.

- [#420](https://github.com/stella/folio/pull/420) [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5) Thanks [@jan-kubica](https://github.com/jan-kubica)! - Bound version-comparison, agent, and validation paths against crafted-input
resource exhaustion: a single aggregate LCS cell budget is now shared across all
document stories; move detection dequeues in O(1) instead of `Array.shift`;
`diffWordSegments` caps its DP matrix and falls back to a whole-string diff;
`ensureParaIds` and `docx-core`'s `validateDocxPackage` enforce entry-count and
uncompressed-size limits before reading; note-paragraph patching builds a linear
offset index instead of rescanning per id; agent whole-word search uses a bounded
boundary window; `suggest_changes` enforces an aggregate operation-text budget;
and tracked vertical cell split refuses a stored continuation whose `gridSpan`
exceeds one column.
- Updated dependencies [[`75842cf`](https://github.com/stella/folio/commit/75842cf60c290af3f756e7dbea7f95671fbdea4f), [`ce930f4`](https://github.com/stella/folio/commit/ce930f4ee45d2b793ef0d625fb0598ce008cb600), [`4b6e885`](https://github.com/stella/folio/commit/4b6e88531408fc9ecb82ae7c0a71e797864fa996), [`75842cf`](https://github.com/stella/folio/commit/75842cf60c290af3f756e7dbea7f95671fbdea4f), [`64f0737`](https://github.com/stella/folio/commit/64f07378ba3f460b999a8a7bba822ed0a01e37e0), [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5), [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5), [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5), [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5), [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5), [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5), [`3229068`](https://github.com/stella/folio/commit/32290689f2256e2e601f1be6701aceb5d135169f), [`a47ee19`](https://github.com/stella/folio/commit/a47ee197d1c4a5abb47efb053d7c674c71074af5), [`21274be`](https://github.com/stella/folio/commit/21274be83afaadc9d28053c87b5ea84ea619c491)]:
- @stll/folio-core@0.13.0

## 0.7.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/agents/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@stll/folio-agents",
"version": "0.7.0",
"version": "0.8.0",
"description": "Framework-neutral LLM tool layer over folio's ai-edits engine: function-calling tools so an agent can read and mutate .docx documents through @stll/folio-core.",
"keywords": [
"agent",
Expand Down
Loading
Loading