@m4trix/core 0.12.1 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +21 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +21 -9
- package/dist/index.js.map +1 -1
- package/dist/matrix/index.cjs +21 -8
- package/dist/matrix/index.cjs.map +1 -1
- package/dist/matrix/index.d.ts +35 -19
- package/dist/matrix/index.js +21 -9
- package/dist/matrix/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { HttpStreamOptions, MessageStream, Pump, Source, StreamChunk, StreamTransformer, ensureFullWords, httpStreamResponse } from './stream/index.js';
|
|
2
2
|
import { Socket } from 'socket.io';
|
|
3
|
-
export { Agent, AgentBinding, AgentFactory, AgentNetwork, AgentNetworkEvent, AgentNetworkEventDef, AnyAgent, AuthResult, Channel, ChannelDef, ChannelName, ConfiguredChannel, ContextEvents, DepedencyLayer, DepedencyLayerDef, EmitPayload, EnvelopeLike, EventEnvelope, EventMeta, EventMetaSchema, EventPlane, ExposeAuthError, ExposeOptions, ExposeRequest, ExposeSelect, ExposedAPI, ExposedStream, ExpressEndpoint, ExpressEndpointOptions, ExpressHandler, ExpressRequest, ExpressResponse, LayerName, LayersFromDeps, NextEndpoint, NextEndpointOptions, NextGetHandler, OnRequestContext, RunEvents, SetupContext, Sink, SinkDef, Skill, SkillDefineContext, SkillInstance, SkillRuntimeOptions, SpawnCallbackContext, SpawnFn, SpawnerBuilder, StreamFactory, UnboundEvent, consoleTracer, consoleTracerLayer, formatSSE, isHttpStreamSink, toSSEStream } from './matrix/index.js';
|
|
3
|
+
export { Agent, AgentBinding, AgentFactory, AgentNetwork, AgentNetworkEvent, AgentNetworkEventDef, AnyAgent, AuthResult, Channel, ChannelDef, ChannelName, ConfiguredChannel, ContextEvents, DepedencyLayer, DepedencyLayerDef, Done, EmitPayload, EnvelopeLike, EventEnvelope, EventMeta, EventMetaSchema, EventPlane, ExposeAuthError, ExposeOptions, ExposeRequest, ExposeSelect, ExposedAPI, ExposedStream, ExpressEndpoint, ExpressEndpointOptions, ExpressHandler, ExpressRequest, ExpressResponse, LayerName, LayersFromDeps, NextEndpoint, NextEndpointOptions, NextGetHandler, OnRequestContext, RunEvents, SetupContext, Sink, SinkDef, Skill, SkillDefineContext, SkillInstance, SkillRuntimeOptions, SpawnCallbackContext, SpawnFn, SpawnerBuilder, StreamFactory, UnboundEvent, consoleTracer, consoleTracerLayer, formatSSE, isHttpStreamSink, toSSEStream } from './matrix/index.js';
|
|
4
4
|
export { Schema as S } from 'effect';
|
|
5
5
|
import 'effect/ParseResult';
|
|
6
6
|
|
package/dist/index.js
CHANGED
|
@@ -1559,16 +1559,19 @@ var LayerName = Brand.refined(
|
|
|
1559
1559
|
(s) => Brand.error(`Expected camelCase (e.g. myLayerFoo), got: ${s}`)
|
|
1560
1560
|
);
|
|
1561
1561
|
var DepedencyLayer = {
|
|
1562
|
-
of(
|
|
1563
|
-
const name = LayerName(
|
|
1564
|
-
const
|
|
1565
|
-
|
|
1562
|
+
of(def) {
|
|
1563
|
+
const name = LayerName(def.name);
|
|
1564
|
+
const decodeConfig = Schema.decodeUnknown(def.config);
|
|
1565
|
+
const dep = {
|
|
1566
1566
|
_tag: "SkillDependencyDef",
|
|
1567
1567
|
name,
|
|
1568
|
-
_name:
|
|
1569
|
-
|
|
1570
|
-
|
|
1568
|
+
_name: def.name,
|
|
1569
|
+
config: def.config,
|
|
1570
|
+
decodeConfig
|
|
1571
1571
|
};
|
|
1572
|
+
return Object.assign(dep, {
|
|
1573
|
+
define: () => dep
|
|
1574
|
+
});
|
|
1572
1575
|
}
|
|
1573
1576
|
};
|
|
1574
1577
|
function toLayerArray(layers) {
|
|
@@ -1587,6 +1590,15 @@ function assertUniqueLayerNames(layers) {
|
|
|
1587
1590
|
seen.add(key);
|
|
1588
1591
|
}
|
|
1589
1592
|
}
|
|
1593
|
+
var DoneTypeId = Symbol.for("sunken-trove/Done");
|
|
1594
|
+
var Done = {
|
|
1595
|
+
of(value) {
|
|
1596
|
+
return { [DoneTypeId]: DoneTypeId, _tag: "Done", done: value };
|
|
1597
|
+
},
|
|
1598
|
+
is(u) {
|
|
1599
|
+
return typeof u === "object" && u !== null && DoneTypeId in u && u[DoneTypeId] === DoneTypeId;
|
|
1600
|
+
}
|
|
1601
|
+
};
|
|
1590
1602
|
var Skill = class _Skill {
|
|
1591
1603
|
constructor(params) {
|
|
1592
1604
|
this._inputSchema = params.inputSchema;
|
|
@@ -1693,7 +1705,7 @@ var Skill = class _Skill {
|
|
|
1693
1705
|
for (const c of chunks) {
|
|
1694
1706
|
yield c;
|
|
1695
1707
|
}
|
|
1696
|
-
yield
|
|
1708
|
+
yield Done.of(decodedDone);
|
|
1697
1709
|
},
|
|
1698
1710
|
invoke: async (input, runtime) => {
|
|
1699
1711
|
const decodedInput = Effect.runSync(
|
|
@@ -1914,6 +1926,6 @@ var consoleTracerLayer = Layer.setTracer(
|
|
|
1914
1926
|
consoleTracer
|
|
1915
1927
|
);
|
|
1916
1928
|
|
|
1917
|
-
export { Agent, AgentFactory, AgentNetwork, AgentNetworkEvent, Channel, ChannelName, ConfiguredChannel, DepedencyLayer, EventMetaSchema, ExposeAuthError, ExpressEndpoint, LayerName, NextEndpoint, Pump, Sink, Skill, SocketIoFactory, consoleTracer, consoleTracerLayer, ensureFullWords, formatSSE, httpStreamResponse, isHttpStreamSink, toSSEStream };
|
|
1929
|
+
export { Agent, AgentFactory, AgentNetwork, AgentNetworkEvent, Channel, ChannelName, ConfiguredChannel, DepedencyLayer, Done, EventMetaSchema, ExposeAuthError, ExpressEndpoint, LayerName, NextEndpoint, Pump, Sink, Skill, SocketIoFactory, consoleTracer, consoleTracerLayer, ensureFullWords, formatSSE, httpStreamResponse, isHttpStreamSink, toSSEStream };
|
|
1918
1930
|
//# sourceMappingURL=out.js.map
|
|
1919
1931
|
//# sourceMappingURL=index.js.map
|