@floless/app 0.156.0 → 0.157.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.
- package/cli-actions.mjs +21 -5
- package/dist/floless-server.cjs +70965 -43326
- package/dist/schemas/drawing-check.profile.v1.schema.json +15 -2
- package/dist/schemas/steel.model.v2.schema.json +25 -1
- package/dist/skills/floless-app-actions/SKILL.md +79 -17
- package/dist/skills/floless-app-knowledge/SKILL.md +21 -2
- package/dist/skills/floless-app-new-workflow/SKILL.md +23 -7
- package/dist/skills/floless-app-onboarding/SKILL.md +31 -1
- package/dist/skills/floless-app-report-issue/SKILL.md +3 -3
- package/dist/skills/floless-app-rfi/SKILL.md +40 -6
- package/dist/skills/floless-app-routines/SKILL.md +9 -2
- package/dist/skills/floless-app-steel-model/SKILL.md +1 -1
- package/dist/skills/floless-app-steel-model/references/detail-from-a-screenshot.md +4 -2
- package/dist/skills/floless-app-tweak-contract/SKILL.md +25 -5
- package/dist/skills/floless-app-workflows/SKILL.md +46 -10
- package/dist/skills/floless-app-workflows/references/agent-steps.md +119 -0
- package/dist/web/agent-steps.js +864 -47
- package/dist/web/agents.js +28 -8
- package/dist/web/app.css +478 -3
- package/dist/web/app.js +110 -11
- package/dist/web/aware-update-client.js +1 -0
- package/dist/web/aware.js +685 -170
- package/dist/web/chat-landing-scene.js +372 -0
- package/dist/web/chat.css +245 -1
- package/dist/web/chat.js +2466 -78
- package/dist/web/commands-drawing-check.js +17 -0
- package/dist/web/commands-shell.js +820 -3
- package/dist/web/commands-steel.js +6 -0
- package/dist/web/connections.js +1 -0
- package/dist/web/drawing-check-editor.html +33 -5
- package/dist/web/drawing-check-editor.js +538 -22
- package/dist/web/drawing-check-overlay.js +13 -0
- package/dist/web/flo-avatar.js +28 -3
- package/dist/web/guide.js +7 -2
- package/dist/web/index.html +119 -6
- package/dist/web/instructor.js +3 -3
- package/dist/web/model-view-query.js +12 -2
- package/dist/web/pages.js +865 -34
- package/dist/web/panels.js +5 -2
- package/dist/web/parser-setup-recovery.js +12 -4
- package/dist/web/project-access.js +549 -0
- package/dist/web/report-files.js +50 -0
- package/dist/web/startup-admission.js +132 -0
- package/dist/web/steel-3d-core.js +9 -0
- package/dist/web/steel-editor.html +642 -22
- package/dist/web/steel-model-v2-commands.js +63 -5
- package/dist/web/step-rename.js +287 -0
- package/dist/web/terminal-requests.js +59 -10
- package/dist/web/tool-updates.js +1 -0
- package/dist/web/workspace-root-management.js +39 -0
- package/dist/web/workspaces.js +1667 -63
- package/launch.mjs +9 -7
- package/package.json +3 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: floless-app-workflows
|
|
3
|
-
description: This skill should be used when building, modifying, or reasoning about FloLess .flo workflows for floless.app — especially reusable apps that take inputs (e.g. a phase number) and run across different Tekla
|
|
3
|
+
description: This skill should be used when building, modifying, or reasoning about FloLess .flo workflows for floless.app — especially reusable apps that take inputs (e.g. a phase number) and run across different models from any source (Tekla, Revit, Rhino, SketchUp, an IFC file, the FloLess steel model, a Workspace project), exec nodes that run code against a live host model (e.g. Roslyn C# in Tekla), Blender animations of a building (blender/exec Python rendered headlessly — construction sequence, fly-through, sun study), the in-app HTML Viewer, the Code tab, or "Debug in VS". Covers the exec contract, the install→validate→compile→run loop, app inputs templating, reading approved Workspace project data and immutable approved Revit model snapshots through the floless-workspace REST seam plus its themed pickers, and the server seams (aware-adapter, app-reader, index).
|
|
4
4
|
metadata:
|
|
5
|
-
version: 0.7
|
|
5
|
+
version: 0.8.7
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Building reusable .flo workflows in floless.app
|
|
@@ -16,7 +16,9 @@ an LLM — it renders AWARE state, triggers `aware` verbs, and relays user inten
|
|
|
16
16
|
|
|
17
17
|
The deliverable floless.app produces is a **reusable FloLess `.flo` app** (which runs on AWARE): one that declares
|
|
18
18
|
`inputs:` with defaults and runs unchanged across different models. The canonical example
|
|
19
|
-
lives at `demos/tekla-bom-by-phase/` — study it before building a new one.
|
|
19
|
+
lives at `demos/tekla-bom-by-phase/` — study it before building a new one. It is a Tekla
|
|
20
|
+
workflow only because Tekla came first: the shape (inputs → core logic → viewer) is the same
|
|
21
|
+
for any host or for none, so don't assume the user's model is in Tekla — ask what it is in.
|
|
20
22
|
|
|
21
23
|
> **Pasted a request?** If the user pastes a message beginning with a
|
|
22
24
|
> `[floless-request type=tweak|use-template id=…]` marker, that's a request **copied from the
|
|
@@ -164,6 +166,18 @@ Two rules that bite immediately:
|
|
|
164
166
|
Do **not** write a file. AWARE ships no html-report render binary, and inline HTML keeps the
|
|
165
167
|
app model-agnostic (no filesystem permission, no hardcoded path). The HTML Viewer renders
|
|
166
168
|
whatever the node returns.
|
|
169
|
+
- **A report with files (images, a 3D model, data) — `report_folder`.** Every successful real run's
|
|
170
|
+
report becomes the next version of the workflow's Page. When the report needs files beside it,
|
|
171
|
+
write them under one folder as `<folder>/assets/...` (up to two folders deep inside `assets/`,
|
|
172
|
+
Page file types only, 50 MB per file), reference them from the HTML as `assets/...`, and return
|
|
173
|
+
the folder's full path with the HTML: `return new { ok = true, html = ..., report_folder = dir };`.
|
|
174
|
+
Give each run a folder of its own (for example a timestamp in its name): FloLess reads the folder
|
|
175
|
+
when the run finishes, so a later run writing into the same folder could mix its files in.
|
|
176
|
+
The Page version is the returned `html` plus those files; the run's HTML Viewer still shows
|
|
177
|
+
`html` alone, where those relative files don't load (they show in the Page: Open in Pages). A
|
|
178
|
+
folder FloLess can't use (a link, a file type a Page can't carry, over a limit) saves the report
|
|
179
|
+
without its files and says why. AWARE `viewer-3d` views and complete model property reports are
|
|
180
|
+
captured on their own — no `report_folder` needed.
|
|
167
181
|
- **No `System.Net`** (so no `WebUtility.HtmlEncode`) — escape with a manual lambda.
|
|
168
182
|
|
|
169
183
|
## Building animations: `blender/exec` (Python, rendered headlessly)
|
|
@@ -365,6 +379,23 @@ picker, HTTP-200 gate, and one Run/HTML Viewer path for Revit and Tekla Parser.
|
|
|
365
379
|
the whole report to one approved revision and current module entitlement; do not add a page-size
|
|
366
380
|
or object/property cap, or treat an incomplete stream as a report. See `references/workspace-data.md`.
|
|
367
381
|
|
|
382
|
+
## Put a saved Agent in a workflow (Agent steps) — AWARE 0.160.0+
|
|
383
|
+
|
|
384
|
+
An **Agent step** runs one Agent the person saved on the Agents page as a step of the workflow: the only
|
|
385
|
+
way a model may reason at run time, and only with the person's recorded confirmation that its answer may
|
|
386
|
+
differ each run. Read `references/agent-steps.md` before adding one. The rules in short:
|
|
387
|
+
|
|
388
|
+
- Use one only for work that needs judgement at run time; anything a fixed rule can do stays an ordinary node.
|
|
389
|
+
- Find the Agent with `agent-steps.agents`, then get the step from FloLess with the `agent-steps.block` action and copy it byte for byte (the step and its
|
|
390
|
+
`<id>-ok` predicate); never type the pinned fields. Wire what feeds it into the step, and `<id>-ok` into the
|
|
391
|
+
first node that uses the answer.
|
|
392
|
+
- Put a **confirm** step (and an `e.body.proceed == true` predicate) before anything that writes, and make the
|
|
393
|
+
write read only the confirm step's `approvedValues`.
|
|
394
|
+
- Add `nondeterministic-output: acknowledged` (AWARE's marker; not consent), then check the workflow with
|
|
395
|
+
`agent-steps.check-source` before you call it ready.
|
|
396
|
+
- **The person confirms in FloLess's approval dialog; you never do.** Open it for them with `agent-steps.confirm`.
|
|
397
|
+
- Never describe such a workflow, or its output, as deterministic. `kb:` on a step is not supported yet.
|
|
398
|
+
|
|
368
399
|
## Consult and cite the project's knowledge at run time — retrieval only
|
|
369
400
|
|
|
370
401
|
Use `floless-workspace/read-knowledge` only when a run must retrieve a project's compiled knowledge
|
|
@@ -392,8 +423,9 @@ model.
|
|
|
392
423
|
matching the subject is legitimate retrieval, not an excuse to invent a citation; make the report
|
|
393
424
|
say so honestly.
|
|
394
425
|
|
|
395
|
-
Never add
|
|
396
|
-
|
|
426
|
+
Never add a model node, vector store, or KB-drift Run gate to this path. Interpretation belongs at
|
|
427
|
+
compose time; runtime knowledge may only be retrieved, cited, or deterministically gated. (An Agent step
|
|
428
|
+
may not reason over the knowledge base yet: `kb:` on a step is answered "not supported yet".)
|
|
397
429
|
|
|
398
430
|
## Author against the project's knowledge, not your priors — COMPOSE TIME
|
|
399
431
|
|
|
@@ -441,11 +473,12 @@ When work is tied to a Workspace project (the user names one, or a queued reques
|
|
|
441
473
|
user when they have diverged. Re-reading the feed to "pin the latest" would record a generation
|
|
442
474
|
whose contents never touched your work, which is the one failure this record exists to prevent.
|
|
443
475
|
|
|
444
|
-
Compose time only: what you learn is baked into the `.flo`.
|
|
445
|
-
AWARE (`E_APP_RUNTIME_MODEL_FORBIDDEN`)
|
|
446
|
-
curated
|
|
447
|
-
|
|
448
|
-
`references/visual-inputs.md
|
|
476
|
+
Compose time only: what you learn is baked into the `.flo`. An ordinary model node in the run path is
|
|
477
|
+
refused by AWARE (`E_APP_RUNTIME_MODEL_FORBIDDEN`). Two routes are admitted, and neither is a way to reach
|
|
478
|
+
knowledge at run time: the curated `vision.extract` (`category: curated`, declaring
|
|
479
|
+
`capabilities.runtime-model-extraction: true`; it extracts but never decides — see
|
|
480
|
+
`references/visual-inputs.md`), and a consented **Agent step** (see "Put a saved Agent in a workflow",
|
|
481
|
+
which cannot reason over the knowledge base yet). Nothing you author for knowledge belongs in either.
|
|
449
482
|
|
|
450
483
|
## How the UI surfaces map to AWARE state
|
|
451
484
|
|
|
@@ -590,6 +623,9 @@ past a few hard facts, split it into a `references/` file and link it.
|
|
|
590
623
|
Enforced by `npm run verify:flo` in CI. See "Every node's Description must be plain English".
|
|
591
624
|
- Determinism is AWARE's: `<app>.lock` is the approved artifact; Run is gated on a fresh
|
|
592
625
|
source-hash. Never let the UI run on drift.
|
|
626
|
+
- **A model reaches the run path only as an Agent step,** with the person's own confirmation that its
|
|
627
|
+
answer may differ each run. You never confirm for them, never add any other model node, and never call
|
|
628
|
+
such a workflow or its output deterministic. See `references/agent-steps.md`.
|
|
593
629
|
- **Never edit a MAINTAINED app's `.flo` in place.** A maintained app is FloLess-published
|
|
594
630
|
(`publisher: floless`) and not forked — it tracks our update channel and its output is our
|
|
595
631
|
responsibility. To run it across projects with different data, **Duplicate** it (stays maintained,
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
# Agent steps — putting a saved Agent in a workflow (AWARE 0.160.0+)
|
|
2
|
+
|
|
3
|
+
An **Agent step** runs one Agent the person saved on the Agents page as a step of a workflow. It is the
|
|
4
|
+
one place a model may reason while a workflow runs, and it is opt-in on both sides: AWARE runs it only
|
|
5
|
+
when the source carries the acknowledgement marker, and FloLess approves the workflow only after the
|
|
6
|
+
**person** ticks that its answer may differ each run.
|
|
7
|
+
|
|
8
|
+
Everything else in the workflow stays deterministic. The `.flo` → `.lock` gate still applies to the
|
|
9
|
+
whole workflow: the step and its instructions are pinned by the lock, and only the step's answer varies.
|
|
10
|
+
|
|
11
|
+
## When to use one, and when not
|
|
12
|
+
|
|
13
|
+
- **Use it** when the work genuinely needs judgement at run time: reading a free-text note and
|
|
14
|
+
classifying it, summarising what came back from a read, choosing between options a person described.
|
|
15
|
+
- **Do not use it** for anything a fixed rule can do. A filter, a threshold, a lookup, a format
|
|
16
|
+
conversion or a value you can read from the project's knowledge at compose time belongs in an
|
|
17
|
+
ordinary node, where it gives the same answer every run.
|
|
18
|
+
- **Never** put a model in a workflow any other way: no other agent or node that calls an LLM. The
|
|
19
|
+
Agent step is the only route, because it carries the person's consent, the labels and the run record.
|
|
20
|
+
|
|
21
|
+
## Build it
|
|
22
|
+
|
|
23
|
+
1. **Find the Agent.** List the Agents you can put in this workflow with the `agent-steps.agents`
|
|
24
|
+
action (name, id, which AI answers, revision — the same choice the canvas offers) and pick one by id.
|
|
25
|
+
(`agents.list` is the full workspace list; a chat working on one workflow is not given it.) If none fits, say so and offer to create one on the Agents page; do not invent one.
|
|
26
|
+
2. **Get the pinned step from FloLess, never type it.** Call the `agent-steps.block` action with the
|
|
27
|
+
Agent's id and, when you know them, the workflow id, a starting node id, one plain-English
|
|
28
|
+
description, the `context` template that feeds it (for example `{{ read-notes.result.text }}`),
|
|
29
|
+
the provider and the answer format (`{"format":"text"}` or `{"format":"json","fields":{…}}`).
|
|
30
|
+
It returns YAML with two parts:
|
|
31
|
+
- `nodes:` — the step itself (`agent: floless-agent-step`, `command: reason`) and its **`<id>-ok`**
|
|
32
|
+
predicate, which stops the run cleanly when the Agent could not answer;
|
|
33
|
+
- `connections:` — `<id>` → `<id>-ok`.
|
|
34
|
+
Copy both parts **byte for byte**. The pinned fields (instructions, agent id and revision, provider,
|
|
35
|
+
scope, output, limits) are what the lock approves; a retyped field is a different step.
|
|
36
|
+
3. **Wire it.** Add your own connections: the node that feeds the step → `<id>`, and `<id>-ok` → the
|
|
37
|
+
first node that uses the answer. Every node that uses the answer must come **after `<id>-ok`**, so it
|
|
38
|
+
never runs on a step that did not answer.
|
|
39
|
+
4. **Read the answer by its path.** A text answer is `{{ <id>.body.text }}`; a JSON answer's field is
|
|
40
|
+
`{{ <id>.body.answer.<field> }}`. Questions and assumptions the Agent raised are listed in the run
|
|
41
|
+
record for the person; do not try to act on them in the workflow.
|
|
42
|
+
5. **Hold every write behind a confirmation.** If anything after the step changes a model, a file or a
|
|
43
|
+
design program, put a **confirm** step before it: a `floless-agent-step` node with
|
|
44
|
+
`command: confirm`, whose body carries `run-id: "{{ run.id }}"`, `node-id` (its own id), a plain-English
|
|
45
|
+
`summary` of what will change, the `values` the write will use, and optional `timeout-minutes`. Follow it with a
|
|
46
|
+
predicate `e.body.proceed == true`, and make the write read **only** `{{ <confirm-id>.body.approvedValues… }}`.
|
|
47
|
+
No AI runs in a confirm step; a person approves exactly the values shown. An unattended run (a
|
|
48
|
+
routine) gets `proceed: false` at once, so the write is skipped and recorded as not made.
|
|
49
|
+
6. **Add the acknowledgement marker.** The top-level line `nondeterministic-output: acknowledged`
|
|
50
|
+
(the block helper also returns it). It is only the marker AWARE needs before it will install or
|
|
51
|
+
compile an Agent step, so you can author, install and compile freely. **It is not consent.**
|
|
52
|
+
7. **Write plain-English Descriptions** as for every node; the step's description says which Agent it
|
|
53
|
+
asks and that its answer is written by an AI and may differ each time.
|
|
54
|
+
8. **If the Agent should check against the project's Knowledge, pin a query, never browse.** Ask the
|
|
55
|
+
block helper with `kbQuery` (a few plain words to look for), and `kbProject` (a project id the Agent
|
|
56
|
+
reads; it defaults to the only one) and `kbMaxPages` (1 to 8, default 4) when needed. The step then
|
|
57
|
+
carries `kb: { project, q, max-pages }`. Before the Agent starts, **FloLess** reads the best-matching
|
|
58
|
+
pages of that project's published Knowledge and gives them to it as evidence; the Agent has no
|
|
59
|
+
Knowledge search of its own in a step, so do not tell it to look anything up. The pages it may cite
|
|
60
|
+
are only those; a citation outside them is dropped and becomes a question for the person. A JSON
|
|
61
|
+
answer then also has `{{ <id>.body.citations }}` (the slugs it says it used); a text answer ends with
|
|
62
|
+
a `Sources:` line. If the project has no published Knowledge, or nothing matches, the step still runs
|
|
63
|
+
and its answer says it rests on no Knowledge — if a missing standard must stop the run, gate on the
|
|
64
|
+
answer with a predicate. Changing the query is a change the person confirms again. Values you can
|
|
65
|
+
read from the Knowledge yourself at compose time still belong baked into ordinary nodes.
|
|
66
|
+
9. **Check before you say it is ready.** Call `agent-steps.check-source` with the workflow text (or
|
|
67
|
+
`agent-steps.check-workflow` once it is installed). It says whether each step still matches its saved
|
|
68
|
+
Agent: newer instructions, a deleted Agent, or a project the step can no longer read. Fix what it
|
|
69
|
+
reports by asking for a fresh block, never by editing pinned fields.
|
|
70
|
+
|
|
71
|
+
## The person confirms — never you
|
|
72
|
+
|
|
73
|
+
Before the workflow can be approved and run, the person ticks in FloLess's approval dialog that it has
|
|
74
|
+
an AI step whose answer may differ each run. They tick it again whenever an Agent step is added or its
|
|
75
|
+
instructions change. **You never give that confirmation and nothing in a chat can answer the dialog.**
|
|
76
|
+
Hand them the screen with the human-only `agent-steps.confirm` action, and say in plain words what they
|
|
77
|
+
are confirming.
|
|
78
|
+
|
|
79
|
+
## What the person sees
|
|
80
|
+
|
|
81
|
+
FloLess labels the workflow and its output wherever they show: the canvas (the step's **AI Agent step**
|
|
82
|
+
badge, and a quieter mark on nodes it found using or decided by the answer), Inspect, the execution
|
|
83
|
+
trace, the Last run panel, the report (an "AI-generated content" pill and a footer) and history rows.
|
|
84
|
+
The report's note is the person's to turn off, per workflow (the Agent step's Inspect panel) or for all
|
|
85
|
+
reports (the ≡ menu); FloLess's own screens stay labelled either way. Never turn it off for them.
|
|
86
|
+
Marks on other nodes are what FloLess *found*; it always says other steps may depend on the answer in
|
|
87
|
+
ways it cannot trace. Never describe the rest of such a workflow, or its output, as deterministic.
|
|
88
|
+
|
|
89
|
+
## Unattended runs
|
|
90
|
+
|
|
91
|
+
A routine cannot ask mid-run. An Agent step in an unattended run follows the safe default: it does the
|
|
92
|
+
work read-only, labels what rests on an assumption, and lists its questions for the person at the top of
|
|
93
|
+
the result. A confirm step in an unattended run never approves; the write is recorded as not made.
|
|
94
|
+
|
|
95
|
+
A workflow that **waits for a trigger** (a watcher: an On trigger routine, or ▶ Run on a watching workflow)
|
|
96
|
+
runs its Agent step **once for each event that reaches it**, unattended:
|
|
97
|
+
|
|
98
|
+
- **The person confirms it twice, in FloLess's own dialog.** Besides the usual tick, a second tick says the
|
|
99
|
+
AI step may run on its own each time the trigger fires, with the wait between answers they set there.
|
|
100
|
+
You never tick either for them and cannot: the chat can only open the workflow for them (`agent-steps.confirm`),
|
|
101
|
+
where they confirm it with Approve or ▶ Run.
|
|
102
|
+
- **Each step waits between answers**, 1 minute unless the person sets another wait or turns it off. An
|
|
103
|
+
event inside the wait skips the AI step: its `ok` is false with `reason: cooldown`, so the steps behind
|
|
104
|
+
its `-ok` check do not run for that event, and the skip is listed for the person. Do not work around it.
|
|
105
|
+
You may make the wait LONGER (`agent-steps.lengthen-trigger-wait`); a shorter wait or none lets the AI
|
|
106
|
+
run more often and only the person can set it: open the workflow for them (`agent-steps.confirm`) and tell
|
|
107
|
+
them to select the AI step and use **Change** under *When the trigger fires* in Inspect, which asks them to confirm.
|
|
108
|
+
- **Every change behind a confirm step is held** in a saved watcher (nobody is watching it). In a live run
|
|
109
|
+
a person started with Run, the change card shows only while they have the live run on screen.
|
|
110
|
+
- **What happened for each event** is listed per event (`agent-steps.trigger-history`): answered, skipped
|
|
111
|
+
because of the wait, not answered, and the questions and held changes waiting for the person. Read it
|
|
112
|
+
when the person asks what the watcher did; never claim an event was answered without it.
|
|
113
|
+
- Watchers' AI steps share the AI conversations with the person's own Agents and use at most 2 of the 4
|
|
114
|
+
at once, so an event can wait its turn and end as "did not answer in time". That is expected, not a fault.
|
|
115
|
+
|
|
116
|
+
## Not supported yet
|
|
117
|
+
|
|
118
|
+
- On an AWARE older than 0.160.0 the step cannot run and FloLess hides the controls; say so and suggest
|
|
119
|
+
updating AWARE rather than working around it.
|