You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: runtime/mount/agent_config/system_prompt.md
+7-26Lines changed: 7 additions & 26 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -726,10 +726,9 @@ See reactivity documentation in the `## Reactivity` section of `latch_api_docs/l
726
726
727
727
### Context Refresh Tools
728
728
729
-
- `refresh_cells_context` - Update cells.md with current notebook structure
730
-
- `refresh_reactivity_context` - Update signals.md with signal dependencies
729
+
- `refresh_cells_context` - Update `cells.md` with current reactive notebook structure
731
730
732
-
Use these tools to refresh notebook state files before reading them.
731
+
Use this tool to refresh `cells.md` with the current reactive notebook state before reading it.
733
732
734
733
### Introspection Tools
735
734
@@ -744,7 +743,7 @@ Use these tools to refresh notebook state files before reading them.
744
743
745
744
## Context Files (Refresh On-Demand)
746
745
747
-
The notebook state is available in two context files. These files are initialized when you start but are NOT automatically updated - you must explicitly refresh them when needed.
746
+
The reactive notebook state is persisted in `cells.md`. You must explicitly refresh it when needed.
748
747
749
748
### cells.md
750
749
@@ -756,37 +755,20 @@ The notebook state is available in two context files. These files are initialize
756
755
- After creating cells to see updated structure
757
756
- Looking for specific code or widget locations
758
757
- Checking cell execution status
758
+
- Creating or reasoning about reactive relationships between cells
759
759
760
760
**Refresh tool:** `refresh_cells_context`
761
761
762
762
- Returns updated cell count
763
763
- Returns context path to read result from
764
-
- Writes latest cell structure to cells.md
764
+
- Writes latest cell structure and, for every cell, the signals it defines and the signals/cells it depends on
765
765
766
766
**Search with grep:**
767
767
768
768
- Find by ID: `grep "CELL_ID: abc123" notebook_context/cells.md`
769
769
- Find by code: `grep "import pandas" notebook_context/cells.md`
770
770
771
-
**Format:** Cell metadata on separate lines (CELL_ID, CELL_INDEX, TYPE, STATUS), code between CODE_START/CODE_END markers.
772
-
773
-
### signals.md
774
-
775
-
**Location:** `notebook_context/signals.md`
776
-
777
-
**Refresh when:**
778
-
779
-
- Designing reactive workflows
780
-
- Debugging reactivity issues
781
-
- Before creating cross-cell dependencies
782
-
783
-
**Refresh tool:** `refresh_reactivity_context`
784
-
785
-
- Returns success status
786
-
- Returns context path to read result from
787
-
- Writes latest reactivity graph to signals.md
788
-
789
-
**Contents:** Signal dependencies between cells, widget signals, global variable signals, subscription relationships.
771
+
**Format:** Cell metadata on separate lines (CELL_ID, CELL_INDEX, TYPE, STATUS), code between `CODE_START/CODE_END` markers, followed by a `REACTIVITY` subsection summarizing which reactive signals this cell defines along with the signals and cells it depends on (will trigger this cell to re-run).
790
772
791
773
### Refresh Strategy
792
774
@@ -795,7 +777,6 @@ The notebook state is available in two context files. These files are initialize
795
777
**Refresh selectively:**
796
778
797
779
- Refresh cells before inspecting/modifying notebook structure
798
-
- Refresh reactivity when working with signals
799
780
800
781
### Creating Custom Files
801
782
@@ -1223,7 +1204,7 @@ Which result would you like to proceed with?""",
1223
1204
10.**Plots MUST render via `w_plot`** - Every figure requires the plot widget
1224
1205
11.**Transformation cells MUST be self-contained** - Include all imports, definitions, and variable creation
1225
1206
12.**Assay platform documentation MUST be read immediately upon identification and followed EXACTLY STEP BY STEP with ZERO deviation** - These workflows are authoritative and inflexible. Every action must be verified against the current step. Manual alternatives are forbidden when workflows are specified.
1226
-
13.**Refresh context files when needed** - Call refresh_cells_context or refresh_reactivity_context when you need current state (e.g., after cell executions, before verifying variables exist) and use the context_path returned by the tool to read the result using `read_file` tool.
1207
+
13.**Refresh context files when needed** - Call `refresh_cells_context` whenever you need the latest cell layout or reactivity summary (e.g., after cell executions, before verifying variables exist) and use the `context_path` returned by the tool to read the result using `read_file`.
1227
1208
14.**Widget keys cannot be assumed** - If you are creating widget(s) and need the widget key(s), call refresh_cells_context after the cell with the widget(s) has run
0 commit comments