mirror of
https://github.com/badlogic/pi-mono.git
synced 2026-11-05 23:37:25 +00:00
feat(chord): replace the facet and service runtime with the chord2 host runtime
Moves chord2 (contracts, objects, cells, roots, plugins, hot reload, memory/IPC/WebSocket links) from p2 into packages/chord, with its tests (now on vitest) and docs. The root export is the new runtime plus the shared base (Context, JsonValue, JsonRepresentation, Draft, copyJson, isJsonValue, replicatedState and its types). ./node now holds the host manager, child control, process locks, and nodeLoader. ./context and ./delta are unchanged; ./bundler is removed. replicatedState stays a standalone module with the same exports. It no longer exposes the exact-op subscription the removed service provider used, so listener failures of mutable states are always reported asynchronously. The package depends on typebox instead of esbuild. The wire format stays JSON.
This commit is contained in:
parent
7472cda0d6
commit
0104fef1e9
92 changed files with 15191 additions and 8974 deletions
|
|
@ -1,3 +1,4 @@
|
|||
import { createHost, memoryLinkPair, replicatedState } from "@earendil-works/chord";
|
||||
import { createAssistantMessageEventStream, Type } from "@earendil-works/pi-ai";
|
||||
import { complete, getModel, getProviders, streamSimple } from "@earendil-works/pi-ai/compat";
|
||||
import { Agent, streamProxy } from "@earendil-works/pi-agent-core";
|
||||
|
|
@ -19,4 +20,7 @@ console.log(
|
|||
typeof stream.push,
|
||||
agent.hasQueuedMessages(),
|
||||
typeof streamProxy,
|
||||
typeof createHost,
|
||||
typeof memoryLinkPair,
|
||||
replicatedState({ browser: true }).value.browser,
|
||||
);
|
||||
|
|
|
|||
|
|
@ -58,8 +58,9 @@ const BUDGETS = {
|
|||
"packages/durable": {
|
||||
".": {
|
||||
// Tool argument validation reaches TypeBox; provider-session creation reaches pi-ai's lean UUID utility; the
|
||||
// memory and SQLite storages share scan order and cursor handling.
|
||||
maxFiles: 63,
|
||||
// memory and SQLite storages share scan order and cursor handling. Values from Chord's root (copyJson,
|
||||
// replicatedState) reach its host runtime through the root barrel.
|
||||
maxFiles: 66,
|
||||
forbid: [
|
||||
"packages/ai/src/index.ts",
|
||||
"packages/ai/src/utils/typebox-helpers.ts",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue