Files
ai-forms/package.json
T
CatoandClaude Opus 5.5 f5689bbdf6 feat: refine fills gaps, writes requested prose, suggestions, shared AiFormAssistant (0.1.3) (#46)
* fix(assist): refine fills empty fields, writes requested prose, localisable copy

A form stops being empty at the first typed word, and from then on every
instruction was a refine that returned only named fields - so pasting an
advert after typing a title filled nothing, and 'fill in the description'
was refused as invention. Refine now also lands in empty fields the message
supplies; facts vs prose are separated (never invent a fact, do write a
requested free-text field). User-facing copy is overridable per app and per
form (AOZ showed English errors in a German form), and the hook clears the
previous turn's 'changed' so it cannot sit beside this turn's error.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* feat: suggestions for filled forms, and one shared AiFormAssistant control

A filled form can now be asked what it would improve: intent 'suggest' on
the same route returns up to 4 one-tap proposals, each applied as an
ordinary refine (undo covers it). Never proposes inventing a fact.

AiFormAssistant moves the bar every adopter hand-rolled (AOZ and evig had
near-identical copies) into the package: behaviour here, words and design
tokens from the app via labels/classNames, no styling shipped. An
improvement to the experience now lands everywhere on one install.

respond keeps its AssistResult type (loki passes one); suggest gets its
own respondSuggest.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-24 01:31:13 -07:00

82 lines
1.9 KiB
JSON

{
"name": "ai-forms",
"version": "0.1.3",
"description": "Headless AI form filling and conversational refinement. Provider-agnostic core, React hook, and a server route factory.",
"license": "MIT",
"author": "Mao Nakamoto",
"homepage": "https://github.com/bitbaum/ai-forms#readme",
"repository": {
"type": "git",
"url": "git+https://github.com/bitbaum/ai-forms.git"
},
"bugs": {
"url": "https://github.com/bitbaum/ai-forms/issues"
},
"keywords": [
"ai",
"forms",
"form-fill",
"autofill",
"llm",
"react",
"headless",
"natural-language"
],
"type": "module",
"sideEffects": false,
"packageManager": "pnpm@11.25.0",
"engines": {
"node": ">=20"
},
"publishConfig": {
"access": "public",
"provenance": true
},
"files": [
"dist"
],
"exports": {
".": {
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
},
"./react": {
"types": "./dist/react.d.ts",
"default": "./dist/react.js"
},
"./server": {
"types": "./dist/server.d.ts",
"default": "./dist/server.js"
}
},
"scripts": {
"build": "tsc -p tsconfig.json",
"lint": "eslint .",
"typecheck": "tsc -p tsconfig.json --noEmit",
"test": "node --test test/*.test.js",
"verify": "pnpm run format:check && pnpm run lint && pnpm run typecheck && pnpm run build && pnpm test",
"prepare": "pnpm run build",
"format": "prettier --write .",
"format:check": "prettier --check ."
},
"peerDependencies": {
"react": ">=18"
},
"peerDependenciesMeta": {
"react": {
"optional": true
}
},
"devDependencies": {
"@eslint/js": "^10.0.1",
"@types/node": "^26.4.0",
"@types/react": "^19.0.2",
"eslint": "^10.9.1",
"eslint-plugin-react-hooks": "^7.1.1",
"globals": "^17.11.0",
"prettier": "3.9.6",
"typescript": "^6.0.3",
"typescript-eslint": "^8.68.0"
}
}