Skip to content

Commit 2d5c5e0

Browse files
committed
v64: deliver chat replies, preserve actionable financial visibility and add private remote access
1 parent 95ad618 commit 2d5c5e0

21 files changed

Lines changed: 1208 additions & 79 deletions

‎SYNTA_RECOVERY.md‎

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,40 @@ Runtime evidence is stored under research/market-research, research/backtests,
195195
research/income-policy-history and research/architecture-candidates. Code tests do
196196
not assert operator-browser, Windows/CUDA runtime acceptance or actual income.
197197

198+
## v64: delivered replies, independent financial visibility and remote access
199+
200+
- Financial questions including the operator's `zarobiles` wording read measured
201+
historical/ledger facts directly. They do not substitute a no-real-orders
202+
explanation for an unprofitable simulation. Explicit `assume capital` commands
203+
update hypothetical-capital policy without authorizing spending. The upgrade
204+
applies the current operator's explicit paper-capital authorization.
205+
- Read-only financial/status questions can bypass the GPU work queue. Terminal
206+
chat monitors requests still pending after its wait window, delivers eventual
207+
saved results and errors, and offers `/results` and `/pending`. Real commands
208+
retain their bounded queue and tool receipts.
209+
- Completed research cycles, last entered loop stage, admitted data, optimizer
210+
steps and accepted weights are separate. The loop records preparation,
211+
research, memory work, data admission, waits and candidate trials. A checkpoint
212+
no longer runs a synchronous full financial audit inside the controller.
213+
- Dashboard inference/readiness HTTP polling uses already-collected events;
214+
browser requests have eight-second deadlines and one in-flight request per
215+
endpoint. The action archive uses live-document delegated events and a retained
216+
DOM container, preserving expanded records across updates and on errors.
217+
- Stored historical tests load independently of the aggregate report. A separate
218+
bounded read checks the current paper state and its last event, exposing equity,
219+
positions, quote/fee blockers and original timestamps. It is visibly distinct
220+
from a full-history audit; it does not invent fill counts. Saved paper reports
221+
retain their own period/time rather than pretending to be live or current-run
222+
training evidence. Negative results remain negative.
223+
- `install-synta-remote.sh` prepares owner-only Tailscale HTTPS dashboard/chat and
224+
existing SSH access, without port forwarding. It requires actual operator
225+
login/HTTPS authorization and the same account on mobile/laptop. See
226+
SYNTA_REMOTE_ACCESS.md for boundaries and shutdown. Windows RTX stays disabled;
227+
the existing conservative Windows CPU worker is unchanged.
228+
229+
The finite code tests do not prove a profitable strategy, continuous optimizer
230+
updates, a successful phone login, or runtime performance on the operator's GPUs.
231+
198232
## v63: independent live refresh and conservative Windows CPU
199233

200234
- Live file snapshots refresh every five seconds without running `mission-report`

‎SYNTA_REMOTE_ACCESS.md‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Private remote Synta
2+
3+
Run `tools/install-synta-remote.sh` as the existing Debian operator after updating Synta. It installs Tailscale from its official signed Debian repository if absent. Login is an operator step: open the printed link, then use the same account on the phone/laptop. If HTTPS needs enabling, Tailscale Serve prints its authorization link.
4+
5+
The script prints the private dashboard, `/chat` and SSH address. Tailscale provides connections outside the LAN without router port forwarding. SSH uses the existing Debian SSH credentials. Install Tailscale separately on another home computer to access that computer; this installer does not expose the whole LAN or enable Windows RDP.
6+
7+
The web gateway binds only `127.0.0.1:8786`. Tailscale Serve terminates HTTPS and supplies verified identity headers. Every route requires the configured owner login. Chat writes require the exact HTTPS Origin and a per-process CSRF token; only the existing bounded mission queue is writable. Dashboard proxy routes and body sizes are restricted. There is no public Funnel, arbitrary URL proxy, browser terminal or unauthenticated command endpoint. Existing Serve and Funnel configuration conflicts are preserved and reported.
8+
9+
Browser chat keeps actual saved request states and replies visible across reconnects. It supports the same goal and work commands as the terminal. A submitted command is not a completed action. `/status` is read from host evidence by the mission service. Authentication, ACLs, HTTPS authorization and the first real phone connection must be completed/verified on the operator's devices.
10+
11+
Disable the gateway with `systemctl --user disable --now synta-remote.service`. Disable only its Serve listener with `sudo tailscale serve --https=443 off`; do not reset other Tailscale services.
12+
13+
Official references: [Serve and identity headers](https://tailscale.com/docs/features/tailscale-serve), [packages](https://pkgs.tailscale.com/stable/), [SSH access](https://tailscale.com/docs/features/tailscale-ssh).

‎SYNTA_REQUIREMENTS_AUDIT.md‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,3 +146,24 @@ accepted weight updates have not been demonstrated in this workspace.
146146
Final v63 validation: 1134 passed, 65 skipped, one existing PEFT warning.
147147
Ruff, formatting, shell syntax and whitespace checks pass. PowerShell has
148148
static contract tests; this Linux workspace does not execute Windows APIs.
149+
150+
## v64 final verification
151+
152+
The terminal and authenticated mobile gateway return financial/status facts without
153+
waiting for GPU jobs. Eventual queued replies remain available and are delivered
154+
by the terminal monitor. Regression coverage includes the exact uploaded Polish
155+
question, assume-capital authorization, language-specific learning facts, queue
156+
persistence, CSRF/owner checks, bounded proxy routes and conflicting remote setup.
157+
158+
Dashboard HTTP inference/readiness reads use cached events. Executed JavaScript
159+
tests click archive controls, expand a record, run repeated rendering updates and
160+
click again, checking DOM identity, disclosure state and deduplication. Full
161+
controller checkpoints no longer call the full report audit. Financial display
162+
tests read while a ledger writer holds a transaction, refuse checksum tampering,
163+
and show historical losses without inventing missing fill counts or timestamps.
164+
165+
Final test run: **1159 passed, 65 skipped**, one existing PEFT warning; no
166+
deselections. Ruff, shell syntax and diff checks passed. The real operator phone
167+
login, Tailscale policy/HTTPS approval, Windows APIs and V100/CUDA performance
168+
remain deployment checks. No profitable strategy or accepted production weight
169+
update is inferred from passing these code tests.

‎pyproject.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name = "rlms"
33
authors = [
44
{name = "Alex Zhang", email = "altzhang@mit.edu"},
55
]
6-
version = "0.1.3+v100.63"
6+
version = "0.1.3+v100.64"
77
description = "Recursive Language Models."
88
readme = "README.md"
99
license = "MIT"

‎rlm/v100/chat_facts.py‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def language(message: str) -> str:
1010
return (
1111
"Polish"
1212
if re.search(
13-
r"\b(?:co|czemu|jak|czy|kiedy|gdzie|zarab|zarabianiem|zrob|zmien|przetestuj|poszukaj|zbieraj|hej|czesc|odpowiedz)\w*\b",
13+
r"\b(?:co|czego|czemu|jak|czy|kiedy|gdzie|uczy|naucz|zarab|zarob|znalaz|zrob|zmien|przetestuj|poszukaj|zbieraj|hej|czesc|odpowiedz)\w*\b",
1414
normalized(message),
1515
)
1616
else "English"
@@ -20,7 +20,7 @@ def language(message: str) -> str:
2020
def requested(message: str) -> bool:
2121
return bool(
2222
re.search(
23-
r"zarab|income|profit|backtest|minus|paper|opportunit|candidate|brier|kandydat",
23+
r"zarab|zarob|strateg|income|profit|backtest|minus|paper|opportunit|candidate|brier|kandydat",
2424
normalized(message),
2525
)
2626
)
@@ -35,9 +35,9 @@ def response(root: Path, message: str) -> dict:
3535
pl = language(message) == "Polish"
3636
paper = value.get("paper", {})
3737
lines = [
38-
"Brak potwierdzonego rzeczywistego dochodu. Nie ma wiarygodnej daty pierwszego zarobku."
38+
"Oceniam wyniki symulacji i strategii, przy założeniu hipotetycznego kapitału. Brak realnych zleceń nie wyjaśnia strat w paper."
3939
if pl
40-
else "No actual income verified. There is no verified date of first income.",
40+
else "I assess simulated capital growth and strategy results. No real orders does not explain paper losses.",
4141
("Faza: " if pl else "Phase: ") + str(value.get("phase")),
4242
("Wykonania paper: " if pl else "Paper fills: ")
4343
+ str(paper.get("executed_fills", "unknown")),

‎rlm/v100/chat_progress.py‎

Lines changed: 74 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
"""Direct read-only progress replies, independent of model conversation drift."""
22

3+
import json
34
import re
45
from pathlib import Path
56

@@ -10,7 +11,7 @@ def requested(message: str) -> bool:
1011
text = normalized(message)
1112
return bool(
1213
re.search(
13-
r"co (?:teraz |aktualnie )?robisz|jaki (?:jest )?(?:postep|progres)|czego sie nauczyl",
14+
r"co (?:teraz |aktualnie )?robisz|jaki (?:jest )?(?:postep|progres)|czego sie nauczyl|czy .*uczysz sie|czy uczysz sie|learn.*continuously|what have you learned|what are you doing",
1415
text,
1516
)
1617
) and not re.search(r"\b(?:zmien|dodaj|napraw|zrob|wdroz|zaimplementuj)\b", text)
@@ -25,42 +26,98 @@ def continue_requested(message: str) -> bool:
2526
)
2627

2728

28-
def respond(root: Path) -> dict:
29+
def respond(root: Path, message: str | None = None) -> dict:
30+
from rlm.v100.chat_facts import language
2931
from rlm.v100.mission_evidence import collect
3032

3133
evidence = collect(root)
3234
learning = evidence["learning"]
3335
official = evidence.get("official_benchmark", {})
36+
pl = message is None or language(message) == "Polish"
37+
38+
def wording(polish: str, english: str) -> str:
39+
return polish if pl else english
3440

3541
def metric(value):
36-
return str(value) if value is not None else "brak potwierdzonych danych"
42+
return (
43+
str(value)
44+
if value is not None
45+
else wording("brak potwierdzonych danych", "no verified data")
46+
)
3747

3848
lines = [
39-
"Status z plików kontrolera, bez zmiany planów:",
40-
"Misja: " + ("działa" if evidence["mission_running"] else "zatrzymana"),
41-
"Faza: " + str(evidence.get("phase")),
42-
"Cykle uczenia: " + metric(learning.get("completed_cycles")),
43-
"Potwierdzone kroki optymalizatora: " + metric(evidence["optimizer_updates_observed"]),
44-
"Zaakceptowane aktualizacje wag: " + metric(evidence["accepted_weight_updates_this_run"]),
49+
wording(
50+
"Pętla badań działa osobno od treningu wag. Trening wymaga nowych zweryfikowanych danych; nie odbywa się przy każdej odpowiedzi.",
51+
"Research runs separately from weight training. Training requires new verified data; answering a message is not an optimizer update.",
52+
),
53+
wording("Misja: ", "Mission: ")
54+
+ (
55+
wording("działa", "running")
56+
if evidence["mission_running"]
57+
else wording("zatrzymana", "stopped")
58+
),
59+
wording("Faza: ", "Phase: ") + str(evidence.get("phase")),
60+
wording("Cykle pętli zakończone: ", "Completed loop cycles: ")
61+
+ metric(learning.get("completed_cycles")),
62+
wording("Potwierdzone kroki optymalizatora: ", "Verified optimizer updates: ")
63+
+ metric(evidence["optimizer_updates_observed"]),
64+
wording("Zaakceptowane aktualizacje wag: ", "Accepted weight updates: ")
65+
+ metric(evidence["accepted_weight_updates_this_run"]),
4566
]
4667
if official:
4768
lines += [
48-
f"Benchmark oficjalny: {official.get('completed', '?')}/{official.get('total', '?')} | {official.get('state', 'stan nieznany')}",
49-
"Raport: " + official["report"],
69+
wording("Benchmark oficjalny: ", "Official benchmark: ")
70+
+ f"{official.get('completed', '?')}/{official.get('total', '?')} | {official.get('state', 'unknown')}",
71+
wording("Raport: ", "Report: ") + official["report"],
5072
]
5173
if official.get("current_case"):
52-
lines.append("Bieżący przypadek: " + official["current_case"])
74+
lines.append(
75+
wording("Bieżący przypadek: ", "Current case: ") + official["current_case"]
76+
)
5377
else:
54-
lines.append("Benchmark oficjalny: brak licznika potwierdzonego dla bieżącego przebiegu.")
78+
lines.append(
79+
wording(
80+
"Benchmark oficjalny: brak licznika potwierdzonego dla bieżącego przebiegu.",
81+
"Official benchmark: no verified current-run counter.",
82+
)
83+
)
5584
for report in evidence["reports"]:
5685
if isinstance(report, dict) and report.get("cases"):
57-
lines.append(f"Test bazowy: {report['passed']}/{report['cases']} | {report['path']}")
86+
lines.append(
87+
wording("Test bazowy: ", "Baseline: ")
88+
+ f"{report['passed']}/{report['cases']} | {report['path']}"
89+
)
5890
goal = evidence.get("goal_learning", {})
59-
lines.append("Zapisane prognozy pod cel: " + str(len(goal.get("forecasts", []))))
60-
lines.append("Przebieg: " + str(evidence["run"]))
6191
lines.append(
62-
"Dashboard odświeża renderer hosta; skrypty w edytowalnym HTML mastera nie są potrzebne. Brak licznika nie dowodzi bezczynności."
92+
wording("Prognozy w ostatnim oknie statusu: ", "Forecasts in the recent status window: ")
93+
+ str(len(goal.get("forecasts", [])))
6394
)
95+
if not evidence["accepted_weight_updates_this_run"]:
96+
lines.append(
97+
wording(
98+
"Nie mam potwierdzenia nowych zaakceptowanych wag w tym przebiegu. Zapisanie prognozy lub planu nie jest treningiem.",
99+
"No newly accepted weights verified in this run. Recording a forecast or plan is not training.",
100+
)
101+
)
102+
if evidence.get("run"):
103+
path = Path(evidence["run"]) / "learning/heartbeat.json"
104+
if path.exists() and path.stat().st_size <= 16384:
105+
try:
106+
activity = json.loads(path.read_text())
107+
lines.append(
108+
wording("Ostatni etap pętli: ", "Last loop stage: ")
109+
+ str(activity.get("stage"))
110+
)
111+
if activity.get("reason"):
112+
lines.append(
113+
wording("Powód oczekiwania: ", "Wait reason: ") + activity["reason"]
114+
)
115+
except (OSError, ValueError) as error:
116+
lines.append(
117+
wording("Status etapu niedostępny: ", "Stage status unavailable: ")
118+
+ str(error)[:200]
119+
)
120+
lines.append(wording("Przebieg: ", "Run: ") + str(evidence["run"]))
64121
return {
65122
"answer": "\n".join(lines),
66123
"actions": [],

0 commit comments

Comments
 (0)