Repository navigation
The stage-2 router listens in the PTY server; the arena holds ten providers - #12814
Conversation
Summary by t27-beesChecked by the t27 compilert27c parse, parse-complete and typecheck on each changed .t27 file at
Read by the modelThis PR hosts the stage-2 router's accept loop inside the PTY server (binding 127.0.0.1:47127), expands the provider key table from 72 to 80 slots, fixes a SOCK_STREAM constant collision between Worth a look
Read: 9 files, +943 -496, the whole diff up to 60000 characters (the rest was not read). Head |
|
Second commit: the outbound call law (provider/call.t27, 3/3) -- the bytes the router's walk will write to zai/nemotron and the content it reads back. The walk wiring itself is the successor lane; this PR closes the host wiring (#12797). |
…s ten providers (Closes #12797) pty_server hosts the router accept loop by the merged laws: router_actor router_listen opens 127.0.0.1:47127 (the bytes are router_sock's), the mailbox holds CONN_MAILBOX connections in G_RCFD, serve_answer puts the wire down, and a burst of broken clients backs the conn loop off for BACKOFF_TICKS (tick_decision) while panes and the supervisor keep ticking. The walk's body is the router's own honest error until the outbound provider client lands. SOCK_STREAM is one law: router_sock imports pty_client's and re-declares nothing (two modules emitting one name collide in the merged build). pty_logic carries the growth: ST_SIZE 512 to 544 for the router state, the key table 72 to 80 slots (the nvidia provider made PROVIDER_COUNT 10; the 72-slot table silently dropped its keys), O_CARRY/O_SCAN moved after the grown table, O_RTRD + 8 x 2048 read buffers appended, MEM_SIZE 1171712 to 1190088; the arena, mask and load pins follow the law (load_all_mask is 1023, needs_key reads it, no literal masks). pty_logic 58/58, pty_server 25/25, router 8, sock 3, serve 5, actor 4, keys 115, fleet 5, transform 12 -- t27c and t27b agree. phi^2 + 1/phi^2 = 3 | TRINITY
…ply's content (Refs #12797) provider/call.t27: chat_request composes the POST a provider's chat-completions endpoint expects (the head, the bearer, Content-Length naming the body, then the body); chat_body escapes the prompt the way JSON must; reply_content reads the assistant's content back out, decoding the escapes. The socket belongs to the walk (the router-host successor); this spec owns the bytes only. Keys are never printed; the max_tokens arrives from the caller, which applies the floor law. call 3/3 -- t27c and t27b agree. phi^2 + 1/phi^2 = 3 | TRINITY
7b3a190 to
eaaedff
Compare
PR DashboardGenerated at: 2026-10-27 11:59:30 UTC
Summary
Seal Status
|
Closes #12797
What lands (all on .t27, the host binary is generated)
Verification
pty_logic 58/58, pty_server 25/25, router 8, sock 3, serve 5, actor 4, keys 115, fleet 5, transform 12 -- t27c and t27b agree. Seals: T27osPtyServer, T27osPtyLogic, T27osRouterActor, T27osRouter refreshed against this tree; the dupe ratchet is green. Master carried these reds before this PR: pty_logic 55/58, pty_server 21/25 (the arena overlap was a real memory overlap, not a stale pin).
phi^2 + 1/phi^2 = 3 | TRINITY