Skip to content

Commit a2e0f12

Browse files
committed
2026-06-06-ai-user-doc-updates Add AI risk guidance and script execution page
1 parent b94e83e commit a2e0f12

10 files changed

Lines changed: 327 additions & 41 deletions

post.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Preview: AI prompts, formulas, scripts, and MCP updates in Freeplane 1.13.3
2+
3+
We have a preview build of Freeplane `1.13.3` with a broader set of AI
4+
features and updated documentation.
5+
6+
Highlights in this preview:
7+
8+
- reusable AI prompts and assistant profiles,
9+
- prompt-specific optional model and tool settings,
10+
- AI attachment for the Formula Editor and Script Editor,
11+
- optional AI repair after formula execution failure,
12+
- a separate `AI may edit formulas` permission,
13+
- a separate explanation of AI-owned script execution and its risks,
14+
- a clearer `AI-owned script execution policy`,
15+
- improved MCP behavior and MCP visibility in AI chat,
16+
- Groovy scripts that can ask AI asynchronously,
17+
- the `Block formula map edits` safeguard.
18+
19+
The documentation now covers these areas in more detail, including the
20+
permissions each feature needs and the risks and benefits of enabling
21+
it.
22+
23+
Important risk notes:
24+
25+
- AI output can be wrong.
26+
- Prompt injection through mind map content or scripts cannot be fully
27+
excluded.
28+
- AI-generated formulas and especially AI-generated scripts should be
29+
reviewed carefully.
30+
- Allowing AI to run scripts without user review is materially riskier
31+
than shown-mode review.
32+
- Freeplane's MCP server listens only on `127.0.0.1` by default, so it
33+
is not remotely reachable by itself. It becomes externally reachable
34+
only if separate forwarding or proxy software exposes that local
35+
port.
36+
- Even then, connected MCP clients may themselves send map content or
37+
results to external AI services.
38+
39+
If you test this preview, feedback on both usability and safety wording
40+
would be especially useful.

src/docs/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
- [AI chat workflows](ai/ai-chat-workflows.md)
1313
- [AI prompts and profiles](ai/ai-prompts-and-profiles.md)
1414
- [AI formulas and script editing](ai/ai-formulas-and-script-editing.md)
15+
- [AI-owned script execution](ai/ai-owned-script-execution.md)
1516
- [Model Context Protocol server](ai/model-context-protocol-server.md)
1617
- [AI integration troubleshooting](ai/ai-integration-troubleshooting.md)
1718
- [User documentation](user-documentation/user-documentation.md)

src/docs/ai/ai-chat-workflows.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,21 @@
33
This page focuses on practical ways to get useful results from AI in
44
everyday map work.
55

6+
## Benefits and risks
7+
8+
Benefits:
9+
10+
- workflow patterns can make repeated map tasks faster and more
11+
consistent,
12+
- profiles and prompts reduce repeated setup work.
13+
14+
Risks:
15+
16+
- AI suggestions can still be wrong,
17+
- hidden prompt runs reduce visibility,
18+
- tool-call summaries help review what happened, but they do not prove
19+
that the result is correct or safe.
20+
621
## Use profiles and prompts for repeatable work
722

823
- Use `Manage profiles` when you want reusable chat behavior across many

src/docs/ai/ai-formulas-and-script-editing.md

Lines changed: 38 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,21 @@
11
## AI formulas and script editing
22

33
The features on this page require Freeplane `1.13.3` or later.
4-
Each section below repeats the settings it needs.
4+
The feature sections below repeat the settings they need.
5+
6+
## Benefits and risks
7+
8+
Benefits:
9+
10+
- AI can draft, explain, and repair formulas and scripts faster,
11+
- editor attachment lets AI work with the live text you are currently
12+
editing.
13+
14+
Risks:
15+
16+
- formulas and scripts can be wrong or unsafe,
17+
- models make mistakes, and prompt injection through map content or
18+
scripts cannot be fully excluded.
519

620
## Formula editing and execution with AI
721

@@ -10,6 +24,11 @@ To use this:
1024
- `AI tool availability` must include `Editing` or `Script execution`.
1125
- `AI may edit formulas` must be enabled.
1226

27+
Benefit: AI can help draft and repair formulas faster.
28+
29+
Risk: review any generated formula before submitting it, especially if
30+
it refers to other nodes or searches the map.
31+
1332
`Formula Editor` can be attached to AI through its local `AI` button.
1433

1534
When you attach the editor, AI works with the **live text currently
@@ -49,6 +68,11 @@ repair, see [Formulas](../scripting/Formulas.md).
4968
No AI permission is needed for this safeguard itself. It is a
5069
formula-plugin preference and applies to all formulas.
5170

71+
Benefit: this blocks one important class of formula side effects.
72+
73+
Risk: if you disable it, formula evaluation can perform map edits when
74+
the formula text does that.
75+
5276
The formula-plugin preference `Block formula map edits` is enabled by
5377
default.
5478

@@ -66,6 +90,16 @@ To use this:
6690

6791
- `AI tool availability` must include `Script execution`.
6892

93+
Benefit: AI can help draft, explain, and refactor Groovy scripts
94+
faster.
95+
96+
Risk: AI-generated code is untrusted code and should be reviewed before
97+
running it.
98+
99+
This attached editor flow helps AI edit the current script draft. For
100+
execution of AI-owned scripts, see
101+
[AI-owned script execution](ai-owned-script-execution.md).
102+
69103
`Edit script` can be attached to AI through its local `AI` button.
70104

71105
When you attach the editor, AI works with the **live text currently
@@ -75,33 +109,6 @@ open in that editor**, not only with already-saved map content.
75109

76110
*Script Editor with the local AI attach button.*
77111

78-
## AI-owned script execution policy
79-
80-
This section matters only when `AI tool availability` includes `Script
81-
execution`.
82-
83-
`AI-owned script execution policy` controls how AI-created scripts are
84-
run:
85-
86-
- `Shown, user must press Run`
87-
- `Hidden, AI may run directly`
88-
89-
In shown mode, Freeplane opens a review dialog so you can inspect the
90-
script before running it.
91-
92-
If you want AI to run the script directly, this policy must be `Hidden,
93-
AI may run directly`.
94-
The separate `AI-owned dialog Run permissions` setting controls which
95-
external permissions a user-started `Run` from that dialog uses.
96-
97-
![AI-owned script review dialog](../images/ai-owned-script-review-dialog.png)
98-
99-
*Shown mode is a review gate. The dialog is for script inspection and
100-
Run/Cancel only.*
101-
102-
The shown dialog is not a results window. If you later see a popup with
103-
script output, that popup usually comes from the script itself.
104-
105112
## Prefer value-computing formulas and scripts
106113

107114
This guidance still applies when the relevant permissions are enabled.
@@ -123,10 +130,12 @@ If you want most features on this page, a good default configuration is:
123130

124131
- `AI tool availability`: `Editing` or `Script execution`
125132
- `AI may edit formulas`: enabled if you want AI to help with formulas
126-
- `AI-owned script execution policy`: `Shown, user must press Run`
127133
- `AI chat shows tool calls`: enabled if you want visible AI/MCP tool
128134
activity in chat
129135

136+
For AI-owned script execution settings, see
137+
[AI-owned script execution](ai-owned-script-execution.md).
138+
130139
The preferences page below shows the main settings involved in these
131140
workflows.
132141

src/docs/ai/ai-integration-getting-started.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,28 @@ The newer features linked from this page — prompts, editor attachment,
66
AI-owned script review, formula-editing controls, and script-facing AI
77
requests — require Freeplane `1.13.3` or later.
88

9+
## Benefits and risks
10+
11+
Benefits:
12+
13+
- AI can summarize, rewrite, inspect, and help edit map content faster.
14+
- Prompts, profiles, formulas, and scripts can make repeated tasks
15+
easier.
16+
17+
Risks:
18+
19+
- Depending on your provider and setup, map content sent to AI may
20+
leave your machine.
21+
- Model output can be wrong, misleading, or influenced by map content.
22+
- Higher-permission features such as editing, formula authoring,
23+
script execution, and MCP increase risk and should be enabled
24+
deliberately.
25+
26+
For the higher-risk features, read
27+
[AI formulas and script editing](ai-formulas-and-script-editing.md)
28+
and [Model Context Protocol server](model-context-protocol-server.md)
29+
before enabling them.
30+
931
### Configure AI in Preferences
1032

1133
Open AI Preferences from the AI panel toolbar burger menu, then
@@ -48,7 +70,7 @@ The following settings matter for most current AI workflows:
4870
availability is high enough
4971
- `AI-owned script execution policy`
5072
- controls whether AI-owned scripts are shown for review or may run
51-
directly
73+
directly without user review
5274
- `AI chat shows tool calls`
5375
- shows AI and MCP tool activity in chat
5476

@@ -74,8 +96,10 @@ Helpful chat controls:
7496
[AI chat workflows](ai-chat-workflows.md).
7597
- Learn how prompts and profiles differ in
7698
[AI prompts and profiles](ai-prompts-and-profiles.md).
77-
- Learn about editor attachment, formulas, and script review in
99+
- Learn about editor attachment, formulas, and script editing in
78100
[AI formulas and script editing](ai-formulas-and-script-editing.md).
101+
- Learn about direct AI-owned script execution in
102+
[AI-owned script execution](ai-owned-script-execution.md).
79103
- For remote tool access, see
80104
[Model Context Protocol server](model-context-protocol-server.md).
81105
MCP is disabled by default and should be enabled only when needed,

src/docs/ai/ai-integration-troubleshooting.md

Lines changed: 25 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## AI integration troubleshooting
22

3-
### Start here
3+
## Start here
44

55
If AI does not respond as expected, open AI Preferences (from the AI
66
panel burger menu) and check:
@@ -15,7 +15,20 @@ panel burger menu) and check:
1515
For prompts, editor attachment, AI-owned script review, and formula
1616
editing features, use Freeplane `1.13.3` or later.
1717

18-
### Messages you may see
18+
## Benefits and risks
19+
20+
Benefits:
21+
22+
- this page helps you diagnose configuration and permission problems,
23+
- it can help you avoid enabling stronger AI features by guesswork.
24+
25+
Risks:
26+
27+
- some fixes involve enabling stronger permissions,
28+
- when a fix requires editing, formula authoring, script execution, or
29+
MCP, re-read the corresponding feature page before enabling it.
30+
31+
## Messages you may see
1932

2033
- `No AI provider is configured.`
2134
- Required provider settings are missing.
@@ -33,7 +46,7 @@ editing features, use Freeplane `1.13.3` or later.
3346
- `Unknown AI provider selection.`
3447
- Re-check provider settings in Preferences.
3548

36-
### Prompts and profiles
49+
## Prompts and profiles
3750

3851
If you cannot find saved prompts or assistant profiles:
3952

@@ -48,7 +61,7 @@ If prompts do not behave like normal chat, that may be expected:
4861
- shown prompts open their own chat,
4962
- hidden prompts do not stay as visible saved chats.
5063

51-
### Formula editing is missing or not offered
64+
## Formula editing is missing or not offered
5265

5366
If AI does not offer formula editing:
5467

@@ -57,10 +70,12 @@ If AI does not offer formula editing:
5770

5871
Formula editing is gated separately from ordinary AI editing.
5972

60-
### AI-owned script review behaves differently than expected
73+
## AI-owned script review behaves differently than expected
6174

6275
If an AI-owned script waits for you instead of running immediately,
6376
check `AI-owned script execution policy`.
77+
For the full behavior and risk model, see
78+
[AI-owned script execution](ai-owned-script-execution.md).
6479

6580
- `Shown, user must press Run`
6681
- opens the review dialog and waits for your decision.
@@ -71,7 +86,7 @@ If you see a popup with a script result, that popup may have been
7186
created by the script itself rather than by the AI-owned review dialog.
7287
Prefer `return` or `println` in scripts when you do not want UI popups.
7388

74-
### Formula execution fails while editing
89+
## Formula execution fails while editing
7590

7691
If formula execution fails with a message about blocked execute calls,
7792
check the formula-plugin setting `Block formula map edits`.
@@ -82,7 +97,7 @@ validation can fail by design.
8297
This is especially relevant if a formula tries to create nodes or make
8398
other map changes.
8499

85-
### Editor attachment and AI repair
100+
## Editor attachment and AI repair
86101

87102
If the `AI` button in `Formula Editor` or `Edit script` does not behave
88103
as expected:
@@ -92,7 +107,7 @@ as expected:
92107
- if formula repair is offered after an execution failure, remember that
93108
the repair request is optional and starts only if you choose it.
94109

95-
### MCP not working
110+
## MCP not working
96111

97112
If another local AI app cannot use Freeplane through MCP:
98113

@@ -115,12 +130,12 @@ Also remember that some MCP-assisted editing features depend on the
115130
current AI settings. If formula-related editing is missing, re-check
116131
`AI tool availability` and `AI may edit formulas`.
117132

118-
### Scripts asking AI
133+
## Scripts asking AI
119134

120135
If you are troubleshooting Groovy scripts that call AI, see
121136
[Asking AI from scripts](../scripting/Asking_AI_from_scripts.md).
122137

123-
### Quick success checklist
138+
## Quick success checklist
124139

125140
Use this after changes or upgrades:
126141

0 commit comments

Comments
 (0)