Skip to content

Replace the elicitation path with a plain Petrinaut-to-Flue chat. - #9382

Open
lunelson wants to merge 6 commits into
ln/fe-1521-machete-protocolfrom
ln/fe-1522-mission-1
Open

Replace the elicitation path with a plain Petrinaut-to-Flue chat.#9382
lunelson wants to merge 6 commits into
ln/fe-1521-machete-protocolfrom
ln/fe-1522-mission-1

Conversation

@lunelson

Copy link
Copy Markdown
Contributor

🌟 What is the purpose of this PR?

🔗 Related links

  • ...

🚫 Blocked by

  • ...

🔍 What does this change?

  • ...

Pre-Merge Checklist 🚀

🚢 Has this modified a publishable library?

This PR:

  • does not modify any publishable blocks or libraries, or modifications do not need publishing
  • modifies an npm-publishable library and I have added a changeset file(s)
  • modifies a Cargo-publishable library and I have amended the version
  • modifies a Cargo-publishable library, but it is not yet ready to publish
  • modifies a block that will need publishing via GitHub action once merged
  • I am unsure / need advice

📜 Does this require a change to the docs?

The changes in this PR:

  • are internal and do not require a docs change
  • are in a state where docs changes are not yet required but will be
  • require changes to docs which are made as part of this PR
  • require changes to docs which are not made in this PR
    • Provide more detail here
  • I am unsure / need advice

🕸️ Does this require a change to the Turbo Graph?

The changes in this PR:

  • do not affect the execution graph
  • affected the execution graph, and the turbo.json's have been updated to reflect this
  • I am unsure / need advice

⚠️ Known issues

🐾 Next steps

🛡 What tests cover this?

❓ How to test this?

  1. Checkout the branch / view the deployment
  2. Try X
  3. Confirm that Y

📹 Demo

@vercel

vercel Bot commented Aug 27, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hash Ready Ready Preview Aug 27, 2026 5:56pm
petrinaut Ready Ready Preview Aug 27, 2026 5:56pm
petrinaut-docs Ready Ready Preview Aug 27, 2026 5:56pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
hashdotdesign-tokens Ignored Ignored Preview Aug 27, 2026 5:56pm

Request Review

@github-actions github-actions Bot added area/deps Relates to third-party dependencies (area) area/infra Relates to version control, CI, CD or IaC (area) area/libs Relates to first-party libraries/crates/packages (area) type/eng > frontend Owned by the @frontend team area/tests New or updated tests area/apps labels Aug 27, 2026

lunelson commented Aug 27, 2026

Copy link
Copy Markdown
Contributor Author

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@lunelson
lunelson deployed to pull-request August 27, 2026 15:56 — with GitHub Actions Active
@lunelson
lunelson deployed to pull-request August 27, 2026 15:56 — with GitHub Actions Active
@lunelson
lunelson marked this pull request as ready for review August 27, 2026 15:57
@lunelson
lunelson marked this pull request as draft August 27, 2026 15:57
@lunelson
lunelson marked this pull request as ready for review August 27, 2026 15:57
@cursor

cursor Bot commented Aug 27, 2026

Copy link
Copy Markdown

PR Summary

Medium Risk
Rewrites the production chat door, Flue route authorization, and persistence model while removing elicitation; new ownership checks are covered by tests but the surface area is still broad.

Overview
Replaces the SDCPN/Gherkin elicitation harness on the Petrinaut panel with a single plain Flue ChatAgent (ping server tool + browser readPetrinautDoc), wired through /api/chat with AI SDK streaming, GET history hydration, and client-tool resume via Flue signals—no brunch_ask, capture store, or target-document persistence on this path.

Conversation identity is now principal + panel conversation id → SHA-256 Flue instance id, with agentOwnershipGuard on /agents/chat/:id so the path id is not a bearer token. New flue-ui-stream / flue-transcript bridge Flue chunks and history() to AI SDK messages; a transcript CLI prints the same log.

Dependencies and tests drop @hashintel/brunch-agent core, binding-flue, and plugins; the app depends on @hashintel/petrinaut-core for doc tool catalogs. Large elicitation suites (baseline harness, walking skeleton, ask integration) are removed in favor of chat-path integration tests.

Petrinaut local demo pins a stable conversation id per net, hydrates from GET /api/chat, removes the Brunch ask widget and sweep stream decoration, and documents the voice dock as sharing the same POST contract. Lint/docs/README and dev:brunch now build Petrinaut libs first; Brunch MISSION.md advances to Mission 2 (mechanical capture sweep) with MISSION.next.md scratchpad guidance in AGENTS.md.

Reviewed by Cursor Bugbot for commit 00e16a5. Bugbot is set up for automated code reviews on this repo. Configure here.

? flueHistory.messages
: currentNetId
? aiMessagesByNetId[currentNetId]
: undefined,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Flue history never hydrates the panel

High Severity

GET /api/chat history is applied by swapping aiAssistant.messages after mount, but Petrinaut's useChat only reads that prop as initial state. The panel therefore keeps the first paint's localStorage (or empty) transcript and never reconciles to Flue, so reload and cross-client turns do not reconstruct the conversation from server history.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 7d400c4. Configure here.

});
},
}),
[aiMessagesByNetId, currentNetId, setAiMessagesByNetId],

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clear chat keeps the Flue conversation

High Severity

Clearing the assistant only deletes the localStorage cache. The per-net conversationId is unchanged, so the next send still targets the same Flue instance. The model continues the old thread even though the panel looks empty, and a later successful history load would restore the wiped transcript.

Additional Locations (2)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 7d400c4. Configure here.

return { messages: [] };
}
return { messages: snapshotToUiMessages(snapshot) };
};

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

History failures look like empty chats

Medium Severity

loadHistory catches every history() failure and returns HTTP 200 with messages: []. The panel treats a successful GET as authoritative Flue state, so a missing instance, timeout, or Flue error is indistinguishable from a brand-new conversation and can wipe the visible transcript.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 7d400c4. Configure here.

@codspeed-hq

codspeed-hq Bot commented Aug 27, 2026

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 98 untouched benchmarks


Comparing ln/fe-1522-mission-1 (00e16a5) with main (3b2d8e3)1

Open in CodSpeed

Footnotes

  1. No successful run was found on ln/fe-1521-machete-protocol (b06ac00) during the generation of this report, so main (3b2d8e3) was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

@github-actions

Copy link
Copy Markdown
Contributor

Benchmark results

@rust/hash-graph-benches – Integrations

policy_resolution_large

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 2002 $$26.9 \mathrm{ms} \pm 207 \mathrm{μs}\left({\color{gray}-3.041 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$3.45 \mathrm{ms} \pm 27.1 \mathrm{μs}\left({\color{gray}-1.786 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 1002 $$12.3 \mathrm{ms} \pm 116 \mathrm{μs}\left({\color{gray}-0.596 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 3314 $$42.9 \mathrm{ms} \pm 425 \mathrm{μs}\left({\color{gray}-0.841 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$14.1 \mathrm{ms} \pm 134 \mathrm{μs}\left({\color{gray}-4.815 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 1527 $$23.7 \mathrm{ms} \pm 253 \mathrm{μs}\left({\color{gray}-0.731 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 2078 $$28.5 \mathrm{ms} \pm 269 \mathrm{μs}\left({\color{gray}0.365 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$3.76 \mathrm{ms} \pm 22.6 \mathrm{μs}\left({\color{gray}-2.410 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 1033 $$13.4 \mathrm{ms} \pm 146 \mathrm{μs}\left({\color{gray}0.213 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_medium

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 102 $$3.84 \mathrm{ms} \pm 30.5 \mathrm{μs}\left({\color{gray}0.239 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$3.00 \mathrm{ms} \pm 21.6 \mathrm{μs}\left({\color{gray}-0.082 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 52 $$3.37 \mathrm{ms} \pm 25.6 \mathrm{μs}\left({\color{gray}-0.923 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 269 $$5.19 \mathrm{ms} \pm 39.7 \mathrm{μs}\left({\color{gray}-1.090 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$3.54 \mathrm{ms} \pm 23.4 \mathrm{μs}\left({\color{gray}-0.562 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 108 $$4.15 \mathrm{ms} \pm 37.6 \mathrm{μs}\left({\color{gray}-1.056 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 133 $$4.41 \mathrm{ms} \pm 28.0 \mathrm{μs}\left({\color{gray}-1.793 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$3.49 \mathrm{ms} \pm 23.0 \mathrm{μs}\left({\color{gray}0.533 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 63 $$4.09 \mathrm{ms} \pm 27.8 \mathrm{μs}\left({\color{gray}-0.703 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_none

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 2 $$2.69 \mathrm{ms} \pm 22.1 \mathrm{μs}\left({\color{gray}3.15 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.54 \mathrm{ms} \pm 16.8 \mathrm{μs}\left({\color{gray}0.431 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 2 $$2.66 \mathrm{ms} \pm 15.4 \mathrm{μs}\left({\color{gray}2.86 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 8 $$2.94 \mathrm{ms} \pm 17.4 \mathrm{μs}\left({\color{gray}1.99 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.74 \mathrm{ms} \pm 16.8 \mathrm{μs}\left({\color{gray}3.91 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 3 $$2.98 \mathrm{ms} \pm 31.9 \mathrm{μs}\left({\color{gray}4.56 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_small

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 52 $$3.06 \mathrm{ms} \pm 26.6 \mathrm{μs}\left({\color{gray}0.340 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.76 \mathrm{ms} \pm 18.7 \mathrm{μs}\left({\color{gray}1.15 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 26 $$3.00 \mathrm{ms} \pm 23.2 \mathrm{μs}\left({\color{gray}2.00 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 94 $$3.46 \mathrm{ms} \pm 25.1 \mathrm{μs}\left({\color{gray}-0.095 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$3.02 \mathrm{ms} \pm 28.1 \mathrm{μs}\left({\color{gray}2.21 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 27 $$3.32 \mathrm{ms} \pm 28.1 \mathrm{μs}\left({\color{gray}2.31 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 66 $$3.39 \mathrm{ms} \pm 31.1 \mathrm{μs}\left({\color{gray}0.451 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.96 \mathrm{ms} \pm 25.3 \mathrm{μs}\left({\color{gray}-0.028 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 29 $$3.35 \mathrm{ms} \pm 25.8 \mathrm{μs}\left({\color{gray}1.95 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_complete

Function Value Mean Flame graphs
entity_by_id;one_depth 1 entities $$41.1 \mathrm{ms} \pm 241 \mathrm{μs}\left({\color{gray}-0.752 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 10 entities $$31.8 \mathrm{ms} \pm 236 \mathrm{μs}\left({\color{gray}-2.038 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 25 entities $$34.2 \mathrm{ms} \pm 324 \mathrm{μs}\left({\color{gray}-0.410 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 5 entities $$31.2 \mathrm{ms} \pm 278 \mathrm{μs}\left({\color{gray}-0.960 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 50 entities $$40.6 \mathrm{ms} \pm 243 \mathrm{μs}\left({\color{gray}-4.204 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 1 entities $$48.9 \mathrm{ms} \pm 304 \mathrm{μs}\left({\color{gray}-0.017 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 10 entities $$39.2 \mathrm{ms} \pm 271 \mathrm{μs}\left({\color{gray}0.012 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 25 entities $$89.6 \mathrm{ms} \pm 752 \mathrm{μs}\left({\color{gray}-1.023 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 5 entities $$32.8 \mathrm{ms} \pm 215 \mathrm{μs}\left({\color{gray}-0.452 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 50 entities $$305 \mathrm{ms} \pm 1.60 \mathrm{ms}\left({\color{red}9.64 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 1 entities $$10.4 \mathrm{ms} \pm 91.9 \mathrm{μs}\left({\color{gray}0.382 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 10 entities $$10.5 \mathrm{ms} \pm 70.8 \mathrm{μs}\left({\color{gray}-0.605 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 25 entities $$10.4 \mathrm{ms} \pm 92.5 \mathrm{μs}\left({\color{gray}0.360 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 5 entities $$10.4 \mathrm{ms} \pm 82.1 \mathrm{μs}\left({\color{gray}-0.822 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 50 entities $$10.4 \mathrm{ms} \pm 74.2 \mathrm{μs}\left({\color{gray}-0.084 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_linkless

Function Value Mean Flame graphs
entity_by_id 1 entities $$10.4 \mathrm{ms} \pm 68.1 \mathrm{μs}\left({\color{gray}-0.349 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10 entities $$10.5 \mathrm{ms} \pm 78.0 \mathrm{μs}\left({\color{gray}0.083 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 100 entities $$10.5 \mathrm{ms} \pm 67.4 \mathrm{μs}\left({\color{gray}-0.689 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 1000 entities $$10.5 \mathrm{ms} \pm 79.6 \mathrm{μs}\left({\color{gray}-0.159 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10000 entities $$10.5 \mathrm{ms} \pm 66.0 \mathrm{μs}\left({\color{gray}-1.583 \mathrm{\%}}\right) $$ Flame Graph

representative_read_entity

Function Value Mean Flame graphs
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/block/v/1 $$10.8 \mathrm{ms} \pm 65.5 \mathrm{μs}\left({\color{gray}-2.871 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/book/v/1 $$10.8 \mathrm{ms} \pm 60.0 \mathrm{μs}\left({\color{gray}-2.435 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/building/v/1 $$10.9 \mathrm{ms} \pm 69.5 \mathrm{μs}\left({\color{gray}-0.609 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/organization/v/1 $$10.9 \mathrm{ms} \pm 70.8 \mathrm{μs}\left({\color{gray}0.486 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/page/v/2 $$10.7 \mathrm{ms} \pm 58.5 \mathrm{μs}\left({\color{gray}-0.668 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/person/v/1 $$11.2 \mathrm{ms} \pm 101 \mathrm{μs}\left({\color{gray}1.03 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/playlist/v/1 $$10.7 \mathrm{ms} \pm 60.4 \mathrm{μs}\left({\color{gray}-1.364 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/song/v/1 $$10.7 \mathrm{ms} \pm 68.9 \mathrm{μs}\left({\color{gray}-1.785 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/uk-address/v/1 $$10.8 \mathrm{ms} \pm 74.0 \mathrm{μs}\left({\color{gray}-1.213 \mathrm{\%}}\right) $$ Flame Graph

representative_read_entity_type

Function Value Mean Flame graphs
get_entity_type_by_id Account ID: bf5a9ef5-dc3b-43cf-a291-6210c0321eba $$8.05 \mathrm{ms} \pm 49.7 \mathrm{μs}\left({\color{gray}-0.928 \mathrm{\%}}\right) $$ Flame Graph

representative_read_multiple_entities

Function Value Mean Flame graphs
entity_by_property traversal_paths=0 0 $$56.2 \mathrm{ms} \pm 486 \mathrm{μs}\left({\color{gray}1.85 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=255 1,resolve_depths=inherit:1;values:255;properties:255;links:127;link_dests:126;type:true $$109 \mathrm{ms} \pm 640 \mathrm{μs}\left({\color{gray}1.09 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:0;link_dests:0;type:false $$63.5 \mathrm{ms} \pm 501 \mathrm{μs}\left({\color{gray}-0.414 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:1;link_dests:0;type:true $$73.5 \mathrm{ms} \pm 509 \mathrm{μs}\left({\color{gray}-1.003 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:2;links:1;link_dests:0;type:true $$82.7 \mathrm{ms} \pm 622 \mathrm{μs}\left({\color{gray}0.839 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:2;properties:2;links:1;link_dests:0;type:true $$87.7 \mathrm{ms} \pm 538 \mathrm{μs}\left({\color{gray}0.436 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=0 0 $$41.7 \mathrm{ms} \pm 310 \mathrm{μs}\left({\color{gray}-0.257 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=255 1,resolve_depths=inherit:1;values:255;properties:255;links:127;link_dests:126;type:true $$70.9 \mathrm{ms} \pm 551 \mathrm{μs}\left({\color{gray}-0.282 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:0;link_dests:0;type:false $$48.0 \mathrm{ms} \pm 392 \mathrm{μs}\left({\color{gray}0.065 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:1;link_dests:0;type:true $$57.3 \mathrm{ms} \pm 400 \mathrm{μs}\left({\color{gray}0.032 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:2;links:1;link_dests:0;type:true $$59.7 \mathrm{ms} \pm 396 \mathrm{μs}\left({\color{gray}0.385 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:2;properties:2;links:1;link_dests:0;type:true $$59.6 \mathrm{ms} \pm 464 \mathrm{μs}\left({\color{gray}0.015 \mathrm{\%}}\right) $$

scenarios

Function Value Mean Flame graphs
full_test query-limited $$127 \mathrm{ms} \pm 694 \mathrm{μs}\left({\color{red}5.21 \mathrm{\%}}\right) $$ Flame Graph
full_test query-unlimited $$137 \mathrm{ms} \pm 688 \mathrm{μs}\left({\color{gray}3.13 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-limited $$18.3 \mathrm{ms} \pm 176 \mathrm{μs}\left({\color{lightgreen}-17.290 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-unlimited $$522 \mathrm{ms} \pm 1.23 \mathrm{ms}\left({\color{gray}-3.375 \mathrm{\%}}\right) $$ Flame Graph

lunelson and others added 6 commits August 27, 2026 19:41
Mission 1 needs a durable conversation through the real panel before capture lands, so /api/chat now mounts one Flue agent with a server tool, a read-only client-tool resume, and Flue history as the log.

Co-authored-by: Cursor <cursoragent@cursor.com>
…ries.

The agent module stays a thin hook composition; skills, subagents, and channels sit empty until they are used.

Co-authored-by: Cursor <cursoragent@cursor.com>
…uth.

The Flue tool now shares petrinaut-core's catalog instead of a free string, and yarn dev:brunch builds the panel's workspace libraries first.

Co-authored-by: Cursor <cursoragent@cursor.com>
… them.

The conversation projector now maps data-part and message-metadata, fails compilation on new Flue chunk types, and keeps the same parts in history reconstruction.

Co-authored-by: Cursor <cursoragent@cursor.com>
The mounted agent URL is no longer a capability hash; later concerns move to the mission scratchpad so Mission 1 stays the only execution authority.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@lunelson
lunelson force-pushed the ln/fe-1521-machete-protocol branch from 69dac29 to b06ac00 Compare August 27, 2026 17:42

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

There are 5 total unresolved issues (including 3 from previous reviews).

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 00e16a5. Configure here.

return part.output;
}
return clientOutput;
};

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pending client tools hydrate as complete

Medium Severity

When a client tool is still awaiting a browser result, resolveToolOutput falls back to the { awaiting: "client" } sentinel and toolPartFrom emits output-available. Reload hydration then looks like the tool already finished, so the panel will not re-run it or POST a client-tool-result, and that Flue turn stays blocked.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 00e16a5. Configure here.

},
},
write,
);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns drop the idempotency key

Medium Severity

runUserTurn and runClientToolResume hash identity and dispatch the text or signal, but they never forward idempotencyKey. The previous elicitor path passed that key into agent.dispatch, and the transport still computes it. Retried POSTs can therefore run the same Flue turn twice.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 00e16a5. Configure here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/apps area/deps Relates to third-party dependencies (area) area/infra Relates to version control, CI, CD or IaC (area) area/libs Relates to first-party libraries/crates/packages (area) area/tests New or updated tests type/eng > frontend Owned by the @frontend team

Development

Successfully merging this pull request may close these issues.

1 participant