@roomle/embedding-lib 9.0.0-alpha.4 → 9.0.0-alpha.5
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/docs/md/web/embedding/CHANGELOG.md +60 -4
- package/{drag-ghost-BOwjMbG3.mjs → drag-ghost-BxqPJdhq.mjs} +1 -1
- package/{drag-ghost-BQ8r6NVo.mjs → drag-ghost-CDFtC1pd.mjs} +1 -1
- package/{drag-in-BP_E53zb.mjs → drag-in-CV1E-DO6.mjs} +2 -2
- package/{drag-in-QhL3zGC0.mjs → drag-in-ClPpCYyi.mjs} +2 -2
- package/embedding-plugins.js +1 -1
- package/embedding-plugins.min.js +1 -1
- package/{from-custom-view-BM_zRJCf.mjs → from-custom-view-Q9A-J7qV.mjs} +2 -2
- package/{from-custom-view-D2Z1YmCx.mjs → from-custom-view-Sx6P6iDI.mjs} +2 -2
- package/{from-website-DlklVbxU.mjs → from-website-BmCO2xli.mjs} +2 -2
- package/{from-website-CPVeVVMI.mjs → from-website-DZJy_l42.mjs} +2 -2
- package/hi.js +53 -13
- package/hi.min.js +51 -11
- package/package.json +1 -1
- package/packages/embedding-lib/src/hi.d.ts +1 -3
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp-tools.d.ts +65 -8
- package/packages/embedding-lib/src/homag-intelligence/hi-planning-assistant.d.ts +2 -2
- package/roomle-embedding-lib.js +1 -1
- package/roomle-embedding-lib.min.js +1 -1
- package/hi-mcp-server-BiZlFkBm.mjs +0 -4866
- package/hi-mcp-server-DTQnrykg.mjs +0 -5278
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/agent-facing.d.ts +0 -35
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/hi-mcp-server.d.ts +0 -3
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/mcp-tool-types.d.ts +0 -57
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/mcp-tool.d.ts +0 -13
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/plan-history.d.ts +0 -33
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/planner-api.d.ts +0 -32
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/skills.d.ts +0 -23
- package/packages/embedding-lib/src/homag-intelligence/hi-mcp/tool-executors.d.ts +0 -4
|
@@ -1,5 +1,61 @@
|
|
|
1
|
-
## 9.0.0-alpha.
|
|
1
|
+
## 9.0.0-alpha.5 (2026-10-23)
|
|
2
2
|
|
|
3
|
-
* Merge
|
|
4
|
-
* Merge
|
|
5
|
-
*
|
|
3
|
+
* Merge branch 'master' into feat/hi-mcp-improvements ([5810d86](https://github.com/roomle-dev/roomle-ui/commit/5810d86))
|
|
4
|
+
* Merge branch 'master' into feat/hi-mcp-improvements ([68259ea](https://github.com/roomle-dev/roomle-ui/commit/68259ea))
|
|
5
|
+
* Merge branch 'master' into feat/hi-mcp-improvements ([b2aaff7](https://github.com/roomle-dev/roomle-ui/commit/b2aaff7))
|
|
6
|
+
* Merge branch 'master' into feat/hi-mcp-improvements ([3b8d5fd](https://github.com/roomle-dev/roomle-ui/commit/3b8d5fd))
|
|
7
|
+
* Merge branch 'master' into release/test ([1d8227a](https://github.com/roomle-dev/roomle-ui/commit/1d8227a))
|
|
8
|
+
* Merge pull request #3146 from roomle-dev/feat/hi-initial-checks-RML-18217 ([8b8e266](https://github.com/roomle-dev/roomle-ui/commit/8b8e266)), closes [#3146](https://github.com/roomle-dev/roomle-ui/issues/3146)
|
|
9
|
+
* Merge pull request #3164 from roomle-dev/feat/hi-mcp-improvements ([529c69a](https://github.com/roomle-dev/roomle-ui/commit/529c69a)), closes [#3164](https://github.com/roomle-dev/roomle-ui/issues/3164)
|
|
10
|
+
* Merge pull request #3169 from roomle-dev/chore/spike-keep-showroom-view-RML-18283 ([08ad29c](https://github.com/roomle-dev/roomle-ui/commit/08ad29c)), closes [#3169](https://github.com/roomle-dev/roomle-ui/issues/3169)
|
|
11
|
+
* Merge pull request #3170 from roomle-dev/feat/upload-size-crop-camera-RML-18283 ([0d15559](https://github.com/roomle-dev/roomle-ui/commit/0d15559)), closes [#3170](https://github.com/roomle-dev/roomle-ui/issues/3170)
|
|
12
|
+
* Merge pull request #3177 from roomle-dev/chore/progress-view-block-decision-RML-18283 ([c725f47](https://github.com/roomle-dev/roomle-ui/commit/c725f47)), closes [#3177](https://github.com/roomle-dev/roomle-ui/issues/3177)
|
|
13
|
+
* Merge pull request #3179 from roomle-dev/release/live ([a1ba2dc](https://github.com/roomle-dev/roomle-ui/commit/a1ba2dc)), closes [#3179](https://github.com/roomle-dev/roomle-ui/issues/3179)
|
|
14
|
+
* Merge pull request #3180 from roomle-dev/upgraded-by-ci/core-3.2.0-alpha.4 ([6b00f29](https://github.com/roomle-dev/roomle-ui/commit/6b00f29)), closes [#3180](https://github.com/roomle-dev/roomle-ui/issues/3180)
|
|
15
|
+
* Merge remote-tracking branch 'origin/master' into feat/upload-size-crop-camera-RML-18283 ([c432b1c](https://github.com/roomle-dev/roomle-ui/commit/c432b1c))
|
|
16
|
+
* Revert "fix: set the water connection level – only for PoC and has to be removed again" ([7b60e83](https://github.com/roomle-dev/roomle-ui/commit/7b60e83))
|
|
17
|
+
* feat: add the library context of the HI planner apart from the plan context ([8cc0028](https://github.com/roomle-dev/roomle-ui/commit/8cc0028))
|
|
18
|
+
* feat(hi): filter the attributes the agent sees, the element type first ([7de3fa8](https://github.com/roomle-dev/roomle-ui/commit/7de3fa8))
|
|
19
|
+
* feat: make the messages of the planning assistant chat selectable ([7bf8d15](https://github.com/roomle-dev/roomle-ui/commit/7bf8d15))
|
|
20
|
+
* feat(ai-chat): render every planner upload off-screen at 2048 px ([aa9361a](https://github.com/roomle-dev/roomle-ui/commit/aa9361a))
|
|
21
|
+
* feat(hi): run the hi agent tools in the planner, the embedding-lib forwards to them ([12eef7d](https://github.com/roomle-dev/roomle-ui/commit/12eef7d))
|
|
22
|
+
* feat(hi): run the initial checks of the library on loaded and new groups and modules ([218dad5](https://github.com/roomle-dev/roomle-ui/commit/218dad5))
|
|
23
|
+
* feat: show the agent the groups alone and the top view in get-plan-images ([9996ac1](https://github.com/roomle-dev/roomle-ui/commit/9996ac1))
|
|
24
|
+
* feat(core): upgrade to version 3.2.0-alpha.4 ([2980f4f](https://github.com/roomle-dev/roomle-ui/commit/2980f4f))
|
|
25
|
+
* chore(ai-render-eval): keep-photo wording and the spike's conclusion ([44f3b20](https://github.com/roomle-dev/roomle-ui/commit/44f3b20))
|
|
26
|
+
* chore: merge master into feat/hi-initial-checks-RML-18217 ([727b416](https://github.com/roomle-dev/roomle-ui/commit/727b416))
|
|
27
|
+
* chore(ai-render-eval): spike keep-showroom VIEW block for kept bird's-eye inputs ([ab870ed](https://github.com/roomle-dev/roomle-ui/commit/ab870ed))
|
|
28
|
+
* chore(ai-render-eval): staged variants for the keep-showroom spike ([4022fbe](https://github.com/roomle-dev/roomle-ui/commit/4022fbe))
|
|
29
|
+
* docs(progress): decision to keep the archviz VIEW block for birdsEyeView=keep ([2b025cc](https://github.com/roomle-dev/roomle-ui/commit/2b025cc))
|
|
30
|
+
* docs(hi): describe how the units of other groups follow their carriers on every row edit ([8124668](https://github.com/roomle-dev/roomle-ui/commit/8124668))
|
|
31
|
+
* docs(hi): describe when the planner loads the hi agent tools ([9da9439](https://github.com/roomle-dev/roomle-ui/commit/9da9439))
|
|
32
|
+
* docs(ai-chat): level 2 evidence for the window-independent upload ([46b79eb](https://github.com/roomle-dev/roomle-ui/commit/46b79eb))
|
|
33
|
+
* docs(hi): move the HI tool documentation from roomle-hi-example ([e2899dc](https://github.com/roomle-dev/roomle-ui/commit/e2899dc))
|
|
34
|
+
* docs(ai-chat): upload size independent of the window, 2D always adjusts ([6f1c871](https://github.com/roomle-dev/roomle-ui/commit/6f1c871))
|
|
35
|
+
* fix(hi): answer a tool call after the reloads of the plan changes its step reports ([9ba1fc0](https://github.com/roomle-dev/roomle-ui/commit/9ba1fc0))
|
|
36
|
+
* fix(hi): answer an inherited name as an unknown agent tool and load the tools again after a failed i ([f649372](https://github.com/roomle-dev/roomle-ui/commit/f649372))
|
|
37
|
+
* fix(hi): apply the group position when a root module gains or loses its docking vectors ([2d13dc5](https://github.com/roomle-dev/roomle-ui/commit/2d13dc5))
|
|
38
|
+
* fix(hi): declare the docking vector indices of the docking context optional ([2cca910](https://github.com/roomle-dev/roomle-ui/commit/2cca910))
|
|
39
|
+
* fix(hi): dock a root module the library calculates for the first time from its neighbour instead of ([7c12f90](https://github.com/roomle-dev/roomle-ui/commit/7c12f90))
|
|
40
|
+
* fix(hi): give the agent every attribute of the library and the attributes of the sub modules ([ffed98c](https://github.com/roomle-dev/roomle-ui/commit/ffed98c))
|
|
41
|
+
* fix(hi): give the sdk programs the vite client types instead of the skills module ([b5a7556](https://github.com/roomle-dev/roomle-ui/commit/b5a7556))
|
|
42
|
+
* fix(hi): keep the initial checks off split-off and duplicated groups and drop a failed check ([0df932f](https://github.com/roomle-dev/roomle-ui/commit/0df932f))
|
|
43
|
+
* fix(hi): keep the sub module inputs of a root a replace keeps ([e05c597](https://github.com/roomle-dev/roomle-ui/commit/e05c597))
|
|
44
|
+
* fix(hi): keep the units hanging above another one in the group after a delete in place ([5269f14](https://github.com/roomle-dev/roomle-ui/commit/5269f14))
|
|
45
|
+
* fix(ai-chat): keep worktop roles in the material legend stable ([feba857](https://github.com/roomle-dev/roomle-ui/commit/feba857)), closes [#3170](https://github.com/roomle-dev/roomle-ui/issues/3170)
|
|
46
|
+
* fix(hi): leave the element type out of the interior fittings the agent reads ([593b919](https://github.com/roomle-dev/roomle-ui/commit/593b919))
|
|
47
|
+
* fix(hi): move the groups of units above with their carriers when a delete and compact turns or shift ([abd5285](https://github.com/roomle-dev/roomle-ui/commit/abd5285))
|
|
48
|
+
* fix(hi): move the units above in other groups with their carriers on every row edit, each within its ([44c1c8c](https://github.com/roomle-dev/roomle-ui/commit/44c1c8c))
|
|
49
|
+
* fix(hi): name the attribute by its name and its id in the find-attributes answer ([fa76c8b](https://github.com/roomle-dev/roomle-ui/commit/fa76c8b))
|
|
50
|
+
* fix(sdk): set the image renderer's mode once at planner start ([4070792](https://github.com/roomle-dev/roomle-ui/commit/4070792)), closes [#3170](https://github.com/roomle-dev/roomle-ui/issues/3170)
|
|
51
|
+
* fix: set the water connection level – only for PoC and has to be removed again ([0f33f07](https://github.com/roomle-dev/roomle-ui/commit/0f33f07))
|
|
52
|
+
* fix(hi): stand a unit behind flush with the end its row starts from ([e76558b](https://github.com/roomle-dev/roomle-ui/commit/e76558b))
|
|
53
|
+
* fix(sdk): wait for the plan and its materials before renderCameraImage ([97c146b](https://github.com/roomle-dev/roomle-ui/commit/97c146b)), closes [#3170](https://github.com/roomle-dev/roomle-ui/issues/3170)
|
|
54
|
+
* style: format photo-camera spec ([1ef1343](https://github.com/roomle-dev/roomle-ui/commit/1ef1343))
|
|
55
|
+
* style: format scene-context ([32cc4b0](https://github.com/roomle-dev/roomle-ui/commit/32cc4b0))
|
|
56
|
+
* test(hi): calculate the failed root module from its value in the tool test ([49d09b6](https://github.com/roomle-dev/roomle-ui/commit/49d09b6))
|
|
57
|
+
* test(hi): expect a unit behind flush with the end its row starts from ([7a5258a](https://github.com/roomle-dev/roomle-ui/commit/7a5258a))
|
|
58
|
+
* test(hi): expect the group to keep its place when a root module gains or loses its docking vectors ([48bd05f](https://github.com/roomle-dev/roomle-ui/commit/48bd05f))
|
|
59
|
+
* test(hi): expect the units above in other groups to follow their carriers on every row edit, each wi ([acd66c9](https://github.com/roomle-dev/roomle-ui/commit/acd66c9))
|
|
60
|
+
* test(hi): expect units above in other groups to follow their carriers on a delete and compact ([6f44a41](https://github.com/roomle-dev/roomle-ui/commit/6f44a41))
|
|
61
|
+
* test: render the object perspective and the top view without the plan perspective ([40c9df5](https://github.com/roomle-dev/roomle-ui/commit/40c9df5))
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as e, c as t, i as n, m as r, o as i, s as a } from "./drag-in-
|
|
1
|
+
import { a as e, c as t, i as n, m as r, o as i, s as a } from "./drag-in-ClPpCYyi.mjs";
|
|
2
2
|
import "./embedding-plugins.js";
|
|
3
3
|
//#region packages/common/src/utils/drag.ts
|
|
4
4
|
var o = (e, t, n = 0, r = 0) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as e, c as t, i as n, m as r, o as i, s as a } from "./drag-in-
|
|
1
|
+
import { a as e, c as t, i as n, m as r, o as i, s as a } from "./drag-in-CV1E-DO6.mjs";
|
|
2
2
|
import "./embedding-plugins.min.js";
|
|
3
3
|
var o = (e, t, n = 0, r = 0) => {
|
|
4
4
|
let i = t.x + t.width + n, a = t.x - n, o = t.y + t.height + r, s = t.y - r, { x: c, y: l } = e;
|
|
@@ -34,7 +34,7 @@ var e = Object.defineProperty, t = (t, n) => {
|
|
|
34
34
|
}
|
|
35
35
|
async init() {
|
|
36
36
|
if (await super.init(), this._mode === "website") try {
|
|
37
|
-
let { DragInFromWebsiteStrategy: e } = await import("./from-website-
|
|
37
|
+
let { DragInFromWebsiteStrategy: e } = await import("./from-website-BmCO2xli.mjs");
|
|
38
38
|
this._strategy = new e(this._instance, this._mainDomElement, {
|
|
39
39
|
settings: this.options,
|
|
40
40
|
mode: "website"
|
|
@@ -45,7 +45,7 @@ var e = Object.defineProperty, t = (t, n) => {
|
|
|
45
45
|
else {
|
|
46
46
|
if (this._mode !== "custom-view") throw Error("Unsupported mode");
|
|
47
47
|
try {
|
|
48
|
-
let { DragInFromCustomViewStrategy: e } = await import("./from-custom-view-
|
|
48
|
+
let { DragInFromCustomViewStrategy: e } = await import("./from-custom-view-Sx6P6iDI.mjs");
|
|
49
49
|
this._strategy = new e(this._instance, this._mainDomElement, this.options, this._viewName);
|
|
50
50
|
} catch (e) {
|
|
51
51
|
throw e;
|
|
@@ -41,7 +41,7 @@ var e = Object.defineProperty, t = (t, n) => {
|
|
|
41
41
|
}
|
|
42
42
|
async init() {
|
|
43
43
|
if (await super.init(), this._mode === "website") try {
|
|
44
|
-
let { DragInFromWebsiteStrategy: e } = await import("./from-website-
|
|
44
|
+
let { DragInFromWebsiteStrategy: e } = await import("./from-website-DZJy_l42.mjs");
|
|
45
45
|
this._strategy = new e(this._instance, this._mainDomElement, {
|
|
46
46
|
settings: this.options,
|
|
47
47
|
mode: "website"
|
|
@@ -50,7 +50,7 @@ var e = Object.defineProperty, t = (t, n) => {
|
|
|
50
50
|
throw console.error("Could not load Dragin strategy \"FromWebsite\""), e;
|
|
51
51
|
}
|
|
52
52
|
else if (this._mode === "custom-view") try {
|
|
53
|
-
let { DragInFromCustomViewStrategy: e } = await import("./from-custom-view-
|
|
53
|
+
let { DragInFromCustomViewStrategy: e } = await import("./from-custom-view-Q9A-J7qV.mjs");
|
|
54
54
|
this._strategy = new e(this._instance, this._mainDomElement, this.options, this._viewName);
|
|
55
55
|
} catch (e) {
|
|
56
56
|
throw console.error("Could not load Dragin strategy \"FromCustomView\""), e;
|
package/embedding-plugins.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, c as t, d as n, f as r, h as i, i as a, m as o, o as s, s as c, t as l, u } from "./drag-in-
|
|
1
|
+
import { a as e, c as t, d as n, f as r, h as i, i as a, m as o, o as s, s as c, t as l, u } from "./drag-in-ClPpCYyi.mjs";
|
|
2
2
|
export { l as DragIn, a as RML_DRAG_GHOST_FADE_IN, e as RML_DRAG_GHOST_FADE_IN_ANIMATION_CSS, s as RML_DRAG_GHOST_FADE_OUT, c as RML_DRAG_GHOST_FADE_OUT_ANIMATION_CSS, t as RML_DRAG_IN_DRAG_ELEMENT_ID, u as RML_DRAG_IN_FALLBACK_GHOST_HEIGHT, n as RML_DRAG_IN_FALLBACK_GHOST_URL, r as RML_DRAG_IN_FALLBACK_GHOST_WIDTH, o as RML_DRAG_IN_STYLES_ID, i as TARGET_OPACITY };
|
package/embedding-plugins.min.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, c as t, d as n, f as r, h as i, i as a, m as o, o as s, s as c, t as l, u } from "./drag-in-
|
|
1
|
+
import { a as e, c as t, d as n, f as r, h as i, i as a, m as o, o as s, s as c, t as l, u } from "./drag-in-CV1E-DO6.mjs";
|
|
2
2
|
export { l as DragIn, a as RML_DRAG_GHOST_FADE_IN, e as RML_DRAG_GHOST_FADE_IN_ANIMATION_CSS, s as RML_DRAG_GHOST_FADE_OUT, c as RML_DRAG_GHOST_FADE_OUT_ANIMATION_CSS, t as RML_DRAG_IN_DRAG_ELEMENT_ID, u as RML_DRAG_IN_FALLBACK_GHOST_HEIGHT, n as RML_DRAG_IN_FALLBACK_GHOST_URL, r as RML_DRAG_IN_FALLBACK_GHOST_WIDTH, o as RML_DRAG_IN_STYLES_ID, i as TARGET_OPACITY };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { d as e } from "./drag-in-
|
|
1
|
+
import { d as e } from "./drag-in-ClPpCYyi.mjs";
|
|
2
2
|
import { a as t, c as n, n as r } from "./utils-DxJ3PcKe.mjs";
|
|
3
|
-
import { t as i } from "./drag-ghost-
|
|
3
|
+
import { t as i } from "./drag-ghost-BxqPJdhq.mjs";
|
|
4
4
|
var a = (e, t = 0) => n(e) ? {
|
|
5
5
|
clientX: e.touches[t].clientX,
|
|
6
6
|
clientY: e.touches[t].clientY
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { d as e } from "./drag-in-
|
|
1
|
+
import { d as e } from "./drag-in-CV1E-DO6.mjs";
|
|
2
2
|
import { a as t, c as n, n as r } from "./utils-wJ80awOA.mjs";
|
|
3
|
-
import { t as i } from "./drag-ghost-
|
|
3
|
+
import { t as i } from "./drag-ghost-CDFtC1pd.mjs";
|
|
4
4
|
var a = (e, t = 0) => n(e) ? {
|
|
5
5
|
clientX: e.touches[t].clientX,
|
|
6
6
|
clientY: e.touches[t].clientY
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { l as e, p as t, r as n } from "./drag-in-
|
|
1
|
+
import { l as e, p as t, r as n } from "./drag-in-CV1E-DO6.mjs";
|
|
2
2
|
import { c as r, i, n as a, o, r as s, s as c } from "./utils-wJ80awOA.mjs";
|
|
3
|
-
import { t as l } from "./drag-ghost-
|
|
3
|
+
import { t as l } from "./drag-ghost-CDFtC1pd.mjs";
|
|
4
4
|
var u = class {
|
|
5
5
|
_options = {};
|
|
6
6
|
_instance;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { l as e, p as t, r as n } from "./drag-in-
|
|
1
|
+
import { l as e, p as t, r as n } from "./drag-in-ClPpCYyi.mjs";
|
|
2
2
|
import { c as r, i, n as a, o, r as s, s as c } from "./utils-DxJ3PcKe.mjs";
|
|
3
|
-
import { t as l } from "./drag-ghost-
|
|
3
|
+
import { t as l } from "./drag-ghost-BxqPJdhq.mjs";
|
|
4
4
|
//#region packages/embedding-lib/src/plugins/strategy/from-website.ts
|
|
5
5
|
var u = class {
|
|
6
6
|
_options = {};
|
package/hi.js
CHANGED
|
@@ -65,12 +65,52 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
65
65
|
}, window.addEventListener("message", h);
|
|
66
66
|
}, _ = () => {
|
|
67
67
|
h &&= (window.removeEventListener("message", h), null);
|
|
68
|
-
}, v =
|
|
68
|
+
}, v = ({ output: e }) => ({
|
|
69
|
+
type: "content",
|
|
70
|
+
value: e.content.map((e) => e.type === "text" ? {
|
|
71
|
+
type: "text",
|
|
72
|
+
text: e.text
|
|
73
|
+
} : {
|
|
74
|
+
type: "file",
|
|
75
|
+
mediaType: e.mimeType,
|
|
76
|
+
data: {
|
|
77
|
+
type: "data",
|
|
78
|
+
data: e.data
|
|
79
|
+
}
|
|
80
|
+
})
|
|
81
|
+
}), y = async ({ extended: e }) => {
|
|
82
|
+
if (typeof e.getExternalObjectAgentTools != "function") throw Error("The planner has no HI agent tools: it needs a Rubens UI with getExternalObjectAgentTools.");
|
|
83
|
+
let t = await e.getExternalObjectAgentTools();
|
|
84
|
+
return Object.fromEntries(t.map(({ name: t, description: n, inputSchema: r }) => {
|
|
85
|
+
let i = () => r;
|
|
86
|
+
return [t, {
|
|
87
|
+
type: "dynamic",
|
|
88
|
+
description: n,
|
|
89
|
+
inputSchema: { "~standard": {
|
|
90
|
+
version: 1,
|
|
91
|
+
vendor: "hi-mcp",
|
|
92
|
+
validate: (e) => ({ value: e }),
|
|
93
|
+
jsonSchema: {
|
|
94
|
+
input: i,
|
|
95
|
+
output: i
|
|
96
|
+
}
|
|
97
|
+
} },
|
|
98
|
+
execute: (n) => e.callExternalObjectAgentTool(t, n).catch((e) => ({
|
|
99
|
+
content: [{
|
|
100
|
+
type: "text",
|
|
101
|
+
text: e instanceof Error ? e.message : String(e)
|
|
102
|
+
}],
|
|
103
|
+
isError: !0
|
|
104
|
+
})),
|
|
105
|
+
toModelOutput: v
|
|
106
|
+
}];
|
|
107
|
+
}));
|
|
108
|
+
}, b = (e) => `https://esm.sh/${e}?deps=zod@4.6.5`, x = 16, S = async ({ provider: e, model: t, apiKey: n, baseUrl: r, chatCompletions: i, reasoningEffort: a }) => {
|
|
69
109
|
switch (e) {
|
|
70
110
|
case "azure": {
|
|
71
111
|
let { createAzure: e } = await import(
|
|
72
112
|
/* @vite-ignore */
|
|
73
|
-
|
|
113
|
+
b("@ai-sdk/azure@4.0.85")
|
|
74
114
|
), o = e({
|
|
75
115
|
apiKey: n,
|
|
76
116
|
baseURL: r
|
|
@@ -83,14 +123,14 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
83
123
|
case "mistral": {
|
|
84
124
|
let { createMistral: e } = await import(
|
|
85
125
|
/* @vite-ignore */
|
|
86
|
-
|
|
126
|
+
b("@ai-sdk/mistral@4.0.54")
|
|
87
127
|
);
|
|
88
128
|
return { languageModel: e({ apiKey: n })(t) };
|
|
89
129
|
}
|
|
90
130
|
case "anthropic": {
|
|
91
131
|
let { createAnthropic: e } = await import(
|
|
92
132
|
/* @vite-ignore */
|
|
93
|
-
|
|
133
|
+
b("@ai-sdk/anthropic@4.0.68")
|
|
94
134
|
);
|
|
95
135
|
return { languageModel: e({
|
|
96
136
|
apiKey: n,
|
|
@@ -100,23 +140,23 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
100
140
|
case "google": {
|
|
101
141
|
let { createGoogleGenerativeAI: e } = await import(
|
|
102
142
|
/* @vite-ignore */
|
|
103
|
-
|
|
143
|
+
b("@ai-sdk/google@4.0.85")
|
|
104
144
|
);
|
|
105
145
|
return { languageModel: e({ apiKey: n })(t) };
|
|
106
146
|
}
|
|
107
147
|
default: throw Error(`Unknown provider "${e}" - supported: azure, mistral, anthropic, google`);
|
|
108
148
|
}
|
|
109
|
-
},
|
|
149
|
+
}, C = async (e, t, n) => {
|
|
110
150
|
let r = e.extended, i = (e) => r.planningAssistantOutput(e), a;
|
|
111
151
|
try {
|
|
112
152
|
a = await Promise.all([
|
|
113
153
|
import(
|
|
114
154
|
/* @vite-ignore */
|
|
115
|
-
|
|
155
|
+
b("ai@7.0.122")
|
|
116
156
|
),
|
|
117
|
-
|
|
157
|
+
S(t),
|
|
118
158
|
r.getExternalObjectAgentPrompts(),
|
|
119
|
-
|
|
159
|
+
y(e)
|
|
120
160
|
]);
|
|
121
161
|
} catch (e) {
|
|
122
162
|
console.log("[planning-assistant]", String(e)), i({
|
|
@@ -146,9 +186,9 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
146
186
|
instructions: l.systemPrompt,
|
|
147
187
|
messages: [...d, r],
|
|
148
188
|
tools: u,
|
|
149
|
-
stopWhen: s(
|
|
189
|
+
stopWhen: s(x),
|
|
150
190
|
abortSignal: n,
|
|
151
|
-
prepareStep: ({ stepNumber: e }) => e ===
|
|
191
|
+
prepareStep: ({ stepNumber: e }) => e === x - 1 ? { toolChoice: "none" } : void 0
|
|
152
192
|
});
|
|
153
193
|
for await (let t of e.stream) if (t.type === "text-delta") i({
|
|
154
194
|
type: "text",
|
|
@@ -173,10 +213,10 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
173
213
|
type: "availability",
|
|
174
214
|
available: !0
|
|
175
215
|
});
|
|
176
|
-
},
|
|
216
|
+
}, w = {
|
|
177
217
|
HIDE: "hide",
|
|
178
218
|
SHOW_ATTRIBUTES: "attributes",
|
|
179
219
|
SHOW_ARTICLES: "articles"
|
|
180
220
|
};
|
|
181
221
|
//#endregion
|
|
182
|
-
export {
|
|
222
|
+
export { w as HI_PANEL_ACTION, _ as cleanupHi, d as createHiLibraryCallbacks, y as createHiMcpTools, c as libLoadArticleCatalog, u as libLoadCalcScript, l as libLoadMasterData, S as loadChatModel, p as omGetRequest, f as omPostRequest, a as registerLegacyUrlFormat, g as setupHi, C as startPlanningAssistant, o as unregisterLegacyUrlFormat };
|
package/hi.min.js
CHANGED
|
@@ -66,10 +66,50 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
66
66
|
}, window.addEventListener("message", m);
|
|
67
67
|
}, g = () => {
|
|
68
68
|
m &&= (window.removeEventListener("message", m), null);
|
|
69
|
-
}, _ =
|
|
69
|
+
}, _ = ({ output: e }) => ({
|
|
70
|
+
type: "content",
|
|
71
|
+
value: e.content.map((e) => e.type === "text" ? {
|
|
72
|
+
type: "text",
|
|
73
|
+
text: e.text
|
|
74
|
+
} : {
|
|
75
|
+
type: "file",
|
|
76
|
+
mediaType: e.mimeType,
|
|
77
|
+
data: {
|
|
78
|
+
type: "data",
|
|
79
|
+
data: e.data
|
|
80
|
+
}
|
|
81
|
+
})
|
|
82
|
+
}), v = async ({ extended: e }) => {
|
|
83
|
+
if (typeof e.getExternalObjectAgentTools != "function") throw Error("The planner has no HI agent tools: it needs a Rubens UI with getExternalObjectAgentTools.");
|
|
84
|
+
let t = await e.getExternalObjectAgentTools();
|
|
85
|
+
return Object.fromEntries(t.map(({ name: t, description: n, inputSchema: r }) => {
|
|
86
|
+
let i = () => r;
|
|
87
|
+
return [t, {
|
|
88
|
+
type: "dynamic",
|
|
89
|
+
description: n,
|
|
90
|
+
inputSchema: { "~standard": {
|
|
91
|
+
version: 1,
|
|
92
|
+
vendor: "hi-mcp",
|
|
93
|
+
validate: (e) => ({ value: e }),
|
|
94
|
+
jsonSchema: {
|
|
95
|
+
input: i,
|
|
96
|
+
output: i
|
|
97
|
+
}
|
|
98
|
+
} },
|
|
99
|
+
execute: (n) => e.callExternalObjectAgentTool(t, n).catch((e) => ({
|
|
100
|
+
content: [{
|
|
101
|
+
type: "text",
|
|
102
|
+
text: e instanceof Error ? e.message : String(e)
|
|
103
|
+
}],
|
|
104
|
+
isError: !0
|
|
105
|
+
})),
|
|
106
|
+
toModelOutput: _
|
|
107
|
+
}];
|
|
108
|
+
}));
|
|
109
|
+
}, y = (e) => `https://esm.sh/${e}?deps=zod@4.6.5`, b = async ({ provider: e, model: t, apiKey: n, baseUrl: r, chatCompletions: i, reasoningEffort: a }) => {
|
|
70
110
|
switch (e) {
|
|
71
111
|
case "azure": {
|
|
72
|
-
let { createAzure: e } = await import(
|
|
112
|
+
let { createAzure: e } = await import(y("@ai-sdk/azure@4.0.85")), o = e({
|
|
73
113
|
apiKey: n,
|
|
74
114
|
baseURL: r
|
|
75
115
|
});
|
|
@@ -79,30 +119,30 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
79
119
|
};
|
|
80
120
|
}
|
|
81
121
|
case "mistral": {
|
|
82
|
-
let { createMistral: e } = await import(
|
|
122
|
+
let { createMistral: e } = await import(y("@ai-sdk/mistral@4.0.54"));
|
|
83
123
|
return { languageModel: e({ apiKey: n })(t) };
|
|
84
124
|
}
|
|
85
125
|
case "anthropic": {
|
|
86
|
-
let { createAnthropic: e } = await import(
|
|
126
|
+
let { createAnthropic: e } = await import(y("@ai-sdk/anthropic@4.0.68"));
|
|
87
127
|
return { languageModel: e({
|
|
88
128
|
apiKey: n,
|
|
89
129
|
headers: { "anthropic-dangerous-direct-browser-access": "true" }
|
|
90
130
|
})(t) };
|
|
91
131
|
}
|
|
92
132
|
case "google": {
|
|
93
|
-
let { createGoogleGenerativeAI: e } = await import(
|
|
133
|
+
let { createGoogleGenerativeAI: e } = await import(y("@ai-sdk/google@4.0.85"));
|
|
94
134
|
return { languageModel: e({ apiKey: n })(t) };
|
|
95
135
|
}
|
|
96
136
|
default: throw Error(`Unknown provider "${e}" - supported: azure, mistral, anthropic, google`);
|
|
97
137
|
}
|
|
98
|
-
},
|
|
138
|
+
}, x = async (e, t, n) => {
|
|
99
139
|
let r = e.extended, i = (e) => r.planningAssistantOutput(e), a;
|
|
100
140
|
try {
|
|
101
141
|
a = await Promise.all([
|
|
102
|
-
import(
|
|
103
|
-
|
|
142
|
+
import(y("ai@7.0.122")),
|
|
143
|
+
b(t),
|
|
104
144
|
r.getExternalObjectAgentPrompts(),
|
|
105
|
-
|
|
145
|
+
v(e)
|
|
106
146
|
]);
|
|
107
147
|
} catch (e) {
|
|
108
148
|
i({
|
|
@@ -159,9 +199,9 @@ var n = (e, t) => t === e.libraryId ? e : {
|
|
|
159
199
|
type: "availability",
|
|
160
200
|
available: !0
|
|
161
201
|
});
|
|
162
|
-
},
|
|
202
|
+
}, S = {
|
|
163
203
|
HIDE: "hide",
|
|
164
204
|
SHOW_ATTRIBUTES: "attributes",
|
|
165
205
|
SHOW_ARTICLES: "articles"
|
|
166
206
|
};
|
|
167
|
-
export {
|
|
207
|
+
export { S as HI_PANEL_ACTION, g as cleanupHi, d as createHiLibraryCallbacks, v as createHiMcpTools, c as libLoadArticleCatalog, u as libLoadCalcScript, l as libLoadMasterData, b as loadChatModel, p as omGetRequest, f as omPostRequest, a as registerLegacyUrlFormat, h as setupHi, x as startPlanningAssistant, o as unregisterLegacyUrlFormat };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@roomle/embedding-lib",
|
|
3
|
-
"version": "9.0.0-alpha.
|
|
3
|
+
"version": "9.0.0-alpha.5",
|
|
4
4
|
"description": "This is a small library which can be used to communicate with the Roomle Configurator. ES modules only (browser-compatible).",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./roomle-embedding-lib.js",
|
|
@@ -14,9 +14,7 @@ export { createHiLibraryCallbacks } from './homag-intelligence/hi-callbacks';
|
|
|
14
14
|
export { libLoadArticleCatalog, libLoadMasterData, libLoadCalcScript, registerLegacyUrlFormat, unregisterLegacyUrlFormat, } from './homag-intelligence/hi-requests';
|
|
15
15
|
export { omPostRequest, omGetRequest, } from './homag-intelligence/hi-order-manager';
|
|
16
16
|
export { setupHi, cleanupHi } from './homag-intelligence/hi-setup';
|
|
17
|
-
export { createHiMcpTools } from './homag-intelligence/hi-mcp-tools';
|
|
18
|
-
export type { HiMcpTool, HiMcpTools, } from './homag-intelligence/hi-mcp/mcp-tool-types';
|
|
19
|
-
export type { HiMcpPlannerApi } from './homag-intelligence/hi-mcp/planner-api';
|
|
17
|
+
export { createHiMcpTools, type HiMcpTool, type HiMcpTools, type HiMcpPlannerApi, } from './homag-intelligence/hi-mcp-tools';
|
|
20
18
|
export { loadChatModel, startPlanningAssistant, type PlanningAssistantConfig, type PlanningAssistantPlannerApi, } from './homag-intelligence/hi-planning-assistant';
|
|
21
19
|
export { type ExternalObjectSnapshotSaveResult, type HiContextAction, } from '../../web-sdk/packages';
|
|
22
20
|
export { HI_PANEL_ACTION, type HiPanelActionType, type HiOrderHeader, type HiOrder, type HiOrderData, type HiPriceData, type HiCallbacks, } from '../../common/src/hi/hi-types';
|
|
@@ -1,11 +1,68 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { HiAgentToolDefinition, McpToolResult } from '../../../web-sdk/packages';
|
|
2
|
+
/** What the model gets of a tool result, as `@ai-sdk/mcp` hands it to the AI SDK. */
|
|
3
|
+
export interface HiMcpModelOutput {
|
|
4
|
+
type: 'content';
|
|
5
|
+
value: ({
|
|
6
|
+
type: 'text';
|
|
7
|
+
text: string;
|
|
8
|
+
} | {
|
|
9
|
+
type: 'file';
|
|
10
|
+
mediaType: string;
|
|
11
|
+
data: {
|
|
12
|
+
type: 'data';
|
|
13
|
+
data: string;
|
|
14
|
+
};
|
|
15
|
+
})[];
|
|
16
|
+
}
|
|
17
|
+
/** The input schema of a tool as a Standard Schema with its JSON Schema. */
|
|
18
|
+
export interface HiMcpInputSchema {
|
|
19
|
+
'~standard': {
|
|
20
|
+
version: 1;
|
|
21
|
+
vendor: string;
|
|
22
|
+
validate: (value: unknown) => {
|
|
23
|
+
value: unknown;
|
|
24
|
+
};
|
|
25
|
+
jsonSchema: {
|
|
26
|
+
input: (options: {
|
|
27
|
+
target: string;
|
|
28
|
+
}) => Record<string, unknown>;
|
|
29
|
+
output: (options: {
|
|
30
|
+
target: string;
|
|
31
|
+
}) => Record<string, unknown>;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
/** A tool of the HI MCP tool set, in the shape of an AI SDK dynamic tool. */
|
|
36
|
+
export interface HiMcpTool {
|
|
37
|
+
type: 'dynamic';
|
|
38
|
+
description: string;
|
|
39
|
+
inputSchema: HiMcpInputSchema;
|
|
40
|
+
execute: (input: unknown) => Promise<McpToolResult>;
|
|
41
|
+
toModelOutput: (options: {
|
|
42
|
+
output: McpToolResult;
|
|
43
|
+
}) => HiMcpModelOutput;
|
|
44
|
+
}
|
|
45
|
+
/** The HI MCP tools by name, the tool set an AI SDK `streamText` takes. */
|
|
46
|
+
export type HiMcpTools = Record<string, HiMcpTool>;
|
|
47
|
+
/** The planner methods the HI MCP tools forward to: the HI agent tools of the planner. */
|
|
48
|
+
export interface HiMcpPlannerApi {
|
|
49
|
+
extended: {
|
|
50
|
+
getExternalObjectAgentTools(): Promise<HiAgentToolDefinition[]>;
|
|
51
|
+
callExternalObjectAgentTool(name: string, input: unknown): Promise<McpToolResult>;
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
/** The tool result as `@ai-sdk/mcp` passes it to the model: text parts and images as file parts. */
|
|
55
|
+
export declare const mcpToModelOutput: ({ output, }: {
|
|
56
|
+
output: McpToolResult;
|
|
57
|
+
}) => HiMcpModelOutput;
|
|
3
58
|
/**
|
|
4
59
|
* Creates the HI MCP tools for an AI agent that plans in the planner of this
|
|
5
|
-
* page: the tools of the
|
|
6
|
-
* protocol. The host passes the tool set as `tools` to its own
|
|
7
|
-
* The tools
|
|
8
|
-
* `
|
|
9
|
-
*
|
|
60
|
+
* page: the HI agent tools of the planner as an AI SDK tool set, without the
|
|
61
|
+
* MCP protocol. The host passes the tool set as `tools` to its own
|
|
62
|
+
* `streamText`. The tools run in the planner; every call is forwarded to
|
|
63
|
+
* `callExternalObjectAgentTool`. The AI SDK gets the JSON Schema of each input
|
|
64
|
+
* and lets every input through: the planner validates it and answers an
|
|
65
|
+
* invalid input and a failed call as an MCP error result (`isError`), as a
|
|
66
|
+
* forwarding error is answered here.
|
|
10
67
|
*/
|
|
11
|
-
export declare const createHiMcpTools: (
|
|
68
|
+
export declare const createHiMcpTools: ({ extended, }: HiMcpPlannerApi) => Promise<HiMcpTools>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PlanningAssistantOutput, PlanningAssistantPrompt } from '../../../web-sdk/packages';
|
|
2
|
-
import { HiMcpPlannerApi } from './hi-mcp
|
|
2
|
+
import { HiMcpPlannerApi } from './hi-mcp-tools';
|
|
3
3
|
/**
|
|
4
4
|
* The model of the AI Planning Assistant as a JSON object: everything
|
|
5
5
|
* `loadChatModel` and `startPlanningAssistant` need to reach it.
|
|
@@ -49,7 +49,7 @@ export declare const loadChatModel: ({ provider, model, apiKey, baseUrl, chatCom
|
|
|
49
49
|
* Runs the planning agent of the AI Planning Assistant window
|
|
50
50
|
* (featureFlags.planningAssistant) in this page: the window hands every
|
|
51
51
|
* message to "onPlanningAssistantPrompt", the agent calls the HI MCP tools,
|
|
52
|
-
* the tools
|
|
52
|
+
* the tools run in the planner of this page, and the agent's output goes to
|
|
53
53
|
* "planningAssistantOutput". Aborting the signal ends a running turn.
|
|
54
54
|
*/
|
|
55
55
|
export declare const startPlanningAssistant: (roomDesignerApi: PlanningAssistantPlannerApi, config: PlanningAssistantConfig, signal: AbortSignal) => Promise<void>;
|
package/roomle-embedding-lib.js
CHANGED
|
@@ -203,7 +203,7 @@ var t = class {
|
|
|
203
203
|
setupPlugins(e, t, n = "website") {
|
|
204
204
|
for (let r of e) typeof r == "string" && r === "dragIn" ? this.pluginsLoaded.push(new Promise((e, r) => {
|
|
205
205
|
try {
|
|
206
|
-
import("./drag-in-
|
|
206
|
+
import("./drag-in-ClPpCYyi.mjs").then((e) => e.n).then(({ DragIn: i }) => {
|
|
207
207
|
let a = new i(this.ui, t, n, this.viewName);
|
|
208
208
|
a.init().then(() => {
|
|
209
209
|
this.plugins.dragIn = a, e();
|
|
@@ -184,7 +184,7 @@ var t = class {
|
|
|
184
184
|
setupPlugins(e, t, n = "website") {
|
|
185
185
|
for (let r of e) typeof r == "string" && r === "dragIn" ? this.pluginsLoaded.push(new Promise((e, r) => {
|
|
186
186
|
try {
|
|
187
|
-
import("./drag-in-
|
|
187
|
+
import("./drag-in-CV1E-DO6.mjs").then((e) => e.n).then(({ DragIn: i }) => {
|
|
188
188
|
let a = new i(this.ui, t, n, this.viewName);
|
|
189
189
|
a.init().then(() => {
|
|
190
190
|
this.plugins.dragIn = a, e();
|